added documentation to analysis.py
This commit is contained in:
@@ -299,6 +299,224 @@
|
||||
"print(client.fine_tuning.jobs.list(limit=10))\n"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 2,
|
||||
"metadata": {},
|
||||
"outputs": [
|
||||
{
|
||||
"data": {
|
||||
"text/html": [
|
||||
"<div>\n",
|
||||
"<style scoped>\n",
|
||||
" .dataframe tbody tr th:only-of-type {\n",
|
||||
" vertical-align: middle;\n",
|
||||
" }\n",
|
||||
"\n",
|
||||
" .dataframe tbody tr th {\n",
|
||||
" vertical-align: top;\n",
|
||||
" }\n",
|
||||
"\n",
|
||||
" .dataframe thead th {\n",
|
||||
" text-align: right;\n",
|
||||
" }\n",
|
||||
"</style>\n",
|
||||
"<table border=\"1\" class=\"dataframe\">\n",
|
||||
" <thead>\n",
|
||||
" <tr style=\"text-align: right;\">\n",
|
||||
" <th></th>\n",
|
||||
" <th>vwap_direction_next_5min</th>\n",
|
||||
" <th>confidence_score</th>\n",
|
||||
" <th>expected_vwap_change</th>\n",
|
||||
" <th>volatility_estimate</th>\n",
|
||||
" <th>suggested_entry</th>\n",
|
||||
" <th>suggested_stop_loss</th>\n",
|
||||
" <th>suggested_take_profit</th>\n",
|
||||
" <th>key_signals</th>\n",
|
||||
" <th>reasoning</th>\n",
|
||||
" <th>timestamp_prediction</th>\n",
|
||||
" <th>actual_vwap_change</th>\n",
|
||||
" <th>actual_price_change</th>\n",
|
||||
" <th>actual_volume</th>\n",
|
||||
" <th>actual_return</th>\n",
|
||||
" <th>actual_movement</th>\n",
|
||||
" <th>prediction_correct</th>\n",
|
||||
" <th>hour</th>\n",
|
||||
" <th>day_of_week</th>\n",
|
||||
" </tr>\n",
|
||||
" </thead>\n",
|
||||
" <tbody>\n",
|
||||
" <tr>\n",
|
||||
" <th>0</th>\n",
|
||||
" <td>up</td>\n",
|
||||
" <td>0.85</td>\n",
|
||||
" <td>0.01</td>\n",
|
||||
" <td>0.02</td>\n",
|
||||
" <td>701.50</td>\n",
|
||||
" <td>700.5</td>\n",
|
||||
" <td>702.5</td>\n",
|
||||
" <td>['Consistent upward VWAP movement', 'Price abo...</td>\n",
|
||||
" <td>The current market window shows a consistent u...</td>\n",
|
||||
" <td>2025-01-31 10:50:00-05:00</td>\n",
|
||||
" <td>0.000048</td>\n",
|
||||
" <td>0.000126</td>\n",
|
||||
" <td>149963.0</td>\n",
|
||||
" <td>0.000048</td>\n",
|
||||
" <td>up</td>\n",
|
||||
" <td>True</td>\n",
|
||||
" <td>10</td>\n",
|
||||
" <td>4</td>\n",
|
||||
" </tr>\n",
|
||||
" <tr>\n",
|
||||
" <th>1</th>\n",
|
||||
" <td>up</td>\n",
|
||||
" <td>0.85</td>\n",
|
||||
" <td>0.01</td>\n",
|
||||
" <td>0.02</td>\n",
|
||||
" <td>699.50</td>\n",
|
||||
" <td>698.5</td>\n",
|
||||
" <td>700.5</td>\n",
|
||||
" <td>['Consistent upward VWAP movement', 'Price sta...</td>\n",
|
||||
" <td>The current market window shows a consistent u...</td>\n",
|
||||
" <td>2025-01-31 10:55:00-05:00</td>\n",
|
||||
" <td>0.000044</td>\n",
|
||||
" <td>-0.000251</td>\n",
|
||||
" <td>135296.6</td>\n",
|
||||
" <td>0.000044</td>\n",
|
||||
" <td>up</td>\n",
|
||||
" <td>True</td>\n",
|
||||
" <td>10</td>\n",
|
||||
" <td>4</td>\n",
|
||||
" </tr>\n",
|
||||
" <tr>\n",
|
||||
" <th>2</th>\n",
|
||||
" <td>up</td>\n",
|
||||
" <td>0.85</td>\n",
|
||||
" <td>0.01</td>\n",
|
||||
" <td>0.02</td>\n",
|
||||
" <td>700.00</td>\n",
|
||||
" <td>698.5</td>\n",
|
||||
" <td>701.5</td>\n",
|
||||
" <td>['Consistent upward VWAP movement', 'Price sta...</td>\n",
|
||||
" <td>The current market window shows a consistent u...</td>\n",
|
||||
" <td>2025-01-31 11:00:00-05:00</td>\n",
|
||||
" <td>0.000043</td>\n",
|
||||
" <td>0.000080</td>\n",
|
||||
" <td>131817.6</td>\n",
|
||||
" <td>0.000043</td>\n",
|
||||
" <td>up</td>\n",
|
||||
" <td>True</td>\n",
|
||||
" <td>11</td>\n",
|
||||
" <td>4</td>\n",
|
||||
" </tr>\n",
|
||||
" <tr>\n",
|
||||
" <th>3</th>\n",
|
||||
" <td>up</td>\n",
|
||||
" <td>0.85</td>\n",
|
||||
" <td>0.01</td>\n",
|
||||
" <td>0.02</td>\n",
|
||||
" <td>700.84</td>\n",
|
||||
" <td>699.5</td>\n",
|
||||
" <td>702.0</td>\n",
|
||||
" <td>['Consistent upward VWAP movement', 'Price sta...</td>\n",
|
||||
" <td>The current market window shows a consistent u...</td>\n",
|
||||
" <td>2025-01-31 11:05:00-05:00</td>\n",
|
||||
" <td>0.000041</td>\n",
|
||||
" <td>-0.000457</td>\n",
|
||||
" <td>131642.2</td>\n",
|
||||
" <td>0.000041</td>\n",
|
||||
" <td>up</td>\n",
|
||||
" <td>True</td>\n",
|
||||
" <td>11</td>\n",
|
||||
" <td>4</td>\n",
|
||||
" </tr>\n",
|
||||
" <tr>\n",
|
||||
" <th>4</th>\n",
|
||||
" <td>up</td>\n",
|
||||
" <td>0.85</td>\n",
|
||||
" <td>0.01</td>\n",
|
||||
" <td>0.02</td>\n",
|
||||
" <td>699.50</td>\n",
|
||||
" <td>698.5</td>\n",
|
||||
" <td>700.5</td>\n",
|
||||
" <td>['Consistent upward VWAP movement', 'Price sta...</td>\n",
|
||||
" <td>The current market window shows a consistent u...</td>\n",
|
||||
" <td>2025-01-31 11:10:00-05:00</td>\n",
|
||||
" <td>0.000044</td>\n",
|
||||
" <td>-0.000564</td>\n",
|
||||
" <td>139622.6</td>\n",
|
||||
" <td>0.000044</td>\n",
|
||||
" <td>up</td>\n",
|
||||
" <td>True</td>\n",
|
||||
" <td>11</td>\n",
|
||||
" <td>4</td>\n",
|
||||
" </tr>\n",
|
||||
" </tbody>\n",
|
||||
"</table>\n",
|
||||
"</div>"
|
||||
],
|
||||
"text/plain": [
|
||||
" vwap_direction_next_5min confidence_score expected_vwap_change \\\n",
|
||||
"0 up 0.85 0.01 \n",
|
||||
"1 up 0.85 0.01 \n",
|
||||
"2 up 0.85 0.01 \n",
|
||||
"3 up 0.85 0.01 \n",
|
||||
"4 up 0.85 0.01 \n",
|
||||
"\n",
|
||||
" volatility_estimate suggested_entry suggested_stop_loss \\\n",
|
||||
"0 0.02 701.50 700.5 \n",
|
||||
"1 0.02 699.50 698.5 \n",
|
||||
"2 0.02 700.00 698.5 \n",
|
||||
"3 0.02 700.84 699.5 \n",
|
||||
"4 0.02 699.50 698.5 \n",
|
||||
"\n",
|
||||
" suggested_take_profit key_signals \\\n",
|
||||
"0 702.5 ['Consistent upward VWAP movement', 'Price abo... \n",
|
||||
"1 700.5 ['Consistent upward VWAP movement', 'Price sta... \n",
|
||||
"2 701.5 ['Consistent upward VWAP movement', 'Price sta... \n",
|
||||
"3 702.0 ['Consistent upward VWAP movement', 'Price sta... \n",
|
||||
"4 700.5 ['Consistent upward VWAP movement', 'Price sta... \n",
|
||||
"\n",
|
||||
" reasoning \\\n",
|
||||
"0 The current market window shows a consistent u... \n",
|
||||
"1 The current market window shows a consistent u... \n",
|
||||
"2 The current market window shows a consistent u... \n",
|
||||
"3 The current market window shows a consistent u... \n",
|
||||
"4 The current market window shows a consistent u... \n",
|
||||
"\n",
|
||||
" timestamp_prediction actual_vwap_change actual_price_change \\\n",
|
||||
"0 2025-01-31 10:50:00-05:00 0.000048 0.000126 \n",
|
||||
"1 2025-01-31 10:55:00-05:00 0.000044 -0.000251 \n",
|
||||
"2 2025-01-31 11:00:00-05:00 0.000043 0.000080 \n",
|
||||
"3 2025-01-31 11:05:00-05:00 0.000041 -0.000457 \n",
|
||||
"4 2025-01-31 11:10:00-05:00 0.000044 -0.000564 \n",
|
||||
"\n",
|
||||
" actual_volume actual_return actual_movement prediction_correct hour \\\n",
|
||||
"0 149963.0 0.000048 up True 10 \n",
|
||||
"1 135296.6 0.000044 up True 10 \n",
|
||||
"2 131817.6 0.000043 up True 11 \n",
|
||||
"3 131642.2 0.000041 up True 11 \n",
|
||||
"4 139622.6 0.000044 up True 11 \n",
|
||||
"\n",
|
||||
" day_of_week \n",
|
||||
"0 4 \n",
|
||||
"1 4 \n",
|
||||
"2 4 \n",
|
||||
"3 4 \n",
|
||||
"4 4 "
|
||||
]
|
||||
},
|
||||
"execution_count": 2,
|
||||
"metadata": {},
|
||||
"output_type": "execute_result"
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"import pandas as pd\n",
|
||||
"df = pd.read_csv('/Users/ysheynin/deepseek_playground/market_predictor/output/META_2025-01-29_2025-02-02_20250204_044205/predictions.csv')\n",
|
||||
"df.head()"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
|
||||
Reference in New Issue
Block a user