Questions tagged [color-palette]

1

votes
0

answer
33

Views

how to assign color shade values to a continuous variable by custom intervals?

I have a vector 'p' representing probabilities and a vector 'age' representing the age of a subject (as the test is repeated several time per year, it is fine to have more than one p for each age). My problem is that need to plot the results in a way that each value of p is associated to a color ran...
Mat Teo
1

votes
1

answer
183

Views

How to use Angular Material custom- palette colors effectively Angular Material

I am using a custom material-color palette. defined the primary and accent palettes with its default-shade,darker-shade,lighter-shade as below: $my-app-primary: mat-palette($md-lightprimary ,500,900,A700 ); $my-app-accent: mat-palette($md-lightaccent, 500,900,A100); $my-app-warn: mat-palette($...
Tarun Patel
1

votes
0

answer
19

Views

How to get colorgradient using ColorRamp in R?

In R I want to color points according to some values between 0 and 1. Why does the following minimal code generate a plot with a bunch of random colors? And why not a smooth transition from white to dark blue? code needs add-on package rcolorbrewer: niceblues
bazzymath
1

votes
1

answer
1.6k

Views

Gnuplot - defining spacing of color palette with a function

I am plotting a data file with points whose color is defined through a palette that goes from 0 to 1. The color refers to a value in a column of the file; I assign a palette with different hues of 'blue': set cbrange [0:1] set palette defined (1 '#B0E2FF', 2 '#87CEFA', 3 '#7EC0EE', 4 '#4F94CD', 5 '#...
mar tin
1

votes
1

answer
503

Views

Define palette color based on the range of z values from a data file

Suppose I have a data file with x y z column, which looks like: -3.063052922487259 -3.141592741012573 401.3000000000000 -3.063052922487259 -3.063052922487259 1.290000000000000 -3.063052922487259 -2.984513103961945 0.920000000000000 -2.984513103961945...
pig
1

votes
1

answer
593

Views

Multiple palettes and empty labels from file entries using matrix with image in gnuplot

I have a file with a 4x4 score matrix and I'd like to plot the upper triangular with one color palette and the lower triangular with a different one, overlaying the score value (MWE at the bottom). The original file looks like this 0.00 0.65 0.65 0.25 0.25 0.00 0.75 0.25 0.50 0.60 0.00 0.25 0.75 0.2...
neurino
1

votes
1

answer
869

Views

Using a uniform color palette among different ggplot2 graphs with factor variable

I am using ggplot2 to create several plots about the same data. In particular I am interested in plotting observations according to a factor variable with 6 levels ('cluster'). But the plots produced by ggplot2 use different palettes every time! For example, if I make a bar plot with this formula I...
Dario Lacan
1

votes
1

answer
887

Views

How to use the color palettes of Material-Design, and how to calculate&choose them?

I have some issues with the guidelines: On one hand, they say (here) that 500 is the chosen one for toolbars: Toolbars and larger color blocks should use the 500 color of the primary color of your app. On the other hand, they show an example by scrolling on the same page (here) , showing the color o...
android developer
1

votes
1

answer
97

Views

How to access existing code for color palettes in R

I looked for a while, but I am not quite sure how to access existing color palettes in R, e.g. all the colors used for the palette 'Blues'. I am working on maps with the package tmap at the moment. There, I want to map data on on-marital births for different years to compare them. Each data set has...
1

votes
1

answer
483

Views

Where does the QML default Button quick control get its colors from, if not QML SystemPalette?

I'm on a Windows 10 desktop system. I wonder why I can't find the colors in the QML SystemPalette, that I see being used by the QML default Button quick control. The button appears to me in #e1e1e2 normal #e4f0f9 highlighted #cce4f7 pressed But I can't find any of these in the active/inactive/disabl...
yau
1

votes
1

answer
1.5k

Views

How to change the palette colors of a highcharter column plot which depends on a variable?

I'm starting to use the highcharter package (version 0.5.0) in R and I cannot figure out how change the color of the columns, that are linked to a variable in the aesthetics of a series. The head of the data frame is presented below: > head(Top_G) # A tibble: 6 × 29 Rk Name Yrs From...
darh78
1

votes
1

answer
224

Views

Multilevel pie charts with consistent coloring

I'm trying to create a multilevel pie chart for several files that are in the following format: 117.txt compartment percent sequence dna 90 AAGTGT dna 3 AAGTGG dna 0 AAAAAA ... rna 75 AAGTGT rna 10 AAAAAA rna 10 AAGTGG ....
Matt
1

votes
1

answer
105

Views

Can animated GIFs do palette shifting?

Old-school computer graphics sometimes produced animations (cycles and fades) without actually redrawing anything to video memory, purely by updating the color palette. Is it possible to do this in an animated gif? That is, optimise (reduce file-size of) the gif by only providing a single frame of (...
benjimin
1

votes
1

answer
0

Views

Unwanted Color Palette on Plot

I am having issues with a plot that I have created where I am getting an unwanted additional color palette on the plot. My script uses to list of data to create a plot with colored points. plt.close('all') fig, axes = plt.subplots(nrows = 1, ncols = 1) fig.set_facecolor('white') axes.set_ylabel('$...
1

votes
1

answer
0

Views

R - Plotly several color palettes grouped bar

I have the following plot with plotly : library(plotly) library(dplyr) ggplot2::diamonds %>% count(cut, clarity) %>% plot_ly(x = ~cut, y = ~n, color = ~clarity,colors = 'Blues') Right now I only have one color palette 'Blues' for all groups. How can i customize it so I have one color palette per gr...
K.Hua
1

votes
1

answer
209

Views

How to use defined colors as a palette in R

I have following list of colors: ddf = structure(list(r = c(0.374, 0.374, 0.051, 0.096, 0.876, 0.415, + 0.596, 0.724, 0.847, 0.588, 0.481, 0.142, 0.819, 0.91, 0.969, + 0.887, 0.432, 0.927, 0.381, 0.04), g = c(0.183, 0.905, 0.662, + 0.706, 0.461, 0.845, 0.07, 0.101, 0.434, 0.885, 0.366, 0.075, +...
rnso
1

votes
1

answer
522

Views

plotting gnuplot with palette showing some labels

I am plotting data series with gnuplot with command: p 'file.txt' u 1:2:3 with labels and got the graph with a lot of labels as below which looks messy. So, i use different command: p 'file.txt' u 1:2:3 with points pt 5 palette which showed beautiful graph with colour spectrum. But it did not show t...
mee mee
1

votes
1

answer
298

Views

24bpp to 8bpp conversion C with raw image data

I am currently trying to convert raw binary image data (512 x 512 24bpp) to a 512 x 512 8bpp image by using 3bits for the R channel, 3 for the G channel, and 2 for the B channel. However when using my code my picture comes out grey scale? Can anyone tell me what I'm doing wrong? /*24 bit per pixel -...
s.gang
1

votes
1

answer
837

Views

Recurring Custom Color Palette for Seaborn/Python/Matplotlib

I am looking to see if there is a way to set up a color palette to make sure that any time I graph, the colors of the bars will be consistent with the values on the x axis. I am using Seaborn I'm sure this is somewhere online, but have been searching for over an hour with no luck For example, I woul...
1

votes
1

answer
695

Views

How to color each column differently in plot function?

I have a data frame as follows: A B C D E F T1 1 0 4 6 2 5 T2 1 0 4 6 2 5 T3 1 0 4 6 2 5 T4 1...
Ash
1

votes
1

answer
115

Views

Fill empty space of the 256 color palette with black pixels

I need a 256 pixels color palette because FFmpeg gives me this error: Palette input must contain exactly 256 pixels. I use ImageMagick on Mac OS to create a GIF palette from an image that contains a few shades of grey so I don't need that large color palette. The way Palettegen generates palette is...
Peter
1

votes
2

answer
43

Views

Gnuplot: loading palette?

I'm certainly missing something very obvious but how to change the basic colors Gnuplot uses (which can be seen via command test)? I want to define some colors and then to be able to use them as basic colors with linecolor 1, etc. Here's an example, which to my understanding should override colors -...
A S
1

votes
2

answer
1.2k

Views

Generation of 8 bit palette from png file via Python

What would be the best python based library for generating 8-bit palette from the given .png file. As in photoshop generating under .pal format. PS: Input PNG is already in 8 bit format. (paletted) Regards
Hellnar
0

votes
0

answer
13

Views

EmguCV read 8 bit image from byte array

I have a byte array which contains the data of PNG8 (Color palette and indexes of colors). I need to create Image (or at least simply Bitmap) from my byte array. I haven't problems with PNG24 or PNG32: byte type; int height, width; byte[] data; ... // Initializing type, height, width and data with B...
Vlad i Slav
1

votes
2

answer
279

Views

Calculating palettes from an initial color

I'm a bit confused by implementation ambiguities - for instance rotating the hue wheel by 180 degrees 'feels' right for getting a complementary color, but at the same time Adobe Kuler produces identical output for both dark and light shades of the 'seed' color. I'm not sure if this is a bug/feature...
o.v.
1

votes
1

answer
1.7k

Views

Getting pixels color index from TIFF with palette

I've got TIFF with 256 byte color palette. In Java I read this TIFF to BufferedImage. This BufferedImage has IndexColorModel. When I iterate through pixels in BufferedImage, I can only get RGB. I want to write method, which for x,y gets original color index from palette using BufferedImage (not RGB...
Arek Woźniak
1

votes
1

answer
1.2k

Views

Custom palette in the ColorPicker

I would like to change the color palette. The colors are by default have a transparency of 30%. Is it possible to replace the color palette?
espirio
2

votes
0

answer
97

Views

Add seaborn.palplot axes to existing figure for visualisation of different color palettes

Adding seaborn figures to subplots is usually done by passing 'ax' when creating the figure. For instance: sns.kdeplot(x, y, cmap=cmap, shade=True, cut=5, ax=ax) This method, however, doesn't apply to seaborn.palplot, which visualizes seaborn color palettes. My goal is to create a figure of differen...
David de L.
18

votes
1

answer
4.3k

Views

Differences between Android Palette colors

Edit To get a better feel for the Android Palette class, I decided to make a simple app to test some of its features - if you are interested, you can find the app on the Play Store: https://play.google.com/store/apps/details?id=com.tonyw.sampleapps.palettecolorextraction. Basically it just has image...
Tony Wickham
2

votes
1

answer
409

Views

memory problems with imageMagick?

I have problems using convert F:\path\source.png -define registry:temporary-path=F:\path -limit area 0 -type palette -colors 256 F:\path\target.png the temporary-path and my source and target images are on an external hard drive. I used area 0 because I don't want ImageMagick to use my systems memor...
Selphiron
1

votes
3

answer
1k

Views

How to extend dijit/ColorPalette with custom color (particular with transparent)

I use standard digit ColorPalette in my widget. It is simple tool and it works fine. But I need to expand it with transparent or none color. I can deal with it in few ways: Add just a button near the Palette to clear the color Copy all code from dijit/ColorPalette to make custom Palette in my module...
Serg
6

votes
2

answer
2.7k

Views

PNG - Is it possible to reduce the palette using Java 2D?

If I have a PNG image opened as a BufferedImage, is it possible to reduce the palette in the PNG image so that there is less colour (less bits per pixel / colour depth)? For example, if you look at Colour depth in Wikipedia, I would like to use 16 colours in my PNG image (3rd image down the right ha...
Joeblackdev
20

votes
5

answer
20.4k

Views

Simple swift color picker popover (iOS)

Is there is a simple way to implement a color picker popover in swift? Are there any built-in libraries or UI elements that I could leverage for this purpose? I saw some color pickers written in objective-c, but they were several years old and I was wondering if there was something more recent.
Ethan Strider
21

votes
6

answer
10.1k

Views

How can I generate a palette of prominent colors from an image?

I'm trying to figure out how to sample all of the pixels in an image and generate a palette of colors from it, something like this or this. I have no idea where to even begin. Can anyone point me in the right direction? __EDIT: __ This is what I've ended up with so far: I used this Pixelate function...
scottm
3

votes
2

answer
275

Views

How can I attach a list of custom color palettes to a list of ggplot objects without printing each plot object to the screen?

I have a data frame in R in which several of the columns are factors. I'd like to create a series of bar charts showing the relative sizes of each of the factor levels. I want to associate my own customized color palettes to each of the factors, and then customize the final layout of all of the ba...
stachyra
4

votes
4

answer
2.1k

Views

How to make a color progression out of a color palette

My goal with this algorithm I'm working on is to output a color progression out of some provided colors. By color progression I mean creating the 'fade' effect between two colors (color A, color B) and store every color value ((R,G,B) tuple) in between. For example, if what is provided is total bla...
Daniel Wright
11

votes
6

answer
15.3k

Views

MS Chart for .NET predefined palettes color list?

Microsoft Chart for .NET (3.5, 4.x) has predefined palettes e.g. Berry, Bright, SeaGreen etc. Is there anywhere a list of colors for each palette (hex or named)? Thanks!
Yuriy Galanter
2

votes
2

answer
138

Views

How to create and use very large palette textures for use in opengl?

Details: I have a glsl fragment shader with a uniform texture, 'u_MapTexture' with several thousand colors on it (max of about 10k-15k unique rgb values). I also have a uniform palette texture ('u_paletteTexture') that is 16384 × 1 that I want to use to index the colors on u_MapTexture to. My probl...
1

votes
4

answer
144

Views

Abstract fields implemented by static final class?

I'm trying to create custom color palettes for my Android app. I started doing it this way: public class Theme { public static final class DARK { final static int POSITIVE_GREEN = Color.rgb(0, 200, 0); final static int NEGATIVE_RED = Color.rgb(200, 0, 0); final static int BACKGROUND_GREEN = Color.a...
GameKyuubi
1

votes
2

answer
3.6k

Views

Convert 24-bit image RGB to 3-bit 8-color

I am able with an BufferedImage to obtain the RGB values for every pixel of a 640x640 image, the output looks like this: [...] Pixel :(640, 634) RGB: 166 94 82 Pixel :(640, 635) RGB: 166 94 80 Pixel :(640, 636) RGB: 163 91 77 Pixel :(640, 637) RGB: 157 88 73 Pixel :(640, 638) RGB: 157 88 73 Pixel :(...
JF Beaulieu

View additional questions