Click here to Login

                                                   Best practices for using a Global Variable


Obuli Govindaraju
2012-02-23 08:01:19

When a global variable is set does it stay in memory until Quantshare program closes?

What is the best practice on using a global variable, should a global variable be deleted after its use to save memory?

2012-02-23 10:51:07


Best Answer
Yes, it stays in memory until QuantShare closes.

You don't have to delete a global variable unless you are storing big amount of data (Example: Several arrays)

No more messages


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"


Trading Items
Set Global Variable
The Best trading rules for the ADX technical indicator
VIDYA - Variable Index Dynamic Average
Average Stock Performance for each U.S Exchange
High to low stock pattern for the close price

How-to Lessons
How to get stocks for a particular index using the global script
How to calculate the average of a time series using the money man...
How to debug a trading system using the money management tool
How to optimize a neural network using a genetic algorithm
How to get fundamental data for U.S. Stocks

Related Forum Threads
Set Global Variable Between Strategy and AMM
Intraday Variable for 'Entry Bar' and 'First Bar Of Day'
Best way to precompute a custom formula and store it
Custom Multi-Dimensional Fitness Formula (CMDFF) for Optimizer
Global variables

Blog Posts
Charting & Scripts - Manage stock charts using the global script
How to Select the Best Market Indicator for your Trading System
QS Trading Software: Global Script
How to Download Trading Data for Certain Securities Only
Select the best ETFs combination to maximize your return and redu...

Create an account
Affiliate Program
Contact Us
Trading Forum
How-to Lessons
About Us
Terms of Use

Copyright 2015
Social Media
Follow us on Facebook
Twitter Follow us on Twitter
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.