Notice!
This is documentation for kScript v1.0, which may not include the latest features. For up-to-date documentation, see the latest version.

Available Color Constants

kScript provides 17 predefined color constants. These can be used directly in plotting functions and style definitions.

#FFFF00
yellowcolor

Yellow color (#FFFF00)

#FFA500
orangecolor

Orange color (#FFA500)

#800080
purplecolor

Purple color (#800080)

#808080
graycolor

Gray color (#808080)

#000000
blackcolor

Black color (#000000)

#FFFFFF
whitecolor

White color (#FFFFFF)

#FF0000
redcolor

Red color (#FF0000)

#008000
greencolor

Green color (#008000)

#0000FF
bluecolor

Blue color (#0000FF)

#C0C0C0
silvercolor

Silver color (#C0C0C0)

#800000
marooncolor

Maroon color (#800000)

#FF00FF
fuchsiacolor

Fuchsia color (#FF00FF)

#00FF00
limecolor

Lime color (#00FF00)

#808000
olivecolor

Olive color (#808000)

#000080
navycolor

Navy color (#000080)

#008080
tealcolor

Teal color (#008080)

#00FFFF
aquacolor

Aqua color (#00FFFF)

Using Colors in Your Scripts

Examples of how to use color constants in different plotting scenarios.

Single Color Plot

Use a single color constant for simple line plots.

Multi-Color Indicators

Combine multiple colors for complex multi-line indicators.

Conditional Coloring

Change colors based on market conditions or signal strength.

Recommended Color Palettes

Pre-designed color combinations that work well together for different types of indicators.

Trading Signals

Classic colors for buy/sell signals and trend indicators

green
red
blue
let colors = ["green", "red", "blue"];

Technical Analysis

Professional colors for technical indicators and overlays

orange
purple
teal
let colors = ["orange", "purple", "teal"];

Volume Analysis

Distinct colors for volume-based indicators

lime
yellow
fuchsia
let colors = ["lime", "yellow", "fuchsia"];

Color Best Practices

🎨

Consistent Branding

Use the same color scheme across related indicators for visual consistency.

Accessibility

Choose colors with sufficient contrast for better readability.

📊

Semantic Colors

Use meaningful colors: green for bullish, red for bearish.

📖
Introduction
Overview of kScript language
🚀
Quick Start
Get started with kScript basics
📋
Function Reference
Complete API reference guide
🔧
Core Concepts
Variables, data types & data sources
🔗
Script Definition
Defining inputs and metadata
TimeSeries Management
Working with time-aligned data
🎯
Utility Functions
Helper functions and calculations
📈
Moving Averages
SMA, EMA and trend-following indicators
📊
Oscillators
RSI, Stochastic and momentum indicators
📈
Trend Indicators
Trend direction and strength analysis
📉
Volume Indicators
Volume-based analysis tools
📦
Orderbook Functions
Market depth analysis tools
🎨
Plotting & Visualization
Chart rendering and styling
🌈
Color Functions
Color manipulation and styling
🏠
Go Home
Return to main landing page