xpressinsight.scenario.InsightRestClient.update_scenario_data
Purpose
Update the values of one or more entities in an Insight scenario.
Synopsis
xpressinsight.scenario.InsightRestClient.update_scenario_data(self, scenario_id: str, updates: Iterable[EntityUpdate], force_load: bool = False)
Arguments
|
scenario_id
|
The ID of the scenario to update.
|
|
updates
|
An iterable containing objects describing the changes to make to each entity.
|
|
force_load
|
If true, the scenario state will be set to 'loaded' if it's currently unloaded.
|
Return value
This function may raise the following errors:
Example
Add 3 values to the array
NumberLabels and update the value of the scalar
Status:
>>> with ins.InsightRestClient(insight_url='http://localhost:8080/') as client:
... client.update_scenario_data('570b9100-46e3-4643-baee-2e24aa538f25', [
... ArrayUpdate('NumberLabels',
... add=pd.Series(['One', 'Two', 'Three'],
... index=pd.Index([1, 2, 3]))),
... ScalarUpdate('Status', 'INITIALIZED')])
More examples can be found in the documentation for
ArrayUpdate,
ScalarUpdate, and
IndexUpdate.
Further information
2. For indexes and arrays, scenario data updates are expressed as the changes to apply to the existing values.
3. The REST API client credentials must authorise a user with write access to the scenario and the
SCENARIO_EDIT authority.
Related topics
© 2001-2025 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation ("FICO"). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.
