From 016b643e3898036788f6ae1bce1183a3e5fc69f7 Mon Sep 17 00:00:00 2001 From: Dagmawi Teferi Date: Tue, 17 Dec 2024 14:08:16 -0500 Subject: [PATCH] main script --- scripts/task2main.py | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 scripts/task2main.py diff --git a/scripts/task2main.py b/scripts/task2main.py new file mode 100644 index 0000000..c851874 --- /dev/null +++ b/scripts/task2main.py @@ -0,0 +1,22 @@ +import sys +import os + +# Add src directory to the Python path +src_path = os.path.abspath(os.path.join(os.path.dirname(__file__), '../src')) +sys.path.append(src_path) + +import data_preprocessing as dp +import indicators as ind +import visualization as vis + +# Example usage +def main(): + file_path = '../data/amazon.csv' + data = dp.load_data(file_path) + data = ind.calculate_indicators(data) + vis.plot_moving_averages(data, 'Stock_price_moving_average.png') + vis.plot_rsi(data, 'relative_strength_index.png') + vis.plot_macd(data, 'macd_signals.png') + +if __name__ == '__main__': + main() \ No newline at end of file