plotly.js: IE9 JS Plotly.redraw and Plotly.addTraces both throws Invalid Argument

I used the recommended way to load plotly for IE9 with the typedarray

<script>if(typeof window.Int16Array !== 'function')document.write("<scri"+"pt src='extras/typedarray.min.js'></scr"+"ipt>");</script>

<script type="text/javascript" src="plotly.min.js"></script>

I am trying to do a simple “bar” chart with three traces. However, both addTraces (adding one trace at a time) and redraw (array of traces) would throw “Invalid Argument” error in IE9 and no bars on graph

IE10+ works Chrome works

Is there a workaround for this in IE9? It is a little urgent

thanks for any help

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 17 (9 by maintainers)

Most upvoted comments

I stumbled upon the same error. Of course I’m not sure the cause is the same, but in my case the value of the value parameter passed to d3_style_setProperty.call was NaNpx (and name was #stroke-width). I could fix this by explictly adding marker.line.width option to my traces. e.g.

marker: {
    color : 'green',
    line: {width: 0} // should be there, to make it work in IE9 :-)
}, 

Hope this can be of any help…