Questions on the color models, schemes, named colors and color functions supported by Mathematica.

learn more… | top users | synonyms (2)

1
vote
3answers
181 views

How to apply a color gradient to a Rectangle primitive? [duplicate]

How can we apply a color gradient (say "Rainbow") to a Rectangle primitive ? Of course, I searched the documentation : http://reference.wolfram.com/language/ref/Rectangle.html, and also the site : ...
2
votes
0answers
59 views

Discrete color bar: height not adjusting

I am trying to adjust height of my color bar, but LegendMarkerSize is not doing what it is supposed to do. Code ...
0
votes
1answer
60 views

Simple ListPlot with different colors and labels [duplicate]

I want to plot a list of points where every point has a different colour. Is it also possible to label these points according to a list of sample names I have in Excel? Please help.
0
votes
1answer
120 views

rescaling ColorFunction for ListContourPlot

I have this question that I've been struggling with. I came across many similar questions, but those solutions do not work for me. What I looked at: Example 1 Example 2 Example 3 I apologize if I ...
10
votes
6answers
1k views

can the color in MeshStyle be specified by a ColorFunction, such as “SunsetColors” for example. If so, what is the correct syntax?

This is an example given in Help: Plot3D[Sin[x y], {x, 0, 3}, {y, 0, 3}, MeshStyle -> Gray] Could this be changed to something like ...
13
votes
2answers
187 views

How to prevent Dynamic activity with colour swatches in V10+

Since version 10, if I type e.g. an RGBColor or simply a named color, a dynamic colour swatch is returned. Same goes for when you e.g. extract colours from a ...
0
votes
2answers
65 views

Color according to condition. [closed]

So, my problem is the following: I have the following table ...
1
vote
0answers
55 views

How to synchronise bar legends zeros for a set of DensityPlots? [duplicate]

I make a set of 6 DensityPlots with PlotLegends and different sets of params: ...
0
votes
0answers
25 views

Crash when picking colours in Drawing Tools

This crash happens consistently, in Mathematica 10.2.0.0; I'm working on Scientific Linux 6. I open the Drawing Tools toolbox, open e.g. the Stroke drop down menu, and want to select the drawing ...
26
votes
3answers
2k views

How to change ColorFunction after plotting

Say I have a plot like plot = DensityPlot[ Exp[-((x-5)^2+(y-5)^2)/5^2], {x, 0, 10}, {y, 0, 10}, PlotRange -> {0,1} ] Is there a way to ...
3
votes
2answers
157 views

ParametricPlot3D colorfunction for a specific region of an object

I have created a 3D parametric plot of an oblate spheroid, and I want to apply "TemperatureMap" as a colorfunction to its surface as a gradient in the Z direction. However, I only want to apply this ...
27
votes
7answers
7k views

Changing the background color of the framed region of a plot

I frequently generate framed plots like this: Plot[Sin[x], {x, 0, 2 \[Pi]}, Frame -> True] Is there an easy way to change the background color of the framed ...
42
votes
4answers
6k views

How to change the default ColorData used in Mathematica's Plot?

This question leads on from the recent question What are the standard colors for plots in Mathematica? There it was determined that the default color palette used by ...
3
votes
2answers
3k views

Define a color function using Piecewise

How can I define a ColorFunction for my ContourPlot using Piecewise? For example, after ...
5
votes
0answers
53 views

How many clusters does DominantColors return?

Is there any documentation on how it automatically chooses the number of colors - does it use X-means or some other heuristic to determine the number of clusters it automatically returns?
0
votes
1answer
59 views

How to add color to listplot

I have generated many points in a 2-dimensional space (x,y). How do I use color to represent different values of f(x,y) in ListPlot? Does ...
3
votes
4answers
158 views

Changing The Colour Of A Contour Plot

I have produced used the following code to create a contour plot: ContourPlot[Cos[x] + Cos[y], {x, 0, 4 Pi}, {y, 0, 4 Pi}] However, I would like to modify this ...
3
votes
2answers
78 views

Coloring specific elements of sets with a prime modified order in an array plot

I have a set of sets: {{1}, {0}, {1, 1}, {0}, {1, 0, 1}, {0}, {1, 1, 1, 1}, {0}, {1, 0, 0, 0, 1}} I’m seeking to apply a color rule to only every other set, starting from the first (from left to ...
0
votes
0answers
49 views

Coloring all elements in prime ordered sets amongst a set of sets [duplicate]

So I have a set of sets. I want only those sets whose order amongst the sets plus one is prime to be colored (all the same, anything but the standard black). Any ideas? ArrayPlot[{{1}, {1, 1}, {1, 1, ...
4
votes
1answer
88 views

What is the default ColorFunction for MatrixPlot?

I think the the default ColorFunction for ArrayPlot is ...
1
vote
1answer
86 views

Color vectors according to a user-defined function

V[x_,z_]:=x/Sqrt[x^2+z^2]; Ex[x_,z_]=-D[V[x,z],x]; Ez[x_,z_]=-D[V[x,z],z]; The electric field components (Ex,Ez) are to be plotted as a vector field in the x-z ...
0
votes
1answer
118 views

ContourPlot color problems [closed]

I tried to use contourplot to a 2D fucntion with rescaled color, the code is given below ...
2
votes
2answers
213 views

Individual ColorFunction with RGBColor [duplicate]

I want to create a custom ColorFunction using RGBColor for my DensityPlot. A nice example is ...
5
votes
3answers
135 views
2
votes
1answer
60 views

Replicate $\LaTeX$ PGF colormap/hot to Mathematica color scheme

I want to replicate the color scheme colormap/hot from $\LaTeX$ PGF's package pgfplots. The color scheme ...
2
votes
1answer
129 views

Color a single contour from a ListContourPlot3D using values from a list

I want to map an electrostatic potential onto a density map. How can I color a single contour from a ListContourPlot3D using the values from another list? Make ...
7
votes
1answer
108 views

How to replicate v9's color conversion to LAB under v10

Mathematica 10(.0.0) appears to use a different flavor of the LAB color space, but I would like to emulate the same behavior observed in version 9(.0.0). v9 ...
1
vote
0answers
65 views

How to properly set ColorFunction and Specularity in ReliefPlot [closed]

I have two questions about ReliefPlot: How can I set the Specularity without changing ...
0
votes
1answer
79 views

How to colorize curves intersection in a manipulate function

I need to show the intersection area of two curves, using the manipulate function in Mathematica. Here's a fully working example, and a preview below it : ...
3
votes
2answers
74 views

Automatically highlighting or coloring specific terms

I am using Mathematica to perform Newton quasi-linearization of the non-linear terms during discretization of PDEs for numerical solution. These expressions can involve tens of terms (depending on the ...
2
votes
2answers
82 views

Special Coloring of two 3D Graphics with same values

As you can see in the picture below, I have plotted three different functions. Since two functions (red and blue) have the same value for a certain region (equity > 60), I was wondering how I can make ...
1
vote
1answer
94 views

Color of lines in ParametricPlot3D

I have a function of two variables which returns a vector of three components. For example func[l_,t_]:={ x=.... y=.... z=.... {x,y,z}} Now I ...
3
votes
2answers
139 views

ListDensityPlot with discrete values and colors

I have a file with mesh points and a value that indicates the domain the point belongs to https://www.dropbox.com/sh/ll9hb3oxxreufsg/AABvU7nufHhyHY3W4ausanJ6a?dl=0 I would like to plot using ...
10
votes
2answers
399 views

How do you convert RGBColor to an HTML-style string?

If I run some color processing function, like: Blend[RGBColor /@ {"#DC4E00", "#000000", "#822250", "#FCC11B"}] I get back a ...
6
votes
1answer
116 views

Plotting piecewise functions with distinct colors - issue found [duplicate]

I've been making use of the following thread: Plotting piecewise function with distinct colors in each section A handy feature I found there goes as follows: ...
31
votes
2answers
10k views

What are the standard colors for plots in Mathematica 10? [duplicate]

Mathematica 10 release appears to have changed the default styling of plots: the most visible changes are thicker lines and different default colors. Thus, answers to this stackoverflow question are ...
3
votes
1answer
93 views

SmoothHistogram3D with a ColorFunction representing z-values of the data set

I'd like to make a 3d plot of a list of {x, y, z} points, where the height of the plot scales with the density (as in histogram) of the xy-values and the color ...
3
votes
1answer
100 views

mask specific range of RGB color frome an image with lower and upper threshold

I'm trying to detect a specific range of RGB color from an image with the lower threshold [180.150.0] and upper threshold [255,255,150]. I am just new on Mathematica please help me with clear ...
5
votes
2answers
2k views

How to color lines in Epilog

I often use Epilog to label lines within graphs, and I like to coordinate the color of the labels with the color of the lines they're labeling. This is no problem. However, I'm currently working on a ...
20
votes
1answer
1k views

Is it possible to insert new colour schemes into ColorData?

Because of the standards in my field, for many plots I need to use (or at least end up using) rather narrowly defined colour schemes, and in particular the Matlab "Jet" scheme, which is well described ...
3
votes
1answer
81 views

Colour of lines in ContourPlot3D

How do I change the colour of these lines from black to, let's say, red? ...
6
votes
2answers
289 views
29
votes
2answers
982 views

How can I use Kenneth Moreland's “Diverging Color Maps for Scientific Visualization” in plots?

I often want to plot two dimensional data that is centered around zero (for me, this is usually a 2D optical spectroscopy signal, but there are other cases), and the MATLAB "Jet" color scheme is ...
2
votes
1answer
200 views

Polar color coding for complex function plots?

Having browsed this Q on plotting complex functions and the Zeta page, I don't see anything as nice as this plot from Matilde Marcolli's slides "Geometry and physics of numbers". Looks like ...
2
votes
1answer
112 views

ListDensityPlot — bar legend colors inconsistent with plot value coloring [duplicate]

I want to make a ListDensityPlot of an array of values that happen to be 1. To mimic this, use: ...
14
votes
6answers
897 views

Default Chart Color Doesn't Match

I have looked through other posts to find out what the default plot color is, but when I use it, the color doesn't seem to match. Can anyone explain why I'm seeing different output? The reason I ask ...
4
votes
2answers
164 views

How to customize color scheme to mimic that in Origin?

Origin is a software for plotting. The standard color scheme used by Origin is So how to mimic this color scheme in mathematica, so we can use it in ...
7
votes
1answer
140 views

Why does ColorConvert give a different answer than other websites when converting from RGB to XYZ?

I was recently making a function that needed to convert between several different colorspaces, and I decided to do it manually. @J.M. used many builtin functions to accomplish the same goal. When I ...