
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<title>QuantShare</title>
<description>Trading software, sharing server and social network</description>
<link>http://www.quantshare.com/</link>
<copyright>Corporate Trading</copyright>
<atom:link href="http://www.quantshare.com/postsfeed.xml" rel="self" type="application/rss+xml" />



     <item>
        <title> Chart Layouts Explained - With Custom Scripts</title>
        <description><![CDATA[ Chart layouts contain information such as the number of panes, the formula(s) as well as the template that is applied by each pane.<br />
<br />
<br />
<strong>How to create a layout?</strong><br />
<br />
To create a layout from a chart, right click on that chart, then select "Save layout as...". Type the name for your layout then save.<br />
<br />
<br />
<strong>How to apply a layout?</strong><br />
<br />
To update a chart layout, right click on a chart, select "Change Layout" then select the layout you want to apply.<br />
You can also apply a layout to all opened charts by clicking on the button as shown in the picture below then selecting the appropriate layout.<br />
<br />
<img src="https://www.quantshare.com/manual/Tutorial/Application/Layouts_files/image001.jpg" title="Chart Layouts Explained - With Custom Scripts" /><br />
<br />
<br />
You can also switch from one layout to another using the CONTROL+ALT+L hotkey<br />
<br />
<br />
<strong>Custom Scripts?</strong><br />
<br />
The previous hotkey we introduced allows you to move from one layout to the next one. But how to access the previous layout instead of the next one?<br />
<br />
There is no hotkey for this so we are going to create our own hotkey to do that.<br />
You can create a custom script and assigns a shortcut to it with the "Add Shortcut" feature that you can find after selecting "Divers -> List of shortcuts" at the bottom of Alchemcharts.<br />
<br />
The script should be created using "Tools -> Script Editor".<br />
<br />
<u>Here is an example</u>:<br />
<br />
<span style="color:#1C74A8">if(!Global.ContainsVariable("layout_index"))<br />
{<br />
Global.SetVariable("layout_index", 0);<br />
}<br />
int index = (int)Global.GetVariable("layout_index");<br />
string[] layouts = App.Main.GetLayoutNames();<br />
App.Main.UpdateChartLayout(Charts.GetSelectedChartId(), layouts[index]);<br />
index = index - 1;<br />
if(index < 0)<br />
{<br />
index = layouts.Length - 1;<br />
}<br />
Global.SetVariable("layout_index", index);</span><br />
<br />
<br />
The idea here is to check the value of the global variable "layout_index" (that we define).<br />
Then, we get the list of all layouts, pick the layout given the "layout_index" then subtract one to "layout_index", so that the next time the script is called we will get the previous layout.<br />
<br />
After you create the script, select "File -> Save As..." then save it under the "Scripts" folder.<br />
Now, at the bottom of QuantShare, click on the "Divers" icon then "List of Shortcuts".<br />
In the new form, click on "Add Shortcut".<br />
<br />
<img src="http://www.quantshare.com/Images/blog/layout_hotkey_1.png" title="Chart Layouts Explained - With Custom Scripts" /><br />
<br />
<br />
Type the name of the shortcut, a description, how to activate it then finally enter the script path.<br />
If you named the script "prev_layout" then you should enter there: Scripts\prev_layout.azf<br />
<br />
<img src="http://www.quantshare.com/Images/blog/layout_hotkey_2.png" title="Chart Layouts Explained - With Custom Scripts" /><br />
<br />
<br />
<strong>Automation Ideas?</strong><br />
<br />
There are several ways we can use the layout tool. And when combined with custom scripts capabilities, we can further create advanced and creative stuff.<br />
<br />
<u>Below are some examples of what you can achieve</u>:<br />
<br />
<a href="https://www.quantshare.com/sa-562-update-chart-layout-based-on-active-time-frame">Update Chart Layout based on Active Time Frame</a>: <br />
In this post, we show you how to change the layout of a chart dynamically based on the current chart time frame.<br />
<br />
<a href="https://www.quantshare.com/sa-528-update-chart-layout-based-on-active-ticker-symbol">Update Chart Layout based on Active Ticker Symbol</a>:<br />
In this post, we show you how to change the layout of a chart dynamically based on the current chart symbol. <br />
For example, you can display the RSI on the lower pane for stocks and when switching to an index display a market breadth indicator.<br />
<br />
<a href="https://www.quantshare.com/sa-529-update-chart-layout-based-on-active-ticker-symbol-part-2">Update Chart Layout based on Active Ticker Symbol - Part 2</a>:<br />
This is the second part of the previous blog post. Here, we explain how to associate a specific layout to a list of symbols so that a specific layout is applied to a chart each time a symbol in a specific list is selected.<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-655-chart-layouts-explained-with-custom-scripts</link>
		<guid>http://www.quantshare.com/sa-655-chart-layouts-explained-with-custom-scripts</guid>
        <pubDate> Tue, 01 Jun 2021 17:28:56 -0400 </pubDate>
     </item>  
     <item>
        <title> Create Graphs using the Grid Tool</title>
        <description><![CDATA[ The Grid tool is one of the tools that are available with the Premium version. The reason for that is that the Premium version supports real-time data and the grid tool was mainly created to display and work with real-time data using one or several data feeds.<br />
<br />
Let us show you today how to create graphs using the grid tool.<br />
<br />
Select "Tools -> Grid" then "Grid Editor"<br />
Select "File -> New" in the Grid editor then type in the number of rows and columns. Example: 30 as the number of rows, 10 as the number of columns<br />
<br />
<br />
<strong>Add Formulas</strong><br />
<br />
Type "GOOGL" in A1 cell<br />
Click on A2 cell then click on the "Fx" button at the top under the tool bar.<br />
<br />
Let us select a function now. We want to display the real time data of GOOGL, so we select "Intraday" then "GetClose".<br />
Type A1 as "Symbol Name". QuantShare will get the symbol name from the "A1" cell. Changing the value of "A1" will automatically update any function that references that cell.<br />
Set 60 as "Time Frame". This will display the last price of the last 60 second -1min- bar. Same as the last tick which has a time frame of 0.<br />
<br />
If you do not see any data then make sure that you are connected to a data provider such as "IEX Exchange", "Interactive Brokers", "Yahoo Feed"...<br />
Also, you need to make sure that your cells are using the correct data provider. For this, select all cells then right click, select "DataFeed" then select the data provider you want to work with.<br />
<br />
Click on A3 cell then enter the following formula directly next to the "Fx" button at the top. Note that you can use the formula editor but we want to show you here how to quickly add a formula to a particular cell.<br />
<span style="color:#1C74A8">=GetOpen(A1, 60)</span><br />
<br />
// This will display the open price of the last 1min bar<br />
Note that by default there is no backfill so you will need to wait here 1min in order to get the correct open price.<br />
<br />
Click on A4 cell then enter the following formula:<br />
<span style="color:#1C74A8">=Round(A2-A3, 3)</span><br />
<br />
// This will display the difference between the close and open value of the last 1min bar<br />
<br />
<br />
<strong>Copy Cells</strong><br />
<br />
Select the first four cells (A1, A2, A3 and A4) then click on the right/bottom corner and move your mouse to the right to copy the cell, just like you would do with Excel.<br />
<br />
In the first row, update the "GOOGL" text and type in other stock or ETF ticker symbols.<br />
<br />
<br />
<strong>Create Chart</strong><br />
<br />
Select "Insert -> Chart" then select "Vertical bar" as type of chart<br />
Right click on the chart, select "Chart Settings" then update the chart's title. Example: "1min Performance"<br />
<br />
Right click on the chart, click on "Select Cells", select the cells in the fourth row (Example: A4:E4) then click "OK" on the new "Select Cells" control.<br />
Right click on the chart, click on "Select X-Axis Cells", select the cells in the first row (Example: A1:E1) then click "OK" on the new "Select Cells" control.<br />
<br />
Your chart is ready now. You can move it, edit it and watch it update in real time.<br />
<br />
<img src="http://www.quantshare.com/Images/blog/gridGraph_1.png" title="Create Graphs using the Grid Tool" /><br />
<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-654-create-graphs-using-the-grid-tool</link>
		<guid>http://www.quantshare.com/sa-654-create-graphs-using-the-grid-tool</guid>
        <pubDate> Thu, 03 Dec 2020 13:05:14 -0500 </pubDate>
     </item>  
     <item>
        <title> Profile Graphs</title>
        <description><![CDATA[ You can plot profile graphs on QuantShare by using the "PlotProfile" function. To learn more about the QuantShare programming language, please <a href="https://www.quantshare.com/sa-499-quantshare-programming-language-tutorial">check this</a>.<br />
<br />
Here is how a profile graph looks like. The graph in red displays the volume by price. By looking at the chart, you can quickly see at which price range the highest volume occurred. These could be potential support and resistance areas.<br />
<br />
<img src="http://www.quantshare.com/Images/blog/profile_1.png" title="Profile Graphs" /><br />
<br />
<br />
And here is the function used to display that profile:<br />
<span style="color:#1C74A8">PlotProfile("volume", 0, 1, 100, colorRed, colorRed, OperationSum);</span><br />
<br />
The profile function isn't designed to show only volume but can be used to display anything.<br />
<br />
Here are some examples:<br />
Number of instances where the asset closed higher (close > open) displayed per price range and for each trading year (new/different profile for each year)<br />
<span style="color:#1C74A8">PlotProfile("close > open", year() != ref(year(), 1), 1, 100, colorBlue, colorBlue, OperationSum);</span><br />
<br />
Average RSI by price range<br />
<span style="color:#1C74A8">PlotProfile("rsi(14)", 0, 1, 100, colorBlue, colorBlue, OperationAvg);</span><br />
<br />
Daily volume profile on a weekly price<br />
<span style="color:#1C74A8">PlotProfile("volume", 1, 1, 5, colorRed, colorRed, OperationSum);</span><br />
<br />
<br />
The function contains several parameters.<br />
<br />
<u>Formula</u>: Defines the profile formula<br />
For a profile graph based on volume, simply type: "volume"<br />
For a profile graph based on 25-bar simple moving average, type: "sma(25)"<br />
<br />
<u>New Profile Condition</u>: Specify when to create a new profile<br />
To display only one profile for all trading data, type: 0<br />
To display one profile for each trading bar, type: 1<br />
In a daily chart and in order to display one profile per week, type: week() != ref(week(), 1)<br />
<br />
<u>Time frame</u>: Specify the time frame used to calculate "Formula"<br />
<br />
<u>Number of buckets</u>: The number of buckets (price range) for each profile<br />
<br />
<u>Back Color</u>: The back color of profiles<br />
<br />
<u>Font/Border Color</u>: The font and border color of profiles<br />
<br />
<u>Operation</u>: Specify the operation to perform in this profile and some styles. You can separate values using the character |<br />
<br />
OperationAvg: calculate the average of the "Formula" values for each bucket<br />
OperationMax: calculate the maximum of the "Formula" values for each bucket<br />
OperationMin: calculate the minimum of the "Formula" values for each bucket<br />
OperationRank: calculate the rank of the "Formula" values for each bucket<br />
OperationSum: calculate the sum of the "Formula" values for each bucket<br />
ShowBorder: Display profile borders<br />
ShowValues: Show the value of each profile bar<br />
<br />
<u>UseRthOnly</u>: Uses data from regular trading hours only (intraday)<br />
<br />
<b>Note:</b> <br />
1/ If you have an EOD chart and you want to use intraday data in your profile graph, simply use a negative value as "Time frame". Same for Intraday charts.<br />
2/ For EOD data, time frame is expressed in days<br />
3/ For Intraday data, time frame is expressed in seconds<br />
<br />
In a future article, we will show you how to access profile data using C# and create advanced custom functions based on the profile data.<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-653-profile-graphs</link>
		<guid>http://www.quantshare.com/sa-653-profile-graphs</guid>
        <pubDate> Thu, 20 Aug 2020 11:36:01 -0400 </pubDate>
     </item>  
     <item>
        <title> More about QuantShare Programming Language</title>
        <description><![CDATA[ QS language is a very simple programming language used in QuantShare to plot lines, create indicators, composite, trading systems, watchlists, scan stocks...<br />
<br />
Previously, we created a blog post that introduces QS language. We strongly suggest you read that post before continuing here.<br />
<a href="https://www.quantshare.com/sa-499-quantshare-programming-language-tutorial">QuantShare Programming Language Tutorial</a><br />
<br />
Besides the popular and less popular indicators, there are a lot of functions that can be used in QS language to plot and detect your own pattern, formula, indicators...<br />
Many of the most basic functions were introduced in the blog post referenced in the link above.<br />
<br />
<br />
<b>Introducing the logical operators (And/Or)</b><br />
<br />
Let us begin by one example:<br />
<span style="color:#1C74A8">a = close > 10.5 AND volume > 1000;</span><br />
<br />
In the above example, the "And" operator was used (you can also use && instead). The formula assigns a value of "1" to each bar of the "a" array/vector if the close is higher than 10.5 AND the volume is higher than 1000;<br />
<br />
<span style="color:#1C74A8">b = close > 10.5 OR volume > 1000;</span><br />
<br />
The above formula assigns a value of "1" to each bar of the "a" array/vector if the close is higher than 10.5 OR the volume higher than 1000.<br />
You can use || instead of OR.<br />
<br />
If the conditions are not met then "a" would get a value of "0" on the corresponding bar.<br />
<br />
You can combine AND and OR operators. Make sure to use parentheses to make the code clean.<br />
<br />
<u>Example</u>:<br />
<span style="color:#1C74A8">c = (close > 10.5 AND volume > 1000) OR (close > 10.5 AND volume < 1000);</span><br />
<br />
Here is how the values of the a, b and c variables will look like given a sample close and volume data.<br />
<br />
<img src="http://www.quantshare.com/Images/blog/qs_language_1.png" title="QuantShare Programming Language Tutorial" /><br />
<br />
<br />
<b>Referencing another time-series</b><br />
<br />
When analyzing a particular formula, whether it is for charting, backtesting or screening, that formula is always applied for each symbol individually.<br />
<br />
When the formula finds the variable "close", the engine will use the close price of the currently analyzed security.<br />
<br />
The "GetSeries" function allows you to reference an external security time-series.<br />
<br />
<span style="color:#1C74A8">closeSPY = getseries("spy", close);</span><br />
<br />
This will get the close series of the "SPY" ETF and associate it with the "closeSPY" variable.<br />
<br />
Now, let us analyze the following formula:<br />
<br />
<span style="color:#1C74A8">closeSPY = getseries("spy", close);<br />
a = close / closeSPY;<br />
filter = sma(a, 10);</span><br />
<br />
If you are running this formula using the screener tool and you are analyzing say two symbols (IWM and QQQ) then screener will run that formula on these two symbols.<br />
<br />
The first run will calculate the ratio of the IWM close series to the SPY close series and then return the 10-bar moving average of that ratio.<br />
The second run will calculate the ratio of the QQQ close series to the SPY close series and then return the 10-bar moving average of that ratio.<br />
<br />
Note how the SPY series is fixed here since we explicitly referenced the ticker symbol "SPY" in the "GetSeries" function.<br />
<br />
<br />
<b>Indicators Crossover</b><br />
<br />
Often you need to detect when a time-series or an indicator crosses above or below another time-series, indicator or an horizontal line.<br />
<br />
This can be easily achieved using the "cross" formula. Below are three examples:<br />
<br />
// Returns 1 for each trading bar where the close price crosses above 20. The close price must be lower than 20 in the previous bar and higher than 20 in the current bar<br />
<span style="color:#1C74A8">a = cross(close, 20);</span><br />
<br />
// Returns 1 for each trading bar where the close price crosses above its 20-bar simple moving average<br />
<span style="color:#1C74A8">a = cross(close, sma(20));</span><br />
<br />
// Returns 1 for each trading bar where the close price crosses below its 20-bar simple moving average (The opposite of the previous line)<br />
// This is equivalent to 20-bar simple moving average crossing above the close price<br />
<span style="color:#1C74A8">a = cross(sma(20), close);</span><br />
<br />
<br />
<b>Tips</b><br />
<br />
In the QuantShare formula editor, there is a very important shortcut that allows you to display the list of available functions depending on the cursor location (start of the line, after "=" operator, inside a function parameter...). That shortcut is CONTROL+SPACE.<br />
<br />
When typing a function and after you type the first parenthesis (Example: a = rsi( ), QuantShare will display a tooltip that shows the number of parameters that the function accepts and a description of each parameter. You can also click on that tooltip to display other variations (if exists). This is in case the function accepts different numbers of parameters.<br />
<br />
As an example, the "RSI" function has two variations. One that accepts two parameters:<br />
<span style="color:#1C74A8">a = rsi(close, 14);</span> // 14-bar RSI of the close time-series<br />
<br />
And another one that accept just one parameter:<br />
<span style="color:#1C74A8">a = rsi(14);</span> // Same as above. In this case, the close time-series will be used by default<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-652-more-about-quantshare-programming-language</link>
		<guid>http://www.quantshare.com/sa-652-more-about-quantshare-programming-language</guid>
        <pubDate> Tue, 02 Jun 2020 11:51:36 -0400 </pubDate>
     </item>  
     <item>
        <title> Backtest Trading Strategies Programmatically and on Schedule</title>
        <description><![CDATA[ Using the QuantShare API, it is possible to perform many tasks programmatically. One of the things you can do is backtest and get results of a specific strategy. This can be accomplished using the Script Editor tool.<br />
<br />
To open the script editor, select "Tools -> Script Editor" then create a new script using "File -> New".<br />
<br />
To access and run backtests, you need to use the "Simulator" object. This object allows you to retrieve the list of trading systems, create trading systems, update them, backtest them and optimize them.<br />
<br />
In the script editor, type "Simulator." (without the double quotes), after typing the dot, a list of available methods will be displayed.<br />
<br />
<strong>Examples to help you get started</strong><br />
<br />
To list all your trading systems, you can for example use:<br />
<br />
<span style="color:#1C74A8">string[] ts = Simulator.GetTradingSystems(""); <br />
// Category is empty here to get all trading systems</span><br />
<br />
<br />
To create a new trading system based on an existing one (copy) then update the start date:<br />
<br />
<span style="color:#1C74A8">QSTradingSystem ts = Simulator.CreateTradingSystem("", "MyStrategy");<br />
<br />
ts.CopySettingsFromTradingSystem("", "ExistingStrategyName"); // Replace "ExistingStrategyName" with the name of an existing strategy you have<br />
<br />
ts.StartDate = new DateTime(2000, 10, 1); // Year, Month, Day<br />
<br />
ts.Save();</span><br />
<br />
<br />
To backtest a specific strategy:<br />
<br />
<span style="color:#1C74A8">SimulatorTask task = Simulator.Backtest("", "MyStrategy", true); <br />
// The last parameter indicates whether to show a report or not (Run the backtest silently)</span><br />
<br />
Note that this function returns a "SimulatorTask" variable.<br />
We can use this variable to check whether the simulation ended and to access the report programmatically.<br />
<br />
The following example will run the backtest silently then display a message with the simulation annual return:<br />
<br />
<span style="color:#1C74A8">SimulatorTask task = Simulator.Backtest("", "MyStrategy", false);<br />
<br />
while(!task.IsCompleted){<br />
App.Main.Sleep(100);<br />
}<br />
<br />
// Returns one report after a backtest (we access it using [0] next to Reports variable) and multiple reports after an optimization<br />
<br />
double annualReturn = task.Reports[0].AnnualReturn;<br />
<br />
MessageBox.Show("The strategy annual return is: " + annualReturn);</span><br />
<br />
<br />
<strong>Backtest on Schedule</strong><br />
<br />
You can schedule backtests to run at specific times or after an event (such as a new file added or updated in a directory) using the "Task Manager" tool of QuantShare.<br />
<br />
First, you need to create a script to run the backtest.<br />
<br />
- After that, open the task manager using "Tools -> Task Manager".<br />
- In the new "Task Manager" control, click on "Click here to add a task".<br />
- Specify the task trigger settings then click on "Add" button at the bottom/left corner to add the script to be executed when the task is triggered.<br />
- Name your task then click on "Add" at the bottom/right corner.<br />
<br />
The task will be added in the task scheduler of the Windows operating system and when executed will execute the script.<br />
<br />
You can even have the script open automatically QuantShare if it is closed. <br />
To enable this, check the "Execute even if application is not loaded" field in the "Add Task" form.<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-649-backtest-trading-strategies-programmatically-and-on-schedule</link>
		<guid>http://www.quantshare.com/sa-649-backtest-trading-strategies-programmatically-and-on-schedule</guid>
        <pubDate> Wed, 08 Jan 2020 11:26:12 -0500 </pubDate>
     </item>  
     <item>
        <title> QuantShare Trading Software: New Features in the 3.7.0 Version</title>
        <description><![CDATA[ The following is a presentation of the new features that were implemented in the most recent version of QuantShare, the quantitative analysis tool.<br />
<br />
Please let us know in the comments section below, which features do you want us to implement and if you have any questions about the newly added features.<br />
<br />
<br />
<strong>Bookmark Tool</strong><br />
<br />
This tool allows you to create shortcuts for your favorite chart's position.<br />
To open the bookmark tool, select "Tools" then "Bookmarks". <br />
<br />
Let us say, you entered a trade on AAPLE on Jan 2019. To save this position as a bookmark, right click on the entry date on the chart and select "Add to Bookmarks". As you soon as you hit that button, a new entry will be added in the "Bookmarks" control.<br />
Now, whenever you click on that entry in the Bookmarks control, the selected chart will load with the corresponding bookmark symbol, time frame and the chart will automatically move the bookmark date.<br />
<br />
You can specify whether to display the bookmark date on the right or left of the chart by clicking on the "Settings" button at the bottom of the "Bookmarks" control.<br />
<br />
Finally, you can organize your bookmarks by categories by simply adding new categories then dragging and dropping any bookmark into that category.<br />
<br />
<br />
<strong>GetMarketProfileData Function</strong><br />
<br />
The new GetMarketProfileData function is an advanced C# new function that allows you to access profile data within your C# custom functions created using the "Tools -> Create Functions" tool.<br />
<br />
Let us go through an example:<br />
We have the following profile function in our chart (QS language):<br />
<span style="color:#1C74A8">PlotProfile("volume", month() != ref(month(), 1), 1, 10, colorRed, colorRed, OperationAvg);</span><br />
<br />
This will plot the average volume profile each month.<br />
<br />
Now, let us use our new "GetMarketProfileData" formula to get the average volume of the first bucket and display it on a chart.<br />
We first need to use the "GetMarketProfileData" to calculate the profile, similar to what we have done with the QS language. This function returns a variable of "VectorProfile" type. This is the first line of the below C# code.<br />
After that, we just need to loop through each bar, check when the profile data is not null (that would be the first of each month in this case).<br />
Finally, we can access the first bucket value using the "BucketsY" property.<br />
<br />
<span style="color:#1C74A8">VectorProfile vp = cFunctions.GetMarketProfileData("volume", TA.Month() != TA.Ref(TA.Month(), 1), 1, 10, ProfileDataCalculation.Avg);<br />
for(int i=0;i < vp.Length;i++)<br />
{<br />
if(vp[i] != null)<br />
{<br />
result[i] = vp[i].BucketsY[0];<br />
}<br />
}</span><br />
<br />
<img src="https://www.quantshare.com/Images/blog/newversion_1.png" title="QuantShare Trading Software: New Features in the 3.7.0 Version" /><br />
<br />
<br />
<strong>Quarterly Time Frame</strong><br />
<br />
In this new version of QuantShare, you can now use quarterly as a time frame in your chart, backtests, composites and screeners.<br />
To do this, simply select "Quarterly" in the time frame control. <br />
<br />
In the composite tool for example, create a new composite, click on "Next" twice to move to the third screen. Click on "Daily" next to "Select a time frame" then select "Quarterly".<br />
<br />
<br />
<strong>Median Composite Function</strong><br />
<br />
The composite function is one of the most powerful function in QuantShare. It allows you to calculate market indicator and rank securities very easily using a single line of code.<br />
<br />
The following QS language formula, for example, calculates the average daily return for all securities in your database:<br />
<span style="color:#1C74A8">a = comp(perf(close, 1), "avg");</span><br />
<br />
And here is how to use the new 'Median' function to calculate the median daily return for all securities in your database.<br />
<span style="color:#1C74A8">a = comp(perf(close, 1), "med");</span><br />
<br />
More information about the composite function:<br />
<a href="https://www.quantshare.com/sa-140-how-to-create-market-indicators-using-the-composite-function-part-1">How to create market indicators using the composite function - Part 1</a><br />
<a href="https://www.quantshare.com/sa-144-how-to-create-market-indicators-using-the-composite-function-part-2">How to create market indicators using the composite function - Part 2</a><br />
<a href="https://www.quantshare.com/sa-160-how-to-create-market-indicators-using-the-composite-function-part-3">How to create market indicators using the composite function - Part 3 </a><br />
<a href="https://www.quantshare.com/sa-175-trading-indicators-using-the-rank-and-percentile-functions">Trading Indicators using the Rank and Percentile functions </a><br />
<a href="https://www.quantshare.com/sa-179-new-ranking-and-percentile-composite-functions">New Ranking and Percentile Composite Functions </a><br />
<br />
<br />
<strong>New Data Feed for the Indian Markets</strong><br />
<br />
With this new release, we have added support to a new real time data provider (http://globaldatafeeds.in/) that provides streaming data for Indian markets.<br />
<br />
In order to connect to Global datafeed, select "Accounts -> Connect" then "Global Datafeeds".<br />
In the new form, enter your ApiKey (that is provided by Global Datafeeds) then click on "Close".<br />
<br />
To learn more about real time features, please check the following links:<br />
<a href="https://www.quantshare.com/sa-561-presentation-of-quantshare-s-new-real-time-version">Presentation of QuantShare's new Real Time Version</a><br />
<a href="https://www.quantshare.com/sa-615-real-time-quote-sheets-with-quantshare">Real-Time Quote Sheets with QuantShare</a><br />
<br />
Note that the data feed is available only in the premium version of QuantShare. <br />
Please send us an email if you want to upgrade from the advanced to the premium version.<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-647-quantshare-trading-software-new-features-in-the-370-version</link>
		<guid>http://www.quantshare.com/sa-647-quantshare-trading-software-new-features-in-the-370-version</guid>
        <pubDate> Mon, 09 Dec 2019 10:11:25 -0500 </pubDate>
     </item>  
     <item>
        <title> Compare Multiple Securities in a Single Chart </title>
        <description><![CDATA[ In any single chart, you can add tickers to compare performance between two or more assets.<br />
<br />
To do so, right click on the chart, select "Edit Formula" then you can either type the formula directly or have the wizard tool write it for you. To do this, click on the "Add Indicator" button, select the "External Symbol" tab, type a ticker symbol, enable "Compare with current symbol" then click on "OK".<br />
The above steps would plot a new OHLC graph on the top of the existing one.<br />
<br />
In the previous screen, you also have the ability to plot a line instead of an OHLC chart by clicking on the "What to Show?" field and selecting "Close".<br />
<br />
Do the above steps again to add another symbol to the chart and thus compare multiples securities at once.<br />
<br />
If you do not want to compare the performance of these securities but rather display each graph using a different scale, click on the "Chart" icon at the bottom of the chart (near the "S" button) and select "Set Linear Scale".<br />
<br />
Finally, if you want that the different securities use the same scale (Not very useful in comparing assets however), right click on the chart and select "Edit Formula".<br />
<br />
In the new form toolbar, there is a left and a right button. These will show you the different formulas used by the chart. <br />
<br />
NB: A chart can have one or multiple formulas. Different formulas is used simply to differentiate between the different indicators displayed on that chart. You can combine all formulas in a single one, that does not change the display.<br />
<br />
Now, note that the function that will display the OHLC chart of the external symbol is "PlotCandleStick1". The last parameter of the function will allow you to specify style settings. All you have to do here is replace "StyleOwnScale" with "StyleSymbolNone".<br />
<br />
NB: Once you put the cursor at the last parameter (or any other parameter position), use CONTROL+SPACE to display the list of available values for that parameter. This function could be very useful when writing QS language formulas.<br />
<br />
If you want to learn more about QS language, please check the following blog post:<br />
<br />
<a href="https://www.quantshare.com/sa-499-quantshare-programming-language-tutorial">QuantShare Programming Language Tutorial</a><br />
 ]]></description>
        <link>http://www.quantshare.com/sa-646-compare-multiple-securities-in-a-single-chart</link>
		<guid>http://www.quantshare.com/sa-646-compare-multiple-securities-in-a-single-chart</guid>
        <pubDate> Thu, 10 Oct 2019 11:49:29 -0400 </pubDate>
     </item>  
     <item>
        <title> Dynamic Position Sizing in your Trading System</title>
        <description><![CDATA[ In QuantShare, there are two ways to create dynamic position sizing strategies. The easiest method is using the QS programming language and the advanced one is using the money management tool. This article is about the former method.<br />
<br />
If you are not familiar with the QS programming language, we strongly suggest you take a look at this article:<br />
<a href="https://www.quantshare.com/sa-499-quantshare-programming-language-tutorial">QuantShare Programming Language Tutorial</a><br />
<br />
You also need to learn how to create trading strategies before continuing with this tutorial:<br />
<a href="https://www.quantshare.com/sa-582-the-ultimate-guide-to-create-trading-systems-in-quantshare">The Ultimate Guide to Create Trading Systems in QuantShare </a><br />
<br />
<br />
<strong>Dynamic Position Sizing</strong><br />
<br />
By default, a trading system will allocate an equal amount to each position. The amount is calculated by taking the strategy equity and dividing it by the maximum number of allowed positions.<br />
<br />
If you have 100,000 USD in your portfolio and you set up 5 as number of positions, then QuantShare will buy 20,000 USD worth of shares for the new position.<br />
<br />
<img src="http://www.quantshare.com/Images/blog/possizing_1.png" title="Dynamic Position Sizing in your Trading System" /><br />
<br />
<br />
You can change this logic using a single line in your trading system QS language formula. All you need to do is use the "SetSimPosSize" function and define how you want QuantShare to invest in each new position.<br />
<br />
The "SetSimPosSize" has two parameters:<br />
Trade Size: Could be an amount in dollars or a percentage value depending on the second parameter<br />
Position Size Type: The position sizing type or technique to use. Possible values are: _DollarValue, _PercentageOfEquity, _Shares<br />
<br />
<br />
Simple example to buy a fix dollar amount ($10,000) for each new position:<br />
<span style="color:#1C74A8">SetSimPosSize(10000, _DollarValue);</span><br />
<br />
To buy a fixed number of shares (Example: 10 shares) use:<br />
<span style="color:#1C74A8">SetSimPosSize(10, _Shares);</span><br />
<br />
To buy 10% of the portfolio equity for each new position use:<br />
<span style="color:#1C74A8">SetSimPosSize(10, _PercentageOfEquity);</span><br />
<br />
Of course you can use the QS language to create advanced position sizing techniques. For example, you can instruct QuantShare to buy 50% of equity for SPY and 10% for any other asset. Here is how:<br />
<span style="color:#1C74A8">pos = iff(stringequal(name(), "SPY"), 50, 10);<br />
SetSimPosSize(pos, _PercentageOfEquity);</span><br />
<br />
<br />
<strong>Money Management</strong><br />
<br />
For advanced position sizing techniques, you can use the money management tool. This tool allows you to implement C# based scripts that catch different trading events (OnStartSimualtion, OnEndPeriod, OnNewPosition...) and perform different actions such as: Increase the number of shares to be bought, scale-in/out a position...<br />
<br />
Here are some examples of position sizing techniques implemented using the money management tool:<br />
<a href="https://www.quantshare.com/sa-411-5-position-sizing-techniques-you-can-use-in-your-trading-system">5 position sizing techniques you can use in your trading system</a><br />
<br />
And here is how to create a scale-in trading strategy and optimize it (also using the money management script):<br />
<a href="https://www.quantshare.com/sa-484-money-management-scale-in-trading-strategy">Money Management: Scale-in Trading Strategy</a><br />
<a href="https://www.quantshare.com/sa-491-money-management-optimize-the-scale-in-strategy">Money Management: Optimize the scale-in strategy</a><br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-645-dynamic-position-sizing-in-your-trading-system</link>
		<guid>http://www.quantshare.com/sa-645-dynamic-position-sizing-in-your-trading-system</guid>
        <pubDate> Mon, 01 Apr 2019 06:13:44 -0400 </pubDate>
     </item>  
     <item>
        <title> How to Create an Automated Trading System in QuantShare</title>
        <description><![CDATA[ In QuantShare, an automated trading system or ATS is a portfolio that can generate orders and submit them automatically to your broker based on specific rules defined in a  <br />
trading system.<br />
<br />
In order to create an automated trading strategy, you will need to create a trading system. The trading system contains all the logic (buy/sell rules, money management...) behind  <br />
the ATS.<br />
<br />
The following blog posts can help you get started with implementing and creating your own trading systems:<br />
<br />
<a href="https://www.quantshare.com/sa-499-quantshare-programming-language-tutorial">QuantShare Programming Language Tutorial</a><br />
<a href="https://www.quantshare.com/sa-582-the-ultimate-guide-to-create-trading-systems-in-quantshare">The Ultimate Guide to Create Trading Systems in QuantShare</a><br />
<a href="https://www.quantshare.com/sa-388-trading-system-buy-stocks-with-the-highest-sharpe-ratio>Trading System: Buy stocks with the highest Sharpe ratio</a><br />
<a href="https://www.quantshare.com/sa-456-how-to-build-and-backtest-a-robust-stock-trading-system">How to build and backtest a robust stock trading system</a><br />
<a href="https://www.quantshare.com/sa-586-let-me-show-you-how-to-create-hundreds-of-profitable-trading-systems">Let me Show You How to Create Hundreds of Profitable Trading  <br />
Systems</a><br />
<a href="https://www.quantshare.com/sa-572-how-to-optimize-a-trading-system-with-thousands-of-billions-of-combinations">How to Optimize a Trading System with Thousands of  <br />
Billions of Combinations</a><br />
<br />
Once you have implemented/backtested your intraday trading system and are satisfied with the results. The next step would be to create an automated trading system (ATS) from this  <br />
system.<br />
<br />
<strong>To do this</strong>:<br />
<br />
- Select "Portfolio -> Portfolio" from the menu.<br />
<br />
<img src="http://www.quantshare.com/Images/blog/ats_1.png" title="How to Create an Automated Trading System in QuantShare" /><br />
<br />
<br />
- Click on "New" to create a new portfolio<br />
- Specify the starting capital then select the kind of portfolio you want to create.<br />
<br />
<u>Manual</u>: A portfolio where you can send orders and add positions manually<br />
<u>End-Of-Day</u>: A portfolio based on a trading system specifically designed for End-Of-Day data. You will be able to click on a button to generate signals then another button to send  <br />
orders to your broker.<br />
<u>Automated Trading System</u>: A portfolio based on a trading system specifically designed for intraday data<br />
<br />
<img src="http://www.quantshare.com/Images/blog/ats_2.png" title="How to Create an Automated Trading System in QuantShare" /><br />
<br />
<br />
- Select "Automated Trading System" then click on "Next"<br />
- Click on "Add Trading System" then select the trading system you want to add to your ATS<br />
<br />
Make sure that the number of symbols does not exceed the maximum number of streaming symbols allowed by your broker or data feed.<br />
<br />
From the same form, you can update your trading system by clicking on "Click here to update" next to "Trading System".<br />
<br />
- Click on "Next"<br />
<br />
Here, we will define the time frame as well as the real-time data source.<br />
<br />
If we select "10m" (10 minutes) as time-frame then our strategy buy/sell rules will be executed each time a new 10-min bar is formed.<br />
<br />
If you want the strategy to execute on each tick, then all you have to do is select "Tick" as time frame.<br />
<br />
Under the "Time frame", check "Real-time" then select the data source to get real time tick data to feed your ATS. This could be your broker feed (Interactive Brokers) or another  <br />
data feed (IEX, IQFeed, Barchart, Bloomberg, Reuters Xenith...).<br />
<br />
<img src="http://www.quantshare.com/Images/blog/ats_3.png" title="How to Create an Automated Trading System in QuantShare" /><br />
<br />
<br />
Checking the "Analyze on each incoming tick" instructs QuantShare to execute the strategy buy/sell rules on each tick while at the same time working with the 10 minutes bar  <br />
series (example).<br />
<br />
To give you an example, let us say our trading system formula is as follow:<br />
<span style="color:#1C74A8">buy = rsi(14) > 70;<br />
sell = rsi(14) < 30;</span><br />
<br />
RSI will be calculated based on the past fourteen 10-min bars. By checking "Analyze on each incoming tick". The formula will be analyzed on each incoming tick. The previous bars  <br />
will be the same, however the last bar (most recent one) will update on each incoming tick.<br />
You can display these rules on a real time chart to have a visual confirmation of the changes.<br />
<br />
Here is a brief description of the different options under the ATS Settings / Startup tabs:<br />
<u>Close positions when ATS is stopped</u>: Instructs QuantShare to close any opened position when you stop your ATS<br />
<u>Maximum bars to load</u>: This is the number of bars to load for each security when you start your ATS<br />
<u>Wait before starting AT</u>: The number of seconds to wait before effectively running the ATS (After you click on the "Start" button). During this time, QuantShare can build bars and  <br />
backfill data.<br />
<u>Minimum bars</u>: Minimum number of bars a security needs before your ATS can start trading that security<br />
<u>Force backfill at startup</u>: Backfill every analyzed security when starting the ATS<br />
<br />
- Click on "Next" to move to the last screen<br />
<br />
Here we will define the broker that the ATS will use when submitting orders.<br />
<br />
- Uncheck "Enable Simulated Mode" (otherwise, orders execution will be simulated using the real time data defined in the previous screen)<br />
- Select the broker (Currently only Interactive Brokers is supported. IB must also be connected).<br />
<br />
Note: If the "Enable Simulated Mode" is disabled, close the Portfolio form, select "Accounts -> Real time settings", select the "Trading" tab then uncheck "Simulated Trading".<br />
<br />
- Click on "Finish" then name your automated trading system.<br />
<br />
To start the ATS, click on the "Start Automated Strategy" at the top on the right panel.<br />
<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-644-how-to-create-an-automated-trading-system-in-quantshare</link>
		<guid>http://www.quantshare.com/sa-644-how-to-create-an-automated-trading-system-in-quantshare</guid>
        <pubDate> Thu, 17 Jan 2019 10:46:40 -0500 </pubDate>
     </item>  
     <item>
        <title> QuantShare Trading Software: New Features in the 3.6.0 Version</title>
        <description><![CDATA[ The following article introduces the new features implemented in version 3.6.0 of QuantShare.<br />
<br />
In the comments section, at the bottom, please tell us which feature would you like to know more about.<br />
<br />
Note that the first two features concern only the premium version.<br />
<br />
<br />
<strong>Free Real Time Feed</strong><br />
<br />
Investors Exchange (IEX) is a stock exchange based in the United States. IEX provides free real time data to U.S. stocks as well as historical data for the past 30 days.<br />
The new version of QuantShare has added the ability to connect and stream data free from the IEX Exchange real time feed.<br />
<br />
Select "Accounts -> Connect" then select "IEX Exchange" to open the IEX feed.<br />
<br />
You can check instructions here to find how to display real time charts, quote sheets, alerts...<br />
<a href="https://www.quantshare.com/sa-561-presentation-of-quantshare-s-new-real-time-version">Presentation of QuantShare's new Real Time Version</a><br />
<a href="https://www.quantshare.com/sa-591-create-realtime-quote-sheets-with-the-watchlist-tool">Create Realtime Quote Sheets with the Watchlist Tool</a><br />
<a href="https://www.quantshare.com/sa-615-real-time-quote-sheets-with-quantshare">Real-Time Quote Sheets with QuantShare</a><br />
<a href="https://www.quantshare.com/sa-566-real-time-alerts-support-and-resistance-lines-breakout">Real Time Alerts: Support and Resistance Lines Breakout</a><br />
<a href="https://www.quantshare.com/sa-587-how-to-create-a-custom-real-time-table-using-qs-trading-software">How to Create a Custom Real-Time Table using QS Trading Software</a><br />
<br />
<br />
<strong>Custom Real Time Feed</strong><br />
<br />
In this new release, we have added the ability to create your own custom real time feed using the script editor.<br />
<br />
To open the custom real time feed, select "Accounts -> Connect" then custom feed.<br />
You can check instructions above on how to create watchlists, charts and quote sheets using this real time feed.<br />
<br />
The custom real time provider can be feed with data using the script editor.<br />
<br />
The following is an example:<br />
- Select "Tools" then "Script Editor"<br />
- Select "File -> New" then type a new name for your script<br />
- Type the following script to pass tick data to GOOG<br />
<span style="color:#1C74A8">RT.SendCustomFeedEvent("GOOG", DateTime.Now, 0, 200, 10);</span><br />
<br />
The data passed is a trade of $200 with a volume of 10.<br />
<br />
Here is the explanation of the different parameters:<br />
1/ Ticker symbol<br />
2/ Tick date and time<br />
3/ Tick type (0 for a trade, 1 for an ask update and 2 for a bid update)<br />
4/ Price<br />
5/ Volume<br />
<br />
<br />
<strong>Regime Tool</strong><br />
<br />
Some improvements have been done to the "Regime" tool. That tools allow you to quickly see the how your strategy performs under different market regimes.<br />
<br />
You need to backtest a strategy first. After that click on the "Regimes" tab in the simulation report. <br />
Set the market and volatility symbols. Example: SPY (S&P 500 ETF) for the market symbol.<br />
Click on "Calculate" then select any market regime.<br />
On the right panel, you will see the return of your strategy if it was invested only during that market regime.<br />
<br />
<br />
<strong>DrawItem Function</strong><br />
<br />
DrawItem is a QS language function that allows you to get a drawing item value for each bar. <br />
Let us say you draw a line and you want to create an indicator that returns true or 1 when the stock price is above that line.<br />
<br />
Here is how to do that:<br />
- Create an extended trend line for example<br />
- Right click on it, select "Settings" and take note of its name<br />
- In the formula editor (Right click on the chart then select "Edit Formula"), type the following formula:<br />
<span style="color:#1C74A8">a = close > DrawItem("643162", "Line"); // Assuming "643162" is the drawing item name<br />
plot(a, "");</span><br />
<br />
Note that you can also directly create an alert based on that line by right clicking on it then selecting "Create Alert".<br />
<br />
The "DrawItem" function was implemented in a previous version of QuantShare. Previously it was working only when the drawing item is located in the first pane.<br />
In the current version we added the ability to reference drawing data on any pane.<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-643-quantshare-trading-software-new-features-in-the-360-version</link>
		<guid>http://www.quantshare.com/sa-643-quantshare-trading-software-new-features-in-the-360-version</guid>
        <pubDate> Wed, 17 Oct 2018 05:51:32 -0400 </pubDate>
     </item>  
     <item>
        <title> 6 New Ways to Download Free Intraday Data for the U.S. Stock Market</title>
        <description><![CDATA[ Recently we updated our very popular blog post about <a href="https://www.quantshare.com/sa-620-10-new-ways-to-download-historical-stock-quotes-for-free">different ways to download free EOD data</a>. We removed the data sources that are no longer working and added new ones.<br />
<br />
Today we decided to do the same to the <a href="https://www.quantshare.com/sa-426-6-ways-to-download-free-intraday-and-tick-data-for-the-us-stock-market">old list of free intraday data providers</a>, so here is the updated list:<br />
<br />
<br />
<strong>Google Finance</strong><br />
<br />
Google Finance is one of the intraday data source that was listed in the previous article. <br />
<br />
In order to download data, you need to use the following URL:<br />
The URL format is: https://www.google.com/finance/getprices?i=[PERIOD]&p=[DAYS]d&f=d,o,h,l,c,v&df=cpct&q=[TICKER]<br />
<br />
[PERIOD]: Interval or frequency in seconds (60 means 1-min)<br />
[DAYS]: Historical data period, where "10d" means that we need historical stock prices data for the past 10 days.<br />
[TICKER]:Ticker symbol of the stock<br />
<br />
Here is an example: <br />
https://www.google.com/finance/getprices?i=60&p=10d&f=d,o,h,l,c,v&df=cpct&q=GOOG<br />
<br />
Note that the data is available for several countries. You can find the full list here:<br />
https://www.google.com/intl/en_ca/googlefinance/disclaimer/?sa=X&ved=0ahUKEwiSt8DTkaTcAhVs6IMKHbDXD2oQ1AEIUg<br />
<br />
You can get data in QuantShare using the following downloader: <a href="https://quantshare.com/item-733-intraday-data-for-us-stocks">Intraday Data for US Stocks</a><br />
<br />
<br />
<strong>Yahoo Finance</strong><br />
<br />
Yahoo was also listed in the previous article and it is one of most used data sources for stock data.<br />
It allows you to download intraday data for several stock markets. <br />
You can get data for about 62 exchanges, however, unlike the Google downloader which gets data for the past 10 days, the Yahoo one provides data only for past five days.<br />
<br />
Symbol Lookup: <a href="https://finance.yahoo.com/q?s=&ql=1">https://finance.yahoo.com/q?s=&ql=1</a><br />
<br />
You can get data in QuantShare using the following downloader:  <a href="https://quantshare.com/item-734-intraday-quotes-for-major-stock-exchanges">Intraday Quotes for Major Stock Exchanges</a><br />
<br />
<br />
<strong>AlphaVantage</strong><br />
<br />
AlphaVantage is a new free API provider for historical, intraday and real time data on stocks.<br />
<br />
In order to use their API, you need to register and get a free API key on their website.<br />
<br />
Their documentation can be found here:<br />
https://www.alphavantage.co/documentation/<br />
<br />
Example of usage:<br />
https://www.alphavantage.co/query?function=TIME_SERIES_INTRADAY&symbol=MSFT&interval=1min&apikey=demo<br />
<br />
In the above example, MSFT (Microsoft) ticker symbol is used. You will also need to replace the apikey (demo) with your own key.<br />
<br />
You can use QuantShare to download real time intraday data using the Alphavantage downloader:<br />
<a href="https://www.quantshare.com/item-1764-intraday-historical-data-alphavantage">Intraday Historical Data - Alphavantage</a><br />
<br />
<br />
<strong>IEX</strong><br />
<br />
IEX (Investors Exchange) is a stock exchange based in the United States. It offers free real time, end-of-day and Intraday data.<br />
<br />
You can easily download 1-min data without any API key by using the following URLs:<br />
https://api.iextrading.com/1.0/stock/aapl/chart/date/20180629 (Data available for the past 30 calendar days).<br />
<br />
To get the most recent day data (include real time updates):<br />
https://api.iextrading.com/1.0/stock/aapl/chart/1d<br />
<br />
<u>Note</u> that the new premium version of QuantShare supports the free IEX real time feed.<br />
<br />
<br />
<strong>Finam</strong><br />
<br />
Finam is a Russian website that provides data for the stock, futures, ETF and Forex markets. The data is available for only very highlight capitalized securities, however for these securities you can download several months worth of tick data.<br />
<br />
Here is how to download stock data:<br />
<br />
- Use Google translate to translate this Russian website<br />
- Browse the following URL: https://www.finam.ru/analysis/profile041CA00007/default.asp<br />
- In the top form, select "U.S. Stocks (BATS)" then select a stock (Example: Exxon Mobil)<br />
- Select the start/end dates and frequency (Example: 20.04.2012 -> 24.04.2012 and tick data)<br />
- Click on the "Get the file" button to download stock data in CSV format<br />
<br />
<br />
<strong>Stooq</strong><br />
<br />
Stooq is a company based on Poland offering a financial portal and the ability to display data for numerous securities.<br />
<br />
Previously, Stooq was offering the ability to get 5-min data in CSV and Metastock format for all securities in a single file.<br />
Unfortunately, that ability is no longer available. However, you can still get data per symbol by browsing a security URL:<br />
https://stooq.com/q/a2/?s=^spx&i=1&t=c&a=lg&z=530&ft=201807101819&l=0&d=1&ch=0&f=0&lt=58&r=0&o=1  (Example for ^SPY)<br />
<br />
Click on the "csv" button at the bottom to download the data.<br />
<br />
<br />
<strong>Here is a table that summarizes these different free intraday data providers:</strong><br />
<br />
<img src="http://www.quantshare.com/Images/blog/free_intraday_1.png" title="6 New Ways to Download Free Intraday Data for the U.S. Stock Market" /><br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-636-6-new-ways-to-download-free-intraday-data-for-the-us-stock-market</link>
		<guid>http://www.quantshare.com/sa-636-6-new-ways-to-download-free-intraday-data-for-the-us-stock-market</guid>
        <pubDate> Wed, 25 Jul 2018 12:26:13 -0400 </pubDate>
     </item>  
     <item>
        <title> Lock, Link and Undock your Charts</title>
        <description><![CDATA[ These are three features you can use on QuantShare to help you get the most out of your charts.<br />
In the following article, we are going to explain you each feature and how to apply it to your charts.<br />
<br />
<br />
<strong>How to Lock a Chart</strong><br />
<br />
This feature offers you the ability to lock a chart to a specific symbol. All you have to do is select a symbol from the "Select a symbol" combo-box at the top then click on the "S" link at the bottom of the chart you want to lock.<br />
<br />
After the new menu opens, click on "Lock Chart" and the "S" link will become "L" with a dark background. This tells you that the current chart is locked.<br />
<br />
Once a chart is locked, it will stick to that symbol no matter which symbol you select.<br />
Note that by default, all charts are updated automatically to the ticker symbol you select.<br />
<br />
<br />
<strong>How to Link a Chart</strong><br />
<br />
You can link charts by symbol or by time-frame. To link a chart by symbol, click on the "S" link at the bottom of the chart then select a link color. Do the same to all the charts you want to be linked together (have the same link color).<br />
<br />
All charts with the same link color are linked and thus each time you select one of these charts then update the active symbol, only these linked charts will be updated (Symbol Link).<br />
<br />
To link a chart by a time-frame, click on the "T" link at the bottom of the chart then select a link color.<br />
If the charts are time-frame linked then they each time you update the time-frame of one of these linked chart, all other charts with the same link color will be updated with the same time frame.<br />
<br />
Note that by default, changing the time frame or period of a chart does not change any other charts time frame.<br />
<br />
<br />
<strong>How to Undock a Chart</strong><br />
<br />
By undocking a chart, you allow it to move outside the boundaries of QuantShare main form. The undocked chart will no longer be part of the main application form. This will allow you for example to make that chart visible while hiding (minimizing) the main application form.<br />
<br />
To undock a chart, right click on it then select "Windows Type" then "Floating Window".<br />
<br />
By default, a chart is in the "MDI Window" state. Changing it to the "Owned Window" type will allow you to move that chart outside the boundaries of the main form. However, unlike the "Floating Window" type, the chart will still belong to the main form.<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-621-lock-link-and-undock-your-charts</link>
		<guid>http://www.quantshare.com/sa-621-lock-link-and-undock-your-charts</guid>
        <pubDate> Sat, 02 Jun 2018 03:16:07 -0400 </pubDate>
     </item>  
     <item>
        <title> 10 New Ways to Download Historical Stock Quotes for Free</title>
        <description><![CDATA[ Few years ago, we created a post that lists several websites where you can download historical stock quotes for free. Since then, several of these data providers changed their download URL or simply stopped providing the data.<br />
Here is an updated list of ten new websites that allow you to download free historical data for U.S. stocks.<br />
<br />
<br />
<strong><a href="https://www.alphavantage.co/query?function=TIME_SERIES_DAILY&symbol=GOOG&apikey=demo">AlphaVantage</a></strong><br />
AlphaVantage is a leading provider of free APIs for historical and real time data on stocks, physical and crypto currencies,.<br />
All you have to do is register to get your free API then take a look at their documentation:<br />
https://www.alphavantage.co/documentation/<br />
<br />
To export historical daily quotes, here is the URL that you need to request:<br />
https://www.alphavantage.co/query?function=TIME_SERIES_DAILY&symbol=[SYMBOL NAME]<br />
&apikey=[API KEY]<br />
<br />
You can use QuantShare to download real time historical and intraday data using the Alphavantage downloaders:<br />
<a href="https://www.quantshare.com/item-1764-intraday-historical-data-alphavantage">Intraday Historical Data - Alphavantage </a><br />
<a href="https://www.quantshare.com/item-1765-daily-historical-data-alphavantage">Daily Historical Data - Alphavantage </a><br />
<br />
<br />
<strong><a href="http&#58;//markets.financialcontent.com/stocks/action/gethistoricaldata?Month=12&Symbol=GOOG&Range=300&Year=2017">Financial Content</a></strong><br />
Financial content is a very popular data provider that is used by several websites and companies. Here is the URL to get historical data <br />
http&#58;//markets.financialcontent.com/stocks/action/gethistoricaldata?Month=12<br />
&Symbol=[SYMBOL NAME]&Range=300&Year=2017<br />
<br />
<br />
<strong><a href="https://api.tiingo.com/tiingo/daily/GOOG/prices?startDate=2012-1-1&endDate=2016-1-1">Tiingo</a></strong><br />
Tiingo is another data provider that allows you to download historical daily data free using their API.<br />
Documentation can be found here:<br />
https://api.tiingo.com/docs/tiingo/daily#Software<br />
<br />
And here is the API call format to retreive EOD data:<br />
https://api.tiingo.com/tiingo/daily/[SYMBOL NAME]/prices?startDate=2012-1-1<br />
&endDate=2016-1-1<br />
<br />
<br />
<strong><a href="http&#58;//app.quotemedia.com/quotetools/getHistoryDownload.csv?&webmasterId=501&startDay=1&startMonth=1&startYear=1900&endDay=17&endMonth=5&endYear=2017&isRanged=true&symbol=GOOG">Quotemedia</a></strong><br />
Quotemedia is a leading provider of financial data. It provides EOD data for US and Canadian securities via this link:<br />
http&#58;//app.quotemedia.com/quotetools/getHistoryDownload.csv?&webmasterId=501&startDay=1&startMonth=1&startYear=1900&endDay=17&endMonth=5<br />
&endYear=2017&isRanged=true&symbol=[SYMBOL NAME]<br />
<br />
<br />
<strong><a href="https://www.investopedia.com/markets/api/partial/historical/?Symbol=GOOG&Type=Historical+Prices&Timeframe=Daily&StartDate=Nov+28%2C+2017&EndDate=Dec+05%2C+2017">Investopedia</a></strong><br />
The popular world's leading source of financial content, Investopedia, also provides historical data. You can get EOD data via this link:<br />
https://www.investopedia.com/markets/api/partial/historical/?Symbol=[SYMBOL NAME]&Type=<br />
Historical+Prices&Timeframe=Daily&StartDate=Nov+28%2C+2017&EndDate=Dec+05%2C+2017<br />
<br />
<br />
<strong><a href="http&#58;//download.macrotrends.net/assets/php/stock_data_export.php?t=GOOG">Macrotrends</a></strong><br />
Macrotrends is a research platform for long term investors. Via their website, they allow exporting data for several series including U.S. securities.<br />
Here is the URL to get this data:<br />
http&#58;//download.macrotrends.net/assets/php/stock_data_export.php?t=[SYMBOL NAME]<br />
<br />
<br />
<strong><a href="http&#58;//quotes.wsj.com/GOOG/historical-prices/download?MOD_VIEW=page&num_rows=6299.041666666667&range_days=6299.041666666667&startDate=09/06/2000&endDate=12/05/2017">Wall Street Journal</a></strong><br />
The Wall Street Journal or WSJ website provides an online corverage of breaking news and current headlines from the United States and around the world.<br />
Here is the URL to export data from the WSJ website:<br />
http&#58;//quotes.wsj.com/[SYMBOL NAME]/historical-prices/download?MOD_VIEW=page<br />
&num_rows=6299.041666666667&range_days=6299.041666666667&startDate=09/06/2000<br />
&endDate=12/05/2017<br />
<br />
<br />
<strong><a href="http&#58;//www.nasdaq.com/symbol/goog/historical">Nasdaq Website</a></strong><br />
The Nasdaq official website allows you to download data for U.S. securities.<br />
To download data for APAM, browse the following URL then click on the "Download" link at the bottom:<br />
http&#58;//www.nasdaq.com/symbol/apam/historical<br />
<br />
The download cannot be easily automated but here at QuantShare we have a downloader for this.<br />
You can get it here:<br />
<a href="https://www.quantshare.com/item-578-us-historical-quotes-from-nasdaq-website">Historical Quotes from Nasdaq Website</a><br />
<br />
<br />
<strong><a href="https://finance.yahoo.com/quote/IWM/history?p=IWM">Yahoo Finance</a></strong><br />
There has been a lot of discussion about Finance Yahoo recently and how they changed their URL to prevent automatic data download.<br />
You can now download data manually from Yahoo.<br />
Example:<br />
https://finance.yahoo.com/quote/IWM/history?p=IWM<br />
Then click on the "Download Data" link.<br />
<br />
Or you can use the following QuantShare downloader to get data automatically from Yahoo servers:<br />
<a href="https://www.quantshare.com/item-463-historical-stock-market-data">Historical Stock Market Data</a><br />
<br />
<br />
<strong><a href="https://stooq.com/db/h/">Stooq</a></strong><br />
Stooq is a Poland based company and a financial portal.<br />
Data download cannot be automated, however you don't have to do that since all you need is download the entire database via a simple link.<br />
Databases can be found here:<br />
https://stooq.com/db/h/<br />
<br />
You can download data in CSV or Metastock format for several markets including U.S stocks, U.K stocks, bonds, commodities, currencies, indices, macroeconomy data...<br />
Data is available in daily, hourly and 5 minutes format.<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-620-10-new-ways-to-download-historical-stock-quotes-for-free</link>
		<guid>http://www.quantshare.com/sa-620-10-new-ways-to-download-historical-stock-quotes-for-free</guid>
        <pubDate> Thu, 22 Feb 2018 07:20:12 -0500 </pubDate>
     </item>  
     <item>
        <title> Introduction to the Events Monitor Tool</title>
        <description><![CDATA[ The "Events Monitor" is a new tool recently introducted in QuantShare. It allows you to monitor and catch different QuantShare events and generate alerts, execute scripts, send emails... based on these events.<br />
<br />
Currently we support the following events:<br />
<u>Symbol</u>: Generated when a change happens to a ticker symbol (new data, information, new drawing...)<br />
<u>NewTick</u>: Generated on a new real time tick<br />
<u>NewBar</u>: Generated on a new real time bar<br />
<u>MarketDepth</u>: Generated when market depth changes for the analyzed security<br />
<u>OrderStatus</u>: Generated when an order status changes<br />
<u>Alert</u>: Generated when a new alert is triggered<br />
<br />
Note: All events except the first one are supported only in the real time version of QuantShare.<br />
<br />
More events will be added in newer versions. Please also note that you can use the script editor (Tools -> Script Editor) to create custom events. We will discuss how to do that in the end of this article.<br />
<br />
<br />
<strong>How to Monitor Events</strong><br />
<br />
To start monitoring events, select "Tools" then "Events Monitor". This will bring a new form where you can select the events to display by clicking on the "All Events" button at the bottom. By default, all the events are displayed.<br />
<br />
At any moment, you can check the "Freeze" check box to stop updating the list.<br />
<br />
Each event comes with some attributes that are displayed in the "Values" column. The content or value of each attribute is displayed only if it is a numeric or text value. You will see something like "String[]" if the value is an array. In that case, you can access the different elements of the array using the Global script. More about this later in this article. <br />
<br />
<img src="http://www.quantshare.com/Images/blog/events_monitor_1.png" title="Introduction to the Events Monitor Tool" /><br />
<br />
<br />
<strong>How to Create an Alert based on an Event</strong><br />
<br />
To create an alert for a specific event, click on the the "Create Alert" button at the bottom of the "Events Monitor" form.<br />
<br />
<u>Name</u>: Type here the name of the event<br />
<u>Conditions</u>: Specify the conditions that must be meet in order to trigger the Alert.<br />
All conditions must be met in order to trigger the alert.<br />
For each condition, you must first specify the event name, the field or attribute to check (You can see the different attributes in the "Events Monitor" under the "Values" column), the operation (Contains or equals to) and then the "Value" that must be checked.<br />
<u>Happens within...</u>: Specify the maximum number of seconds that separate the first and the last condition<br />
<u>Notification</u>: Select here how you want to be notified when the alert is triggered<br />
<u>General Event</u>: This allows you to generate a custom event when the alert is triggered<br />
<br />
As an example, in order to create an alert when you draw something on the GOOG chart, you need to create two conditions:<br />
<br />
<span style="color:#1C74A8">Condition 1<br />
Event Name: Symbol<br />
Field: symbols<br />
Operation: Contains<br />
Value: GOOG<br />
<br />
Condition 2<br />
Event Name: Symbol<br />
Field: type<br />
Operation: Equals to<br />
Value: Drawing</span><br />
<br />
<br />
<strong>Using the Script Editor to Catch Events</strong><br />
<br />
Open "Tools -> Script Editor" to create a global script. The global script allows you to control almost everything in QuantShare. When it comes to events, you can access the following two functions:<br />
<br />
<span style="color:#1C74A8">Order.SendEvent: Send a custom event<br />
Order.SubscribeEvent: Subscribe to an event</span><br />
<br />
<u>Example 1</u>:<br />
<span style="color:#1C74A8">// Generates a new event called "Hello" that has two attributes (Type and Value).<br />
Hashtable h = new Hashtable();<br />
h.Add("Type", "message");<br />
h.Add("Value", 1);<br />
Global.SendEvent("Hello", h);</span><br />
<br />
<u>Example 2</u>:<br />
<span style="color:#1C74A8">// Display the message "Test" when the event "Hello" is received<br />
Global.SubscribeEvent("Hello", Receive);<br />
<br />
while(true) // Keep the script alive so that we can catch the "Hello" event<br />
{<br />
App.Main.Sleep(1000);<br />
}<br />
<br />
#functions#<br />
public void Receive(EventManager m, SubscribeThreadEventArgs  e)<br />
{<br />
MessageBox.Show("Test");<br />
}</span><br />
<br />
To test the above examples, create two scripts with the code in the example one and two then select the "Example 2" script, select "Settings -> Add current script to bookmark panel".<br />
Execute the script from the bookmark panel then select "Example 1" and execute it directly from the script editor by clicking on the "Execute" button in the toolbar.<br />
<br />
More information about the bookmark panel <a href="https://www.quantshare.com/how-264-what-is-the-bookmark-panel">can be found here</a>.<br />
<br />
Note that you can access the event attributes using the "e" variable of type SubsribeThreadEventArgs.<br />
That variable contains the following methods and properties:<br />
<span style="color:#1C74A8">e.Event.GetElements()<br />
e.Event.GetNumeric(string attribute)<br />
e.Event.GetValue(string attribute)<br />
e.Event.Name<br />
e.Event.Timestamp</span><br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-619-introduction-to-the-events-monitor-tool</link>
		<guid>http://www.quantshare.com/sa-619-introduction-to-the-events-monitor-tool</guid>
        <pubDate> Thu, 16 Nov 2017 06:59:16 -0500 </pubDate>
     </item>  
     <item>
        <title> How to Adjust the Time Displayed in your Intraday Charts</title>
        <description><![CDATA[ Depending on whether you want to adjust time for real time data or historical intraday data, the procedure is totally different.<br />
<br />
<b>The historical data</b> is downloaded from a specific source and the data is stored with the source time. If you are downloading intraday data from Yahoo, Google or any other data provider, the only way to change the bar's time is to edit the downloader and update the pre or post-script.<br />
<br />
Let me show you an example:<br />
- If you don't have the "Intraday Data for US Stocks" downloader then please download it from here: <ref>733</ref><br />
- Select "Download -> Download Manager" then select "Intraday Data for US Stocks"<br />
- Click on "Update" at the top of the download manager<br />
- Click on "Parser" button in the first row then on "OK" and "Next"<br />
- Click on "Next" again to see the bars date/time<br />
<br />
Now, let us suppose we want to increase the time by two hours.<br />
<br />
- Back the "CSV Settings" page (click on "Back"), click on "Post Script" button then add the following script:<br />
<br />
<span style="color:#1C74A8">for(int i=0;i < Data.Rows.Length;i++)<br />
{<br />
Data.Rows[i].Date = Data.Rows[i].Date.AddHours(2);<br />
}</span><br />
<br />
- Click on "OK" then "Next". The time is not updated on this screen (because at that moment, post script is not executed yet)<br />
- Click on "Next" again then on "Show Output".<br />
<br />
<br />
<b>In real time mode</b>, the time is also specified by the data source but can be changed on fly using exchange settings.<br />
<br />
First, at the bottom of the chart, click on "Not live" at the bottom/left corner (in case the chart is not in live mode) then select a data feed (premium version only).<br />
Click on the circle at the bottom/right corner then on "Exchange Settings".<br />
<br />
<img src="http://www.quantshare.com/Images/blog/exchangetime_1.png" title="How to Adjust the Time Displayed in your Intraday Charts" /><br />
<br />
<br />
If no exchange is specified for your ticker symbol, then "Default" exchange will be selected. You can check your symbol Market/Exchange by selecting "Symbol -> Update Symbol". If that Market/Exchange is not available in the list, then you will need to add it here "Symbol -> Categories".<br />
<br />
In the "Exchange" tab, you can define the exchange daylight saving, the time zone, the session time start and the sync time (which is usually the same as the time start).<br />
The sync time is the time that is used as a reference to build bars.<br />
<br />
For example:<br />
If you are displaying an hourly chart and the sync time is 9:30 then the bars will have the following timestamps: ...8:30, 9:30, 10:30...<br />
If the sync time is 9:00 then the bars will have the following timestamps: ...8:00, 9:00, 10:00...<br />
<br />
In order to change the bars' time, you will need to modify the "Zone" field. Set it to the appropriate value then click on "Close".<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-618-how-to-adjust-the-time-displayed-in-your-intraday-charts</link>
		<guid>http://www.quantshare.com/sa-618-how-to-adjust-the-time-displayed-in-your-intraday-charts</guid>
        <pubDate> Thu, 01 Jun 2017 09:44:49 -0400 </pubDate>
     </item>  
     <item>
        <title> How to use QuantShare Indicators in the Grid Tool</title>
        <description><![CDATA[ In a previous post, we have introduced the grid tool and how you can use it to create real time sheets. Today, we are going to show you how to use QuantShare functions and indicators and apply them to particular cells.<br />
<br />
<br />
We are going to show you how to create and calculate in real time the relative strength index of a particular stock.<br />
<br />
- Select "Tools -> Grid -> Grid Editor".<br />
- Select the first cell "A1" then type a ticker symbol. Example: GOOG<br />
- Click on the second cell "B1" then in the above tool bar, click on the "Formulas" button<br />
<br />
A new control will open where you can add QuantShare language as well as C# formulas. <br />
<br />
For this example, we will need to create a QS language formula, so let us click on the "Add formula" button at the top.<br />
<br />
Let us name that function by typing a name next to the "Name" field. Call this function "rsi".<br />
Below that field, click on the combo box next to "Data Used" and select "Realtime" as we want to calculate the real time value of the relative strength index.<br />
In the formula editor on the right, type the following formula:<br />
<span style="color:#1C74A8">cell = Rsi(2);</span><br />
<br />
This simple formula will calculate the 2-bar relative strength index then return the result to the cell.<br />
<br />
Please note that you can add indicators by clicking on the "Add Indicator" button and you can also display the available functions/methods by using CONTROL+SPACE hotkey.<br />
<br />
By default, each QS formula in the Grid tool has two parameters by default which are the ticker symbol name and the time frame. You can add additional parameters by click on the "Add Variable/Parameter" button.<br />
Later, we can access that formula within a particular cell by calling this function:<br />
<span style="color:#1C74A8">=Formula.rsi("GOOG", 60)</span><br />
<br />
This will execute the "rsi" function we just created while passing "GOOG" as ticker symbol and 60 (1-minute) as time frame.<br />
<br />
Click on the "Compile" button at the top then close the form.<br />
<br />
- Select the second cell again "B1" then type in the above formula editor (next to "Fx" button)<br />
<span style="color:#1C74A8">=Formula.rsi(A1, 60)</span><br />
<br />
<img src="http://www.quantshare.com/Images/blog/grid_qsformula_1.jpg" title="How to use QuantShare Indicators in the Grid Tool" /><br />
<br />
<br />
Note how we replaced "GOOG" by A1. This means that the function will use the value that is returned by the A1 cell as first parameter. If you change the ticker symbol in A1, the formula in B1 will be automatically updated.<br />
<br />
The final step would be now to select a data feed for our cells. Select both cells, right click then select "Data Feed" then your data feed.<br />
<br />
To save this grid, click on "File" then "Save".<br />
<br />
You can open that grid directly in QuantShare by selecting "Tools -> Grid -> Open Grid" in the QuantShare menu then selecting the grid you just saved.<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-616-how-to-use-quantshare-indicators-in-the-grid-tool</link>
		<guid>http://www.quantshare.com/sa-616-how-to-use-quantshare-indicators-in-the-grid-tool</guid>
        <pubDate> Tue, 25 Apr 2017 05:18:36 -0400 </pubDate>
     </item>  
     <item>
        <title> Real-Time Quote Sheets with QuantShare</title>
        <description><![CDATA[ Unlike the <a href="https://www.quantshare.com/sa-609-introduction-to-the-grid-tool">Grid tool</a> that can be used to create advanced real-time tables (such as a real-time correlation matrix), the Quote sheet is a very easy to use tool that displays real time data for the securities you want to track.<br />
<br />
As with the Grid tool, the Quote sheet tool is available only in the <a href="https://www.quantshare.com/sa-561-presentation-of-quantshare-s-new-real-time-version">real-time premium version of QuantShare</a>.<br />
<br />
Open a new quote sheet by selecting "Tools" from the menu then "Quote Sheet".<br />
<br />
This will create an empty quote sheet.<br />
<br />
All you have to do now is type the ticker symbol under the "Symbol" column to display the last, net, ask, bid... data in real time for that security.<br />
The default data provider will be used to retrieve real time data. <a href="https://www.quantshare.com/index.php?option=connections">Click here for the list of data providers we currently support</a>.<br />
<br />
In the top of that list, we also support Bloomberg, Stockwatch and any data feed that supports Excel DDE or RTD technologies.<br />
<br />
To change the default data provider, right click on the quote sheet, select "Settings", click on "Settings" tab then change the "Data Feed" field.<br />
If you have multiple data feeds, you can open different quote sheets and each one could use a different feed. <br />
Unlike the grid tool where each cell can have its own data feed, all cells in a single quote sheet must be associated to only one data feed.<br />
<br />
<br />
<strong>Quote Sheet Settings</strong><br />
<br />
Right click on the quote sheet then select "Settings" to open the settings control.<br />
<br />
<u>Columns Tab</u>:<br />
<br />
Here you can define the fields you want to add to your quote sheet. To do so, simply select a field then click on the "+" button at the top.<br />
You can organize the added fields by clicking on the up and down arrows.<br />
<br />
Please note that some fields are available for a particular data feed while other not.<br />
For example, the Implied volatility, VWAP, Option call open interest, last yield... fields are available only when using Interactive Brokers as data feed.<br />
<br />
<br />
<u>Settings Tab</u>:<br />
<br />
In the "Settings" tab, you can define the quote sheet title, data feed, background color, price change color, font color, text size and divider color.<br />
<br />
If you want to specify default settings for any new quote sheet you plan to open in future, just define your settings then click on the "Save As Default" at the bottom of the quote sheet settings control.<br />
<br />
<img src="http://www.quantshare.com/Images/blog/quotesheets_1.png" title="Real-Time Quote Sheets with QuantShare" /><br />
<br />
<br />
<strong>Quote Sheet Layout</strong><br />
<br />
If you have selected to display 5 columns in your quote sheet, then these columns will be repeated if you increase the quote sheet form width. This will allow you to have two, three or more "Symbol" columns and thus the ability to display more data horizontally.<br />
<br />
Also it is important to note that the quote sheets can be docked in the main QuantShare form. All you have to do is keep pressing on the ALT key and start moving the quote sheet form. You will then see several points where you can dock the form.<br />
<br />
<br />
<strong>Import & Export Data</strong><br />
<br />
To export quote sheet data to CSV format for use with Excel or any other program, right click on the quote sheet then select "Export Data".<br />
<br />
If you want to follow multiple ticker symbols and don't want to enter them manually in the quote sheet, copy all these symbols in a text file (one symbol per line) then right click on the quote sheet and select "Import/.... Symbols".<br />
<br />
You can also drag and drop symbols from one quote sheet to another to copy them. Hold the CONTROL key then drag and drop to copy a symbol within the same quote sheet.<br />
<br />
<br />
<strong>Sorting Data</strong><br />
<br />
In the quote sheet, you have the ability to sort the data by any column by first enabling the sorting feature (Right click then click on "Enable Sorting").<br />
Once done, click on any column to start sorting the data. The data is sorted in real time. This means that if you sort the data by the ask price, the security with the highest ask price will always be displayed first/last.<br />
<br />
Also note that each time you add an empty line or a divider, a new group of stocks is created. Each group of stocks is sorted separately.<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-615-real-time-quote-sheets-with-quantshare</link>
		<guid>http://www.quantshare.com/sa-615-real-time-quote-sheets-with-quantshare</guid>
        <pubDate> Fri, 10 Mar 2017 05:18:11 -0500 </pubDate>
     </item>  
     <item>
        <title> Correlation Between Multiple Trading Systems</title>
        <description><![CDATA[ There are two ways to backtest multiple combinations of strategies in QuantShare.<br />
<br />
Initially we have implemented a tool called "Combined Trading Systems" where you can add multiple trading systems then backtest the different combinations.<br />
<br />
Later, we have added a much powerful tool called "Meta-Strategies". With that new tool, you can combine, optimize and rebalance multiple strategies as it was a single trading system (<a href="http://www.quantshare.com/sa-599-how-to-create-your-first-meta-strategy"> How to Create Your First Meta-Strategy</a>).<br />
<br />
In both tools, you can add as many strategies as you want but the problem is the time it takes to backtest all the combinations.<br />
With just 5 strategies, QuantShare would need to backtest about 31 trading systems. <br />
If you increase the number of strategies to 10, QuantShare would need to backtest about 1023 trading systems. That would take a lot of time, and that number would increase exponentially as you add more systems.<br />
<br />
<strong>In case you have many strategies</strong>, the best way to find the best combination would be to calculate the correlation between the different strategies then pick the ones that are the less correlated. Once done, you can input these strategies in the meta-strategy tool and search for the perfect combination.<br />
<br />
Here is how to perform a correlation between multiple trading systems:<br />
- Select "Analysis" then "Simulator"<br />
- In the simulator manager tool bar, select "Tools" then "Combine Trading System".<br />
<br />
In case you don't find "Tools" menu, click on the green "+" icon to expand the tool bar menu.<br />
<br />
- Click on "Add Trading System(s)"<br />
- Check the trading systems you want to include in the correlation matrix<br />
- Click on "Load Checked Item(s)"<br />
- Click on the "Correlation" button at the bottom<br />
<br />
<strong>Depending on the number of trading systems</strong> you added, wait few seconds/minutes for the calculation to be completed and the correlation matrix to be displayed.<br />
<br />
<img src="http://www.quantshare.com/Images/blog/correl_ts_1.png" title="Correlation Between Multiple Trading Systems" /><br />
<br />
<br />
In the "System Correlation" control, you can quickly check the systems that are highly correlated and those who aren't and then pick a smaller set of trading systems to combine using the meta-strategy tool.<br />
<br />
Note that you can display the daily, weekly, monthly or yearly equity correlation. You can do so by updating the "Correlation of Returns" field at the bottom.<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-614-correlation-between-multiple-trading-systems</link>
		<guid>http://www.quantshare.com/sa-614-correlation-between-multiple-trading-systems</guid>
        <pubDate> Thu, 19 Jan 2017 06:39:51 -0500 </pubDate>
     </item>  
     <item>
        <title> How to Use the Percentage Scale</title>
        <description><![CDATA[ In the last release, we have introduced a new scaling option that would change the vertical axis display from price to percentage.<br />
<br />
The percentage displayed on the chart would be the price changes compared to the first visible bar.<br />
<br />
<br />
<strong>Enable the percentage scale</strong><br />
<br />
You can choose to either enable the percentage scale for all panes or for each individual pane in a chart.<br />
<br />
To enable the percentage scale for all charts, click on the chart icon at the bottom of the chart (next to zoom in/out) then select "Set Percentage Scale".<br />
You will notice a new "%" icon at the bottom/right corner of each pane. Also notice how the Y-axis values has changed to percentage values<br />
<br />
A value of 40% indicates that the time-series (or open price for candlestick) has increased 40% since the first visible bar to the selected one.<br />
<br />
To enable the percentage scale for each pane separately, right click on a pane, select "Tools" then "Set Percentage Scale". If the "Set Percentage Scale" option is not visible this means that the pane is already in percentage scale mode.<br />
<br />
<br />
<strong>Comparing two assets</strong><br />
<br />
It is often interesting and important to compare two assets. With this new QuantShare feature, you can easily see how each asset has increased/decreased and easily compare one asset with another.<br />
<br />
Click on the "Add Indicator" button in the main pane (top/left corner of the pane) then select the "External Symbol" tab.<br />
Type a ticker symbol, make sure "Compare with current symbol" is checked then click on "OK".<br />
<br />
<img src="http://www.quantshare.com/Images/blog/percent_1.png" title="How to Use the Percentage Scale" /><br />
<br />
<br />
<strong>Comparing several time-series</strong><br />
<br />
You can perform the previous process to add more symbols and compare multiple assets.<br />
<br />
You can also compare different time-series such as moving averages, close series and any other indicators.<br />
<br />
As an example, create a new pane by right clicking on the main pane then selecting "Create new pane".<br />
Now, click on the "Add Indicator" button in the newly created pane (top/left corner of the pane) and select "All Indicators".<br />
In the "Search" input box, type "sma" then add a simple moving average.<br />
<br />
Perform the same steps and add a new simple moving average with a different period. <br />
<br />
Please note that the two moving average doesn't start at the same level and thus we cannot compare them as it is.<br />
<br />
Right click on this pane then select "Edit Formula". The left/right icons in the tool bar of the formula editor allows you to switch between the different formulas.<br />
For each "Sma" formula, replace the plot style from "StyleSymbolNone" to "StyleOwnScale" then click on the "Update Graph".<br />
<br />
Moving averages can now be compared as they both start at the same level.<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-613-how-to-use-the-percentage-scale</link>
		<guid>http://www.quantshare.com/sa-613-how-to-use-the-percentage-scale</guid>
        <pubDate> Wed, 30 Nov 2016 08:53:31 -0500 </pubDate>
     </item>  
     <item>
        <title> How to Import Metastock data into QuantShare</title>
        <description><![CDATA[ If you have a Metastock database or if your data provider delivers data in Metastock format, then you can either:<br />
<br />
- Use the "Download -> External Database" tool to allow QuantShare to read data directly from your Metastock database<br />
- Or import data from your Metastock database into the QuantShare database<br />
<br />
<br />
Although the first solution is easier to set up and maintain, the second one offer two big advantages:<br />
<br />
1/ Ability to use certain features of QuantShare such as the automated update of watchlists on new data and the ability for the Alert tool to trigger events on new data. The reason is that since QuantShare will use an external database, it will no know about any changes in the data.<br />
<br />
2/ Big speed improvement compared to reading data from the Metastock database. This is important particularly when you are optimizing a trading system and backtesting thousands of trading systems.<br />
<br />
For the first solution, please follow instructions here: http://www.quantshare.com/how-444-how-to-use-quantshare-with-metastock-data<br />
If you decide to go with the second solution, here is what you need to do:<br />
<br />
- Select "Download" then "Download Manager"<br />
- Click on "Add" at the top to create a new download item<br />
- Click on "Add Url" at the top/right corner<br />
- Under "Content Type", select "METASTOCK"<br />
- Click on "Settings" button under "Settings" column<br />
- Click on "Create a URL-Script" button<br />
<br />
Here, we will implement the code that would allow the downloader to get all Metastock sub-directories databases and parse them automatically.<br />
<br />
In the text editor, type the following script:<br />
<br />
<span style="color:#1C74A8">string path = @"C:\path_to_metastock_folder\";<br />
string[] dir = System.IO.Directory.GetDirectories(path, "*.*", System.IO.SearchOption.AllDirectories);<br />
for(int i=0;i < dir.Length;i++)<br />
{<br />
if(System.IO.Directory.GetFiles(dir[i], "EMASTER").Length > 0)<br />
{<br />
Functions.AddURL(dir[i], "");<br />
}<br />
}</span><br />
<br />
// Make sure you update the first line with the path to the Metastock main folder<br />
// The script will automatically look for all sub directories and parse the ones that contain the "EMASTER" file<br />
<br />
- Click on "OK" then "OK" again to close the "Download Settings" form.<br />
- Click on the "Parser" button under "Parser" column<br />
<br />
A list of all Metastock databases will be listed there. Select one then select a symbol to parse.<br />
<br />
<br />
<strong>Parser Settings</strong><br />
<br />
- Click on the "Add Column" as many times as need to create the following structure:<br />
<br />
Quotes -> Symbol<br />
Quotes -> Date<br />
Quotes -> Open<br />
Quotes -> High<br />
Quotes -> Low<br />
Quotes -> Close<br />
Quotes -> Volume<br />
<br />
Select semicolon as separator and MDY as "Date Type".<br />
Make sure you also check "Automatically add new symbols" if you want to add unknown symbols to your QuantShare database.<br />
<br />
Now, set the appropriate time-frame (Example: Daily or 1-min) then click on "Next". Make sure everything is correct then click on "Next" then "Finish".<br />
<br />
<img src="http://www.quantshare.com/Images/blog/metastock_1.png" title="How to Import Metastock data into QuantShare" /><br />
<br />
Please note that a download item should be created to parse only one specific time frame.<br />
If you have a daily database and a 1-min database, then you need to create a different download item for each one.<br />
<br />
<br />
<br />
<br />
<br />
<br />
 ]]></description>
        <link>http://www.quantshare.com/sa-611-how-to-import-metastock-data-into-quantshare</link>
		<guid>http://www.quantshare.com/sa-611-how-to-import-metastock-data-into-quantshare</guid>
        <pubDate> Fri, 21 Oct 2016 09:54:54 -0400 </pubDate>
     </item>  
  

</channel>
</rss>