Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Download
1042 views


	�\Y	�@sxddlZddlZddljZddlmZdddddddddddd�
Ze	dkrte�dS)�N)�model_selectionc

Cs4xtdt|��D]}
t||
�}t||
d�}t||
�}
t||
�}t||
�}t||
�}t||
�}t||
�}t||
|||||�}tj||
|
|d�||
||d�||
||d�||
||d�||
||d�||
||d�f�}||
||d�}td||
d�t|�}t|�}|dt|d��|t|d�d�|dt|d��|t|d�d�f\}}}}|	j|�}|	j|�}tj	|||||�}t|�t|�}}t|||�}t
jdd�t
j||
d�t
j
d�t
jd	�t
j||
d||d�|d
�t
j||
d||d�|�t
j�td||
d�td�qWtd
�t�dS)Nr�zAnalysis for: g�?�figsize���dateZclose_price�roz
Done for: zD====================================================================zAll analysis done)rr)�range�len�min�np�column_stack�print�intZ
fit_transform�utilityZtest_regression�plt�figure�title�xlabel�ylabel�plot�show)Z	model_fit�close_prices_vecs�stock_name_time_stamps�rsi_vecs�mfi_vecs�ema_vecs�so_vecs�	macd_vecs�sl_vecs�scaler�iZ	close_lenZdate_lenZrsi_lenZmfi_lenZema_lenZso_lenZmacd_lenZsl_lenZshared_data_len�x�yZx_lenZy_lenZx_trainZx_testZy_trainZy_testZy_predZ
y_test_lenZ
y_pred_len�r$�E/projects/3572606d-aafc-4285-a345-c223c56d1457/ML/Main/veky_runner.py�runnersD0*3n

)&

r&�__main__)
r�numpyr�matplotlib.pyplot�pyplotr�sklearnrr&�__name__r$r$r$r%�<module>s)