get_model_results: Get Model Results

Description Usage Arguments Details Value References Examples

View source: R/models.R

Description

get_model_details Calls Model Results endpoint of API

Usage

1
2
3
4
5
6
7
8
get_model_results(
  field_id,
  model_id,
  keyToUse = awhereEnv75247$uid,
  secretToUse = awhereEnv75247$secret,
  tokenToUse = awhereEnv75247$token,
  apiAddressToUse = awhereEnv75247$apiAddress
)

Arguments

model_id

A model id to retrieve details for that specific model

keyToUse

aWhere API key to use. For advanced use only. Most users will not need to use this parameter (optional)

secretToUse

aWhere API secret to use. For advanced use only. Most users will not need to use this parameter (optional)

tokenToUse

aWhere API token to use. For advanced use only. Most users will not need to use this parameter (optional)

apiAddressToUse

Address of aWhere API to use. For advanced use only. Most users will not need to use this parameter (optional)

Details

Running a model is as simple as requesting its current results. The aWhere platform will use the information previously provided about a field and planting to generate the relevant, field-specific information. For growth stage models, the results are the current stage as well as information about the most recent and next stage.

Important: Models require the use of the Fields and Plantings APIs to store important information about a field and crop. When a Field is specified for this API, it will select the most recently created Planting record to retrieve the crop and planting date.

Value

- 3 element named list containing information on previous growth stages that have completed (previousStages), the current growth stage (currentStage) and the next growth stage(nextStage)

References

https://developer.awhere.com/api/reference/models/results

Examples

1
## Not run: get_model_results('Field1', 'BarleyGenericMSU')

aWhereAPI/aWhere-R-Library documentation built on Nov. 5, 2021, 3:35 a.m.