Skip to content
This repository has been archived by the owner on Feb 15, 2022. It is now read-only.

resolution to .csv & .json output #1058

Merged
merged 2 commits into from
Jan 6, 2018
Merged

resolution to .csv & .json output #1058

merged 2 commits into from
Jan 6, 2018

Conversation

shr00mie
Copy link
Contributor

@shr00mie shr00mie commented Jan 6, 2018

trogdor123 got me looking at the right section where the params were being input in json. made some minor tweaks to the code and now both are outputting correctly. also ran the entire thing through auto indent to make sure all the sections were visually grouped. resolves part 2 of #1044.

trogdor123 got me looking at the right section where the params were being input in json. made some minor tweaks to the code and now both are outputting correctly.
Copy link
Owner

@DeviaVir DeviaVir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't really find the changes because of all the indentation things you changed, which I'm not sure I agree with in first place 😕

// selector should be at start before keys
if(key == "selector"){
result = input[key].normalized + result;
let buyHoldRegexp = /buy hold: (\d+\.\d+) \(/g;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why are you indenting this?

@@ -91,7 +91,7 @@ let runUpdate = (days, selector) => {
let command = `${zenbot_cmd} backfill --days=${days} ${selector}`;
console.log(`Backfilling (might take some time) ...`);
console.log(command);

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unnecessary spaces?

@@ -81,7 +81,7 @@ let runCommand = (taskStrategyName, phenotype, cb) => {
console.log(`Bad output detected`, err.toString());
console.log(stdout);
}

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unnecessary spaces?

@@ -71,7 +71,7 @@ let runCommand = (taskStrategyName, phenotype, cb) => {
console.error(stderr);
return cb(null, null);
}

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unnecessary spaces?

phenotype['sim'] = {};

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unnecessary spaces?

@@ -59,9 +59,9 @@ let runCommand = (taskStrategyName, phenotype, cb) => {
let zenbot_cmd = process.platform === 'win32' ? 'zenbot.bat' : './zenbot.sh';
let command = `${zenbot_cmd} sim ${simArgs} ${commonArgs} ${strategyArgs[taskStrategyName]}`;
console.log(`[ ${iterationCount++}/${populationSize * selectedStrategies.length} ] ${command}`);

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unnecessary spaces?

*
* Example: ./darwin.js --selector="bitfinex.ETH-USD" --days="10" --currency_capital="5000" --use_strategies="all | macd,trend_ema,etc" --population="101" --population_data="simulations/generation_data_NUMBERS_gen_X.json"
*/
* Clifford Roche <clifford.roche@gmail.com>
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd argue it looks better with a space in front of it, might be personal preference

});
};

simulateGeneration();
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

more indentation problems here

...changes - formatting.
@shr00mie
Copy link
Contributor Author

shr00mie commented Jan 6, 2018

dropped formatting. just kept changes.

Copy link
Owner

@DeviaVir DeviaVir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 nice

@DeviaVir DeviaVir merged commit f5b6b6b into DeviaVir:unstable Jan 6, 2018
DeviaVir added a commit that referenced this pull request Jan 7, 2018
* bring the recent commits to master down into unstable (#1048)

* update products.json file to newest trading pairs at binance (#1028)

* Binance changed API 24 hours to 1 hour (#1027)

* Update README

* Update README again

* add generation data to gitignore (#1012)

* binance changed their API strategy from 24 hour windows to 1 hour.

* rename periodLength to period_length (#1035)

* Change markup_pct to new markdown and markup, set commonArgs so it is included in all strategies, fix return. (#1047)

The only other occurrence is in the readme file noting the legacy aspect.

* Update darwin.js

* Added support for dema-strategy to darwin.js (#1046)

* fix bad escaping on output to console (#1045)

* Update periodLength to underscore syntax for darwin

* Missing | lead to bitwise operation being performed rather than an OR logical comparison. (#1053)

* Console Output adjustment (#1055)

* resolution to .csv & .json output (#1058)

* resolution to .csv & .json output

trogdor123 got me looking at the right section where the params were being input in json. made some minor tweaks to the code and now both are outputting correctly.

* Update darwin.js

...changes - formatting.

* darwin.js - crossover strategy (#1060)

noticed that generational output was static from gen to gen for smalen1 and smalen2. sure enough, those are coded into the strategy itself, but were left out of the darwin.js strategy config for mutation.

* Docker (#1061)

* docker fix

* Resolve docker build problems

* noop strategy: readme/links/list (#1062)

* Travis. Docker. (#1063)

* Updated minimum required node version (#1066)

It appears Zenbot wont work on anything before 8.3.0.  Updating the minimum required version, for clarity.

* Merge DemaStrats (#1067)

fixes #1064

* v4.1.0: prepare release (#1068)

* v4.1.0: prepare release

* update package-lock.json
@shr00mie shr00mie deleted the patch-1 branch January 7, 2018 05:44
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants