Questions on the color models, schemes, named colors and color functions supported by Mathematica.
26
votes
4answers
1k 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 ...
7
votes
4answers
962 views
Coloring Points in a List Plot [duplicate]
Possible Duplicate:
ListPlot with each point a different color and a legend bar
I want to color the points in a list plot using a function of the (x,y) values.
I tried this (example with ...
21
votes
4answers
1k views
Density plot on the surface of sphere
I would like to make density plots of a list of (size 2 or 3) spherical harmonics on the surface of a sphere. I'd like to plot it so that each element of that list is using a different color (red ...
23
votes
1answer
228 views
Is there a way to access the (lexically) current colour inside Graphics?
Note that this is not a duplicate of the question over there. That one asks for a given point, while I'm asking about the lexical structure (which, of course, is not directly related to any point in ...
14
votes
2answers
1k views
How to save plots in grayscale
As sophomoric as this question seems, how should I save plots in grayscale in Mathematica?
I generally like eps images for their scalability and I use ghostscript or other third party perl scripts ...
10
votes
4answers
382 views
Coloring Points in a Plot, based on their position in the list
Before I describe the question, I'd like to say that I've seen the excellent answers posted here but have not managed to get them to work for my own data.
I have a list of values that I would like to ...
4
votes
1answer
534 views
Fixed color scale in multiple density plots
I think there should be a simple solution for my current problem, but neither StackOverflow (or the help of Mathematica) or Google have it.
I have to plot multiple density plots with a color ...
23
votes
1answer
422 views
The correct way to linearize colorspace before resizing, blurring etc
There was an interesting discussion on MathGroups dealing with the fact that image-processing functions in Mathematica (and many other software, including Adobe Photoshop) work with RGB, Grayscale ...
15
votes
2answers
319 views
Exporting a dashed plot with a color gradient to a vector graphics format ruins the dashing
When exporting a dashed plot with a color gradient to a vector graphics format such as EPS or PDF, the dashing is partly ruined. For example, this command:
...
9
votes
2answers
207 views
How can I prevent ColorFunction from disabling antialiasing in graphics?
When I use ColorFunction, the appearance of my plots is ruined, changing from this
which has the normal smooth lines and antialiased fonts, to this
in which ...
15
votes
4answers
541 views
How can I create a ColorFunction using Blend?
As shown below, I am trying to find a cool way to show some variance weighted deviation from the mean. There are 10 attributes that I compute the distance for.
How can I add a color function such ...
11
votes
6answers
372 views
Overlapping Red and Green ArrayPlots to show yellow intersections
Let's say I have two ArrayPlot[]s. One is in redscale and the other is in greenscale, such that the lowest value is white and the highest value is pure red or ...
12
votes
2answers
521 views
Using a ListDensityPlot to map color onto a ListPlot3D graph
I have a 3 column list of data points. The first two columns correspond to x and y coordinates, with data points creating a surface in the z direction from column 3. This gives me a nice wavy ...
6
votes
0answers
111 views
Break[] inside ColorFunction
f[x_?NumericQ]:= (Do[Break[],{i,1,2}];x)
Plot[x,{x,0,1},ColorFunction->(ColorData["Rainbow"][f[#]]&)]
Break::nofwd: No enclosing For, While, or Do found ...
12
votes
2answers
181 views
Pattern that matches colors
Suppose I'm writing a function that takes a color as a parameter; for example:
drawShape[color_] := Graphics[{Style[Disk[], color]}];
But if the caller inputs an ...
8
votes
2answers
397 views
ColorFunction in Histogram[]
Let's say I have a Histogram:
Histogram[RandomVariate[NormalDistribution[10, 2], 500]]
and I want the bars positioned to ...
7
votes
2answers
358 views
Coloring each face of a Cuboid with a different color
Is there a way to color each face of a Cuboid with a different color?
I looked in the help but couldn't find anything. I found this Coloring the faces of a 3D ...
6
votes
1answer
253 views
Way to find color at a point in a Graphics?
I need to figure out a way to find out the RGB color value at a certain coordinate in a Graphics object. The Graphics object I am dealing with is continually Dynamically updated, so it is made of ...
3
votes
2answers
241 views
Define a color function based on color samples obtained from ColorBrewer
I am quite new to mathematica and I am searching for a way to create a smooth colormap based on the samples given by http://colorbrewer2.org/ .
Is it possible to create a interpolated function from ...
13
votes
6answers
328 views
X-Y scatter plot with coloring dependent on Z value
I have an array of $(x,y,z)$ triples (array dimensions: N x 3), from which I can make a 2D scatterplot of $(x,y)$ values:
...
11
votes
2answers
212 views
can a ColorFunction have side effects?
Can anyone explain this (to me) odd behavior. If I run this code once (fresh kernel) it works as intended.
...
11
votes
2answers
214 views
Using uniform coloring in MatrixPlot
I have a rectangular matrix, which is m-by-10. Each element is either 0 or 1. I would like 0 to correspond to white elements, and 1 to red elements. This works ...
7
votes
2answers
508 views
problem with coloring spherical harmonics
I want to color a spherical harmonics. So I write as follows.
...
6
votes
2answers
228 views
Problem achiving effect I want with ColorFunction
I want to create a plot showing historical annual maximum and minimum temperatures. I've figured out how to get 10 years of historical temperature data from Wolfram|Alpha. The plot below shows the ...
5
votes
3answers
258 views
ColorFunction and/or ColorScaling issue with ParametricPlot3D
My goal is to use ColorFunction to color a cylinder based on the $z$ value of a separate Plot3D. I'm not sure if I am making a ...
5
votes
2answers
235 views
Monochrome PNG (and GIF) Export
Is there a way to Export expressions to a monochrome PNG?
I have tried the ColorQuantize function which is mentioned in ...
4
votes
1answer
152 views
How can I colorize an imported model?
How can I colorize an imported model from for example 3ds max?
I'm trying to find the way to colorize a 3D plot from an imported model with something like this:
...
3
votes
2answers
364 views
Use ColorFunction in ListLinePlot with If
The following code
ListLinePlot[{2, 4, 6, 8, 10, 12},
ColorFunction -> Function[{x, y}, If[x <= 3, Blue, Red]]]
should produce blue lines for $x\le3$ and ...
2
votes
3answers
130 views
Controlling Bar Color in BarChart precisely [duplicate]
I'm trying to control the color of individual bars in a BarChartwhen I pass a 2 dimensional list of data to plot. What I want to accomplish is that for each pair of ...


