R/minc_vis2D.R
lut_to_palette.Rd
A tool that returns a color function/palette from color lookup files
lut_to_palette(lookup_table = system.file("luts/spectral", package = "RMINC"), alpha = 1)
lookup_table | Either a path to the lookup table file, or the table itself |
---|---|
alpha | A transparency value between 0 and 1 (inclusive) |
A function that takes in an integer specifying the number of colours required, and returns a vector of colours interpolated from the input colour lookup file
For now, the first column of the lookup table (interval where the colour occurs) is ignored; i.e. equal spacing intervals are assumed
# NOT RUN { spectral.colors <- lut_to_palette(system.file("luts/spectral", package = "RMINC")) spectral.colors(100) # }