Click here to Login





                                                   Plot through the script editor

  0

0
Obuli Govindaraju
2011-10-22 11:13:57


Is it possible to draw stuff through the scripts from the script editor. I am unable to find any API's to do so.

Or should I use Create Functions to accomplish any plotting?



QuantShare
2011-10-23 05:43:47

  0

Which script editor are you referring to?


Obuli Govindaraju
2011-10-23 10:11:04

  0

I am referring to Script Manager or Tools > Script Editor


QuantShare
2011-10-24 04:41:24

  0

Best Answer
Yes it is possible.

Here is an example:

Chart chart = Charts.GetSelectedChart();
PaneObject pane = chart.Panes[0].CreatePaneObject("Pane");
int endIndex = chart.ChartData.EndIndex;
double value = chart.ChartData.GetTimeSeries("close")[endIndex];

ArrowObj arrow = pane.DrawArrow("Arrow1", endIndex+1, value, endIndex+1, value);
arrow.Line.Color = Color.Blue;

pane.Update();



Obuli Govindaraju
2011-10-24 14:15:19

  0

Great! So where do I find documentation for this drawing objects? I couldn't find it by clicking on the Help below the editor.


QuantShare
2011-10-25 05:16:17

  0

After you click on "pane.", a list of available functions is displayed in a list box (Help will be updated very soon)


No more messages
0




Reply:

No html code. URLs turn into links automatically.

Type in the trading objects you want to include: - Add Objects
To add a trading object in your message, type in the object name, select it and then click on "Add Objects"










QuantShare

Trading Items
Stop Loss for the N-first Trading Bars only
Decreasing the Trailing Stop Level every Trading Bar
Number of Times an Event Occurred in the First N-Minutes of a Tra...
Plot Economic Indicators on a Chart
Number of bars up to the end of the month

How-to Lessons
How to get stocks for a particular index using the global script
How to plot two different time frames in the same chart
How to plot the relative performance of several stocks/indices
How to plot a stock using different periods in the same chart
How to plot the number of stock tweets per day

Related Forum Threads
Can I update the sector and industry information in the stock dat...
Adding data to database through script
In a Script is there any way to iterate through a List-of-Symbols...
Money Management script and exit options in the wizard
Composite Tool Script Editor - Write to TXT

Blog Posts
Charting & Scripts - Manage stock charts using the global script
Working with the formula editor
Ranking stocks based on their correlation with the S&P 500 Index
Sentiment Analysis: How to measure the sentiment score of your st...
QuantShare Trading Software: New Features in the 3.4.3 Version









QuantShare
Product
QuantShare
Features
Create an account
Affiliate Program
Support
Contact Us
Trading Forum
How-to Lessons
Manual
Company
About Us
Privacy
Terms of Use

Copyright © 2024 QuantShare.com
Social Media
Follow us on Facebook
Twitter Follow us on Twitter
Google+
Follow us on Google+
RSS Trading Items



Trading financial instruments, including foreign exchange on margin, carries a high level of risk and is not suitable for all investors. The high degree of leverage can work against you as well as for you. Before deciding to invest in financial instruments or foreign exchange you should carefully consider your investment objectives, level of experience, and risk appetite. The possibility exists that you could sustain a loss of some or all of your initial investment and therefore you should not invest money that you cannot afford to lose. You should be aware of all the risks associated with trading and seek advice from an independent financial advisor if you have any doubts.