-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes in next release #15
Comments
Nooooooo. More changes to follow.... :-) Ta |
When I created
|
I have also created my own type for the zindex value, since it seems to really be 0 or 1 (although the docs are unclear whether other values have any possible meaning, and I could see it changing in the future):
|
Thanks for these suggestions. There is some debate in the Elm community as to the benefits of type aliasing (see, this thread for example). I am not sure I have a consistent view on the matter. My instinct would be to include more type aliases like the examples you provide, but it would appear that some people find the additional level of abstraction unhelpful. I had a look again at why I chose to create the alias For other cases (and I'd argue opacity and angle fall into this category), the semantic meaning of a parameter seems clearer and more straightforward so I feel there is less benefit in the alias.
|
On the z-index. There are a few cases where more than 1 and 0 may be needed. In the example below, three values of axis z-index are used to position x gridlines above y gridlines above circles. I don't think this could be achieved with z-indices of 1 and 0 only. zOrderTest : Spec
zOrderTest =
let
data =
dataFromColumns []
<< dataColumn "x" (nums [ 20, 10 ])
<< dataColumn "y" (nums [ 10, 20 ])
<< dataColumn "cat" (strs [ "a", "b" ])
enc =
encoding
<< position X [ pName "x", pQuant, pAxis [ axZIndex 2 ] ]
<< position Y [ pName "y", pQuant, pAxis [ axZIndex 1 ] ]
<< color [ mName "cat", mMType Nominal, mLegend [] ]
cfg =
configure
<< configuration (coAxis [ axcoGridWidth 8 ])
<< configuration (coAxisX [ axcoGridColor "red" ])
<< configuration (coAxisY [ axcoGridColor "blue" ])
in
toVegaLite [ cfg [], data [], enc [], circle [ maSize 5000, maOpacity 1 ] ] While your |
Thanks for the zindex example - it's now part of the hvega documentation (well, it will be once I get around to releasing 0.4.0.0!). I was reading the VegaLite schema documentation perhaps too literally, as it seemed to focus on 0 and 1 being the main values. I've changed ZIndex back to being an alias for Natural. |
One thing I have added is a 'MNoOutliers' constructor for 'MarkProperty' since it looked like the outliers are displayed by default for a boxplot mark, and 'MOutliers []' doesn't turn them off. I'll update this with an example from the new hvega tutorial I've put together (basically a copy of your walk through) once it's released. |
Sorry I missed your comment about noOutliers. Have amended so empty lists for |
I've created a working document listing changes for the next release which will support the new Vega-Lite 4 schema. I will be using this as an opportunity to implement any necessary breaking changes to the API, but would like to keep these to a minimum.
Vega-Lite 4 is still under development, so this is a work in progress and may change to reflect further changes to the Vega-Lite schema.
This should be useful for @DougBurke in keeping the Haskell port hvega up to date.
Feel free to use this issue to comment on or propose any changes prior to the next release.
The text was updated successfully, but these errors were encountered: