cljsjs

punit-naik 2021-03-12T15:04:14.001800Z

Hi Guys I am using [cljsjs/vega-lite "4.17.0-0"] and [cljsjs/vega "3.3.1-0"] in my project. I have the spec below: { "encoding":{ "x":{ "field":"x", "type":"ordinal", "title":"Score", "axis":{ "labelAngle":0, "labelOverlap":false, "grid":false, "titleFontSize":14, "labelFontSize":12, "tickCount":7, "tickOffset":{ "expr":"width/-14" } } }, "y":{ "field":"y", "type":"quantitative", "title":"No. of Companies", "axis":{ "labelAngle":0, "labelOverlap":false, "grid":false, "titleFontSize":14, "labelFontSize":12, "tickCount":7 } }, "color":{ "field":"label", "type":"nominal", "title":"Score belonging to", "legend":{ "orient":"top" }, "scale":{ "domain":[ "Rest of the companies", "Tesla Inc" ], "range":[ "#4c78a8", "#ff6501" ] } }, "opacity":{ "condition":{ "selection":"company", "value":1 }, "value":0.05 }, "tooltip":[ { "field":"x", "title":"Score", "type":"ordinal" }, { "field":"y", "title":"No. of Companies", "type":"quantitative" }, { "field":"label", "title":"Score belonging to", "type":"nominal" } ] }, "transform":[ { "filter":{ "field":"x", "valid":true } }, { "filter":{ "field":"y", "valid":true } } ], "config":{ "view":{ "stroke":"transparent" }, "mark":{ "cursor":"pointer" }, "axis":{ "gridColor":"white", "labelColor":"white", "tickColor":"white", "titleColor":"white" }, "legend":{ "labelColor":"white", "titleColor":"white" } }, "mark":{ "type":"bar", "invalid":"filter" }, "width":"container", "background":"transparent", "id":"573da040-5f77-4ea5-a2c9-24cff7a2eb76", "selection":{ "company":{ "type":"multi", "fields":[ "label" ], "bind":"legend" } }, "height":"container", "data":{ "values":[ { "x":0, "y":38, "label":"Rest of the companies" }, { "x":1, "y":22, "label":"Rest of the companies" }, { "x":2, "y":11, "label":"Rest of the companies" }, { "x":3, "y":6, "label":"Rest of the companies" }, { "x":4, "y":9, "label":"Rest of the companies" }, { "x":5, "y":14, "label":"Tesla Inc" }, { "x":6, "y":30, "label":"Rest of the companies" } ] } } Although this works perfectly fine inside vega editor (https://vega.github.io/edit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qmqGqsotmwZnqcgbtgsKnWgCRJBCXBCDd6pTlqj3dRAc6veg31RsEwSXfif2qgDmoPU9oP6uDaBJR9vqw79yoI3dQMo2D5DHWg4JRuVOPXfjgPIyDxOk-6H1hFTQhGjIJrmlAnQk2Q6DY0MZ2PJN8O3bT2r02jj4dEAA), but the tickOfset expr is not working via the library. Any ideas? I am guessing I need to upgrade/downgrade the lib versions.

jsa-aerial 2021-03-17T21:12:20.001600Z

*strange place to ask this, but that is an old version of vega. Should be using [*cljsjs/vega "5.17.0-0"]

👍 1