# Parallel plot colors

**URL:** <https://community.plotly.com/t/parallel-plot-colors/11011>\
**Category:** plotly.js\
**Created:** [June 18, 2018, 8:15pm UTC](https://community.plotly.com/t/parallel-plot-colors/11011 "2018-06-18T20:15:47Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![chrisfong](https://avatars.discourse-cdn.com/v4/letter/c/958977/32.png) [@chrisfong](https://community.plotly.com/u/chrisfong)\
**Post date:** [June 18, 2018, 8:15pm UTC](https://community.plotly.com/t/parallel-plot-colors/11011/1 "2018-06-18T20:15:48Z")

</div>

I’m still having an issue understanding how the color scale works for the parallel coordinates plot. In my case, the color values are either 0 or 1 which i want to display as red or green. This works fine in some situations, but if I have all 0’s or all 1’s then the color seems to be displayed as a brown

Here’s a fiddle that shows this behavior:  
[https://jsfiddle.net/vjywawu5/2/](https://jsfiddle.net/vjywawu5/2/)

Are there any other ways to color the lines on my plot (to have just discrete colors). Or if I have to use color scale, how can i get around this issue?

---

<div class="post-metadata">

**Author:** ![etienne](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/etienne/32/17_2.png) [@etienne](https://community.plotly.com/u/etienne)\
**Post date:** [June 19, 2018, 1:25pm UTC](https://community.plotly.com/t/parallel-plot-colors/11011/2 "2018-06-19T13:25:36Z")

</div>

You need to specify the color domain with `cmin` and `cmax` as in [https://jsfiddle.net/vjywawu5/3/](https://jsfiddle.net/vjywawu5/3/)

By default, even though all your `color` values are `0`, we add a bit of padding when computing cmin/cmax. In your case, `cmin: -0.5` and `cmax: 0.5`, see [https://jsfiddle.net/r0cLsxat/2/](https://jsfiddle.net/r0cLsxat/2/)
