I propose that all scripts are given the identical options with respect to period handling, and the meaning of these options should be the same in all scripts. Luckily enough, this is almost possible without changing existing scripts, with the exception, that --nb-item in display_indicator and display_signal cannot mean "number of periods loaded" (well it can, but then it has to mean that in all scripts, and not "number of periods used in analysis or graphic" which it means now more often). I have attached a pdf of the updated pod for display_indicator which describes the proposed option style. The period related options would be identical for all scripts. We also should decide whether to document the --max-loaded-item option. It can cause lots of problems if the user does not load the right number of periods. Currently it is supported in graphic.pl, and the two display scripts. However, in the latter, it is named nb-item. In graphic.pl it is not documented. My suggestion is to leave it undocumented so that we can always get rid of it if we think it is to dangerous, but users today can keep using it if they already do. Please advise. Th. > -----Original Message----- > From: Weigert, Thomas > Sent: Saturday, March 29, 2008 11:18 PM > To: 'devel AT geniustrader.org' > Subject: RE: [GT] SVN Commit r595 - trunk/Scripts > > More explanation of the latest checkin... > > I have added a method in GT::Tools, find_calculator, which sets up the > framework for running evaluations. This is used in almost every script, > but currently slightly different schemes had been used to set up the > framework, resulting in duplication of code and inconsistencies, as > discussed recently. > > I have adjusted all scripts to use the new method, and thus portions of > the script have been factored out. I have left in the inconsistent date > handling in this first stage, but it is quite apparent if you examine the > various calls to the find_calculator method: > > > find_calculator($code, $timeframe, $full, $start, $end, 200); > find_calculator($code, $timeframe, 0, $start, $end); > find_calculator($code, $timeframe, $full, $start, $end); > find_calculator($code, $timeframe, 0, $start, $end, $nb_item, > $max_loaded_items); > > But now it is easy to make them consistent, which I will do in the next > step. I will propose a systematic treatment for feedback soon.... > > Cheers, Th. >
Attachment:
display_indicator.pdf
Description: display_indicator.pdf