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

learn more… | top users | synonyms (2)

2
votes
2answers
770 views

How do I find the average color of an image?

It sounds so simple to do, but the best solution I've found so far is by using the MeanFilter function, which isn't really feasible on large images. Can anyone help ...
2
votes
2answers
179 views

Gradient in a plotstyle

I'm trying to replicate the figure below. Now a nice first approach to do this is by using Mathematica, by making some kind of contourplot with circles and just add a gradient to the contourstyle. Now ...
2
votes
3answers
710 views

Color mixing or blend

Color mixing seems not only one type. Here is RGB_color_model I wrote this one: ...
2
votes
2answers
124 views

ListPlot a bunch of points that changes colour

I have a list of points: r = Range[-Pi/2, Pi/2, Pi/8]; angles = (c = Tuples[r, 2]) and a list of numbers which will determine the colour of the points above: ...
2
votes
3answers
227 views
2
votes
2answers
1k views

How can I invert the colors in a color bar

I have this Mathematica code ...
2
votes
1answer
73 views

ColorReplace does not work

I want to do - seemingly - simply image processing. I want to replace all blue pixels with white pixels. The obvious command would be: ...
2
votes
2answers
123 views

Make a colored ListPlot

Basically I have a set of 3D points, such as {3,4,3} or {4,1,4}. Instead of plotting the points in a 3D space, I want to plot the x,y coordinates of the points on the 2D plane and use the z coordinate ...
2
votes
2answers
330 views

Colors for multiple piecewise functions

I have the following $3$ piecewise functions, and I would like that f1, f2 and f3 have $3$ ...
2
votes
1answer
450 views

White regions in DensityPlot — is this a bug with ColorFunctionScaling?

Is this a bug with ColorFunctionScaling? When I try to supply my own ColorFunction Mathematica seems to partially ignore it, ...
2
votes
2answers
150 views

How can I remove edges from my DiscretePlot?

By default, DiscretePlot displays "edges" along the sides and, prominently, align the top when ExtentSize -> Full is set. For ...
2
votes
1answer
206 views

How can I mix colors?

As far as I know if you combine Blue and Green the result is Cyan (using additive mixing). ...
2
votes
3answers
849 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 ...
2
votes
1answer
66 views

Show scatter plot of change in image saturation

Let's say I have two images. One is the original and the other is after some photo-manipulation has been applied to it. I want to show the effect on the color saturation using a scatter chart. ...
2
votes
2answers
66 views

Can i change AutoStyles colors for undefined variables?

I want to change from blue to red the color of the undefined variables; but only for the current Notebook
2
votes
1answer
166 views

Two discrete colors for surface with ParametricPlot3D

I am trying to create a plot of a surface that is yellow above the xy-plane (z>0), but blue below (z<0). My first attempt was to use ...
2
votes
2answers
372 views

DensityPlot Increase Information

I am trying to make a density plot in Mathematica, however the distribution of the plot is not as visible as I would like. I plotted the same function in python and it contains a greater visible range ...
2
votes
2answers
185 views

ListDensityPlot controlling the number of colors

Is there a way to set the number of colors used in ListDensityPlot. I am using "Rainbow" as follows: ...
2
votes
1answer
212 views

Why is the test in my ColorFunction not behaving as expected?

In my code I have a ColorFunction that is meant to highlight all values of $f(x)$ that are greater than $x$ ...
2
votes
2answers
91 views

How to convert a coloured image according to the colorfunction I defined?

I got an image from a website which follows the colorfunction "Rainbow", e.g. ...
2
votes
2answers
107 views

StreamColorFunction ignored when setting to the RGB color

Recently I needed to color streamlines with exact color (e.g. RGBColor[0.1,0.478,0.5]). The help (http://reference.wolfram.com/language/ref/StreamColorFunction.html) suggests, that this can be ...
2
votes
1answer
193 views

Buttons Which Change Color, Each Time Pressed [closed]

I need to have 100 buttons, which their color is defined by the parity of number of times they are pressed: If they're pressed an even number of times their color is blue, and otherwise red. I don't ...
2
votes
1answer
157 views

How to keep front and back colors of Polygon in Graphics3D same all the time [duplicate]

I want the same face color for a 3D Polygon when viewed from front or back or from any angle. i.e. I want the color not changed under any conditions. Front and ...
2
votes
1answer
81 views

Change the colors of individual atoms in a .mol or XYZ file

Similar to (Changing the atom color for plotting xyz-files), I want to take a molecule and then simply change the colors of individual atoms. I don't want to change all atoms of a type to a color ...
2
votes
2answers
343 views

ColorFunction based on data

I have a list of numbers, and I would like to plot them using ArrayPlot (which is easy, usually :)). I would like to be able to color the elements of the plot based on the average of the list: one ...
2
votes
2answers
640 views

Spreading colors in ListContourPlot

I have a data file with triplets. The first two numbers indicate the x and y position, while the third one is the log10 value of a particular indicator. I want to create a 2D plot in which the ...
2
votes
2answers
98 views

Default color for Filling in Mathematica 9

The default color scheme for plots in my Mathematica version is ColorData[1]. What about for the Filling option?
2
votes
1answer
82 views

Having variables appear aqua in user defined function [duplicate]

In many of the inbuilt mathematica function, variables appear aqua like in: However, when creating your own function, variables no longer have that green coloring and are instead colored like an ...
2
votes
1answer
151 views

Coloring a set of polygons, each polygon to have a specific color

In addition to my previus post, regarding plotting the surface of a Möbius strip, I now realised, that some of the eigenmodes for a Möbius strip are either oscillations of a scalar field OR a vector ...
2
votes
1answer
473 views

Normalize the PlotLegends and z values for two DensityPlot

I'm trying to compare two DensityPlots: ...
2
votes
1answer
497 views

How to colorize a rectangle with a given color function?

I want to set color to a rectangle (in fact a line) that lies on (0,0) and (1,0), and the color function is given by $u(x,t)=t(x-x^2), 0\leq t\leq1$. Since, this $u(x,t)$ act as temperature at the ...
2
votes
1answer
117 views

Coloring points via “TemperatureMap” [duplicate]

I have a collection of 3D points, and each is associated with a real number in [0,1]. A typical element looks like {{x,y,z},c} where ...
2
votes
2answers
69 views

Export Text with Colors

Is there a way of using Export[] method to take a text with colors (using Style) and then export to file, such that when I open ...
2
votes
1answer
43 views

Change ColorScheme of DistributionChart

The "ColorScheme"of a DistributionChart can be changed using the ChartElementFunction like in the following example: ...
2
votes
1answer
247 views

Color coding based on 4D data within a building

I am trying to create something similar to a Heatmap within a building. Suppose I have a room with dimensions, {30,40,50} as length, width, and height respectively. I have a set of data that is of ...
2
votes
2answers
55 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 ...
2
votes
1answer
69 views

Inconsistent behavior in ColorFunctionScaling of BarLegend in v10.0.1

I find the ColorFunction in BarLegend behaves very weirdly: Force rescaling from 0 to 1 For example: ...
2
votes
1answer
172 views

Can I apply a ColorFunction to FaceGrids, or otherwise have FaceGrids with varying color?

I want to make a 3d plot with FaceGrids with a certain color scheme. Specifically, I'd like them to be one color below a diagonal line, and a different color above ...
2
votes
0answers
28 views

ArrayPlot: colours depend on image size? [on hold]

ArrayPlot is giving me incorrect colours when the image size is less than about 10.5 times the number of pixels in the input array. For example, ...
2
votes
0answers
32 views

Calculating number of discernible colors in CIE La*b* space

How can Lab space be easily splitted into unity cubes and determined number of cubes that colours of certain image occupy?
2
votes
0answers
58 views

Background color does not display in InputField unless Appearance option is also specified

I get the same behavior for v10.1.0, v.10.0.2 and v.9 with OS X (10.9.5) : No background color is displayed in InputField if I just set properly the option. For ...
2
votes
0answers
97 views

How can I transfer colors from first image into second image? [duplicate]

How can I transfer colors from first image into second image, where every object from the first image should take the same object's color from first image. This images are only an example. this is ...
2
votes
0answers
111 views

puzzled with ColorData

At first let me thank, from this point as well, those that they replied to my previous queries. From a reply I got, I obtained finally the desired graph. ...
1
vote
2answers
265 views

How to blend some colors on a curve

I need to define a color gradient on a 3D curve, but I'm having some problems with this. Suppose we have a 3D curve defined as a parametric function of some real variable ...
1
vote
2answers
208 views

Image's pixels GPU colour classes splitting

How can I split in color classes, the pixels of an image that I load in Mathematica? I would an output like this: ...
1
vote
2answers
580 views

Coloring vertices using GraphPlot

I have the following problem: I used GraphPlot to plot my adjacency matrix. I divided my nodes in three groups: ...
1
vote
2answers
94 views

Adding colors to objects in a loop

I'm just starting out in Mathematica and still learning the ropes. I'm making a "necklace" which is a circle with squares around it. The following works: ...
1
vote
2answers
144 views

Show Simplified Directives [closed]

Is there a way to force Mathematica to convert an already rendered Graphic to the simplified Directive form of that Graphic. Background: I am currently editing Graphics using Drawing Tools and then ...
1
vote
2answers
143 views

Using Specularity effects and ColorFunction in Plot3d

I'd like to reproduce the 3d surface of the attached image . What I'm interested in, is the light reflection at the basis of the surface and the rainbowlike color. I use Plot3d and colorfunction in ...
1
vote
2answers
525 views

Multiple curves plotted with different colours [duplicate]

I am trying to use ColorFunction for 2 functions on the same plot. I only want the cubic equation to change colour. ...