open icon indicating copy to clipboard operation
open copied to clipboard

plotlyhs: Can't set color of marker

Open jeevcat opened this issue 7 years ago • 1 comments

As far as I can tell, the only way to set colors for markers is by using the catColors function, as the markercolor field is defined as so:

_markercolor :: Maybe (ListOrElem Value)

I'm not really sure how to create a Color that will satisfy ListOrElem Value.

How can I set the color of all markers using Color, similar to how the (now deprecated) docs explains it?

jeevcat avatar Dec 10 '17 22:12 jeevcat

@jeevcat just in case you are still waiting for an answer to this issue, if c :: Color you can use something like defMarker & markercolor ?~ All (toJSON c)). That said, I'm not sure why plotlyhs doesn't use _markercolor :: Maybe (ListOrElem Color).

adamgundry avatar Feb 13 '18 11:02 adamgundry