PINE LIBRARY

Graph

Zaktualizowano
Library "Graph"
Library to collect data and draw scatterplot and heatmap as graph

method init(this)
  Initialise Quadrant Data
  Namespace types: Quadrant
  Parameters:
    this (Quadrant): Quadrant object that needs to be initialised
  Returns: current Quadrant object

method init(this)
  Initialise Graph Data
  Namespace types: Graph
  Parameters:
    this (Graph): Graph object that needs to be initialised with 4 Quadrants
  Returns: current Graph object

method add(this, data)
  Add coordinates to graph
  Namespace types: Graph
  Parameters:
    this (Graph): Graph object
    data (Coordinate): Coordinates containing x, y data
  Returns: current Graph object

method calculate(this)
  Calculation required for plotting the graph
  Namespace types: Graph
  Parameters:
    this (Graph): Graph object
  Returns: current Graph object

method paint(this)
  Draw graph
  Namespace types: Graph
  Parameters:
    this (Graph): Graph object
  Returns: current Graph object

Coordinate
  Coordinates of sample data
  Fields:
    xValue (series float): x value of the sample data
    yValue (series float): y value of the sample data

Quadrant
  Data belonging to particular quadrant
  Fields:
    coordinates (array<Coordinate>): Coordinates present in given quadrant

GraphProperties
  Properties of Graph that needs to be drawn
  Fields:
    rows (series int): Number of rows (y values) in each quadrant
    columns (series int): number of columns (x values) in each quadrant
    graphtype (series GraphType): Type of graph - scatterplot or heatmap
    plotColor (series color): color of plots or heatmap
    plotSize (series string): size of cells in the table
    plotchar (series string): Character to be printed for display of scatterplot
    outliers (series int): Excude the outlier percent of data from calculating the min and max
    position (series string): Table position
    bgColor (series color): graph background color

PlotRange
  Range of a plot in terms of x and y values and the number of data points that fall within the Range
  Fields:
    minX (series float): min range of X value
    maxX (series float): max range of X value
    minY (series float): min range of Y value
    maxY (series float): max range of Y value
    count (series int): number of samples in the range

Graph
  Graph data and properties
  Fields:
    properties (GraphProperties): Graph Properties object associated
    quadrants (array<Quadrant>): Array containing 4 quadrant data
    plotRanges (matrix<PlotRange>): range and count for each cell
    xArray (array<float>): array of x values
    yArray (array<float>): arrray of y values
Informacje o Wersji
v2

Added:
method paintQuadrantSummary(this)
  Draw quadrant summary
  Namespace types: Graph
  Parameters:
    this (Graph): Graph object
  Returns: current Graph object

Updated:
GraphProperties
  Properties of Graph that needs to be drawn
  Fields:
    rows (series int): Number of rows (y values) in each quadrant
    columns (series int): number of columns (x values) in each quadrant
    graphtype (series GraphType): Type of graph - scatterplot or heatmap
    plotColor (series color): color of plots or heatmap
    plotSize (series string): size of cells in the table
    plotchar (series string): Character to be printed for display of scatterplot
    outliers (series int): Excude the outlier percent of data from calculating the min and max
    position (series string): Table position
    bgColor (series color): graph background color
    summaryBgColor (series color): background color of quadrant summary label
    summaryTextColor (series color): text color of quadrant summary label
    summaryTextSize (series string): Size of the quadrant summary text
arrayshewhomustnotbenamedMATHstatisticstrendoscope

Biblioteka Pine

W prawdziwym duchu TradingView autor opublikował ten kod Pine jako bibliotekę typu open source, aby inni programiści Pine z naszej społeczności mogli go ponownie wykorzystać. Pozdrowienia dla autora! Możesz używać tej biblioteki prywatnie lub w innych publikacjach typu open source, ale ponowne użycie tego kodu w publikacji podlega Zasadom Regulaminu.

Wyłączenie odpowiedzialności