The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

hettlage (136) [Avatar] Offline
I'm a bit puzzled by the setting of the domain of the color scale for the iris plot. You point out that the reason for explicitly setting the domain is to avoid indeterminate behaviour. However, doesn't the expression still depend on the ordering within the csv file, so that effectively the problem persists?
Curran Kelleher (9) [Avatar] Offline
That's a great point.

I suppose this example doesn't really isolate the case where it would be useful/necessary to set the scale explicitly. In this example, the behavior is the same either way, and you're right that the ordering depends on the ordering from the CSV file.

To make it really deterministic, you'd probably want to sort the values before passing into the range.

I've encountered this need in projects where filtering is applied to the data, which depends on some configuration, and also with APIs that return results in inconsistent orders.

Thanks for the feedback! Maybe this is something I can incorporate into a future revision.