⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 example_script_1.m

📁 This is a simple algorithm that downloads trading data from yahoo database. It is basically a large
💻 M
字号:
% Example Script for Get_Tickers_Data
%
% This script will get the stock date based on the file example_tickers.txt
% You may change the strings at that txt file for your own assets.

clear;

%%%%%%%%%%%%%%%%%%%%%%% OPTIONS %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

firstDay='01/01/2000';  % First day in sample to be downloaded (format: dd/mm/yyyy)
lastDay ='01/01/2007';  % Last day in sample to be downloaded (format: dd/mm/yyyy)

n_stocks=10;         % Number of stocks to download data (according to tickers.txt)
Criteria=.05;       % Percent of missing prices for bad data event
Freq='d';           % Frequency ('d'-dailly ; 'w' - Weekly, 'm' - monthly)

ticker_fileName='example_tickers.txt';  % the name of the ticker txt file

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

addpath('m_Files');         % adding both paths to matlab's search path
addpath('m_Files\sqq_msp');

[SPData]=GetTickersData(firstDay, ...
                        lastDay , ...
                        n_stocks, ... 
                        ticker_fileName, ... 
                        Freq, ... 
                        Criteria);
                      
rmpath('m_Files');    
rmpath('m_Files\sqq_msp');

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -