Skip to content

Instantly share code, notes, and snippets.

@nexosisops
Created January 5, 2018 17:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nexosisops/b9e616a083e953fe401ec81f2b26f1b0 to your computer and use it in GitHub Desktop.
Save nexosisops/b9e616a083e953fe401ec81f2b26f1b0 to your computer and use it in GitHub Desktop.
Nexosis Ruby Client Sample
# Submitting dataset
data = CSV.open('sales-file.csv','rb', headers: true)
NexosisApi.client.create_dataset_csv 'widget-sales', data
# Creating a forecast session
session = NexosisApi.client.create_forecast_session(
'widget-sales',
'2017-12-12',
'2017-12-22',
'daily_transaction'
)
# Retrieve forecast results
results = NexosisApi.client.get_session_results session.sessionId
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment