aboutsummarylogtreecommitdiffstats
path: root/graph.h
diff options
context:
space:
mode:
authorAntony Kellermann2018-03-12 14:28:25 -0400
committerAntony Kellermann2018-03-12 14:28:25 -0400
commit3f2c67221fc705e202aef9f9ef46e715acb6d44f (patch)
treeb632d854a89c8ed526c5d4c5a96f6757354c591d /graph.h
parent9581f647acc6afbbc0c0be2904e1ac5ee4bd4007 (diff)
downloadaur-3f2c67221fc705e202aef9f9ef46e715acb6d44f.tar.gz
Transitioned graph to NCurses
Diffstat (limited to 'graph.h')
-rw-r--r--graph.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/graph.h b/graph.h
index 291e7d90fa15..175b0967fa43 100644
--- a/graph.h
+++ b/graph.h
@@ -3,6 +3,7 @@
#define ROWS_SPACING 5
#define COLS_SPACING 12
+#define DAYS_TO_BUSINESS_DAYS_RATIO (29.0/20.0)
#include <stdio.h>
#include <stdlib.h>
@@ -11,6 +12,19 @@
#include <unistd.h>
#include "api.h"
+/**
+ * Main input loop
+ * @param ticker_name_string symbol
+ */
+void graph_main(const char* ticker_name_string);
+
+/**
+ * Prints out a NCurses based graph given an array of daily close prices.
+ * x-axis -- close price
+ * y-axis -- date
+ * @param points daily close prices
+ * @param start_time the starting date
+ */
void graph_print(const double* points, struct tm* start_time);
#endif \ No newline at end of file