The Stack Overflow podcast is back! Listen to an interview with our new CEO.

Questions tagged [color]

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

873 questions
Filter by
Sorted by
Tagged with
218 views

How can I get a “RedLevel” instead of GrayLevel when drawing a densityplot?

I was trying different colorfunctions, but don't get the RedLevel like the picture as follow: My picture is like this, a greylevel one.
50 views

BarChart and ColorFunction

There are really two questions. The first is: how does one get BarChart to generate x coordinates. That is, ListPlot takes a list of pairs, but ...
101 views

ColorFunction doesn't work with custom PlotMarkers

Bug introduced in 10.3.0 and persisting through 12.0 or later This works: ...
32 views

Different colors for each curve in a Plot[Table[],{}]

I'd like to plot a few curves in a plot but with different colors, like in this code : ...
79 views

How to create a BarChart[] with color rules determined from categorical data?

Let's say I have a list of color names (strings), like this: samples = {{"blue, red, red"}, {"purple, blue, purple"}, {"blue, blue"}}; Then I can plot the ...
136 views

Canceling a color specification

I can get the default colors for one figure (Cuboid), and then color another figure (Sphere), as here: Graphics3D[ {Cuboid[], Red, Sphere[]} ] However, if I ...
78 views

How to plot a function for three variables in 2D plot?

I have a function and want to re-draw its plot for its three variables. Here is my function: Where X is: The plot of this function is: I'm thinking to draw a beautiful plot something like this: I ...
35 views

How to get the same color for the boundary and the shading in ListContourPlot?

If I specify the ContourShading to be the same color as the Contour they end up being a different color, see the example below. ...
33 views

Match light-shaded colors to plot themes for RegionPlot

I have a problem very similar to the one in the following topic: Match colors to plot themes. I want to extract the color of a plot for the corresponding legend. However, as I use a RegionPlot I am ...
66 views

How to rescale the colorfunction?

I have a data file which has 3 columns (let's call them x, y, p). Here x and y columns represent the co-ordinates in the 2-d plane while the third column p represent the probability of an event ...
33 views

How can we change the Highlighted elements to a specific color?

edit I don't want highlighting, only font color. Sorry. I want the Highlighted elements to be Blue Font. I can't understand this suggested previous post. When I ...
35 views

Can I get a list of RGB colors from a graphics object?

I'm wondering if it is possible to get the list of RGBColor from a plot. What I mean is simple. Suppose I plot list L with "TemperatureMap": ...
27 views

ColorFunction for LogPlot (and its cousins)

I have a ColorFunction that I use to color a Plot, with the option ...
28 views

BarLegend for custom colour function

How do I change this code so the desired BarLegend is displayed? ...
51 views

Is it possible to plot a function's value along a curve using different color?

I have a curve in 3D space which is green curve in the following picutre The code for generating the curve is as follows: ...
126 views

Transforming 2D points on to a regular grid or lattice

I have a set of points in 2D generated by doing a DimensionReduce on a list of colors: ...
52 views

Provide a list of colours for the points of ListPlot

I want to colour the points in a ListPlot with a list of colours, i.e. something like ...
15 views

Changing ticks on axes and full bar legend of density plot

I want to remove the {$5*10^4$,$5*10^5$ and $5*10^6$} ticks from the y-axis as they look like eye-sore. How do I do that? Also my bar legend isn't giving the whole range i.e. 0 to Max range of Lkall (...
35 views

Density Plot going out of range

I am plotting a function Lkall (shown in the picture below) with two inputs temp and n1d, ...
87 views

ColorFunction based on array index in ListLinePlot

ColorFunction specifies that for ListLinePlot it takes the $x,y$ data as inputs. I, however, would like to take the array index (...
48 views

Are there better ways to plot a continuous scalar function of three variables?

I am plotting a continuous scalar function of three variables with this code: ...
69 views

Change a formula [closed]

have a program consisting of a database of colors in L-a-b format. I want a formula to obtain the desired color by mixing different amounts of colors that are in the database. For example: I want ...
26 views

How to match value coloring in Plot3d to value coloring of legend

In a Plot3D I want to change the displayed value range, see the following example. The function generates the values {-1,1}, they are displayed correctly on the z-axis within {-2, 2}, but the color ...
41 views

Filling a region in a plot changes color in legend [closed]

I'd like to mark a region in my plot and after some research in the internet I found the solution I was looking for using the Filling option. ...
36 views

PlotLegend Colors Missing

I want a PlotLegend with the colors of the graphics. p4 = Plot[y1[t] /. s1, {t, 0, tmax}, PlotRange -> All, PlotStyle -> {{Gray}}, PlotLegends -> "Y1"]; ...
66 views

How can I plot a matrix with a two-dimensional color scheme?

Plotting a matrix with colors depending on the value of each entry is straightforward, ...
58 views

Scaling contour plot colors over several orders of magnitude

I have this contour plot that has values ranging from ~0.01 to ~100, however, there aren't distinct colors between every order of magnitude. I've tried putting a Log scale on the ...
25 views

Plot: line colors when using assumptions

I want to vary a parameter via assumptions in a simple line plot and assign a different line color to each parameter value. Unfortunately all lines are the same color. I also tried to use Evaluate[], ...
21 views

Color of line in ParametricPlot according to indepedent variable

I solve a set of pdes numerically using NDSolve: ...
135 views

Plotting maxima within a simplex

I am trying to draw a particular maximum plot within a simplex. I have functions based on two variables: Write p,q for the two variables where p,q \geq 0 and p + q \leq 1. This defines the simplex ...
181 views

Construct, in some manner, a four-dimensional “RegionPlot”

Let me abuse some Mathematica notation and formulate the following "command": ...
88 views

Customize ColorData function

I am trying to customize the color data ColorData["AvocadoColors"] I want to make color data function of the gradient starting from the green to the white ...
91 views

Set PlotStyle to be the, say 3rd, default colour Mathematica v11

This question (at least for v10) seems to have been asked many times, but I cannot decipher the answers. I have read a few posts about this - but I don't know how to use any of the answers (e.g. How ...
30 views

how to create colour from sample color with cielab model?

how to create colour from sample color with cielab model? I have measure of l,a,b of sample.. I have all hues. I can't create create the same colour from sample color. please help me!
117 views

...
46 views

How do we color a plot based on a given function?

I'll explain the problem I have with a shorter example, since I'm working with a huge messy function. Suppose we have a real-function $f(t)$, and a curve $C(t) \in \mathbb R^3$. Now, I can use ...
49 views

Discolored ComplexPlot ColorFunction [closed]

I have this code. ...
41 views

How to label the nodes of a graph with the numbers in a list?

I have an adjacency matrix "am" and I want to color the nodes with four colors. Here I what do... ...
61 views

Color scheme problem

I have a problem in the color scheme in a 2D spectra. After a lot of calculations, i can generate a picture like this in the last part using this instructions ...
126 views

Plotting a rectangle with a heat map

Consider the two table set below t1= {0.44, 0.62, 0.77, 0.87, 0.93, 0.96, 0.98, 1} t2= {0.25, 0.25, 0.25, 0.25, 0.25, 0.25, 0.25, 0.25} how can I create a plot ...
28 views

Almost unreadable input assistant text using the official stylesheet “ReverseColor”

When I use Mathematica's ReverseColor the input assistant is shown in almost the same color as the block's background. (Grey tones). See picture below: Can this really be true? Or is it a bug on my ...
494 views

Coloring lines in a graph the same color if they are the same length

If one has a graph with any number of points, as in the example below, how can one color all the lines that are of the same length in the same color? (The points are ...
71 views

Weird lighting for spherical plot

Consider the following code : ...
233 views

Reverse ColorFunction or ColorData

please excuse my bad English, I'm not a native speaker. This should be fairly simple: Is there a simple way to "reverse" ColorFunction or ColorData? Let me explain what I mean. Let's say, we have ...
30 views

Variable color function

Im trying to make a color function for listdensity that changes depending on the range of values in the array. ...
51 views

Highlight certain values based on position

How to highlight or color certain values in a list based on position.. For example x = {1,2,3,4,5,5,5,6}... I want to plot x and highlight values (Red) in a position such as {0,4,5} and others should ...
65 views

...
36 views

Using Maximize with LABColor

I'm writing a function that, given a color, returns a contrasting color. It does this by maximizing the ColorDistance between the input and output colors. However,...