abstract class Cryplot::BasePlot
- Cryplot::BasePlot
- Reference
- Object
Overview
Class used to create a plot containing graphical elements
Direct Known Subclasses
Defined in:
plot/baseplot.crConstructors
Instance Method Summary
- #autoclean(val : Bool)
-
#autoclean : Bool
Toggle automatic cleaning of temporary files (enabled by default)
-
#autoclean=(autoclean : Bool)
Toggle automatic cleaning of temporary files (enabled by default)
-
#border : Border
border style of the plot
-
#cleanup
Delete all files used to store plot data or scripts.
-
#clear
clear all draw and gnuplot commands Note: This method leaves all other plot properties untouched.
- #data_filename : String
-
#draw(what : String, using : String, expr : String)
Draw plot object with given
what
,using
andwith
expressions (e.g.,plot.draw("sin(x)*cos(x)", "", "linespoints")
, (e.g.,plot.draw("file.dat", "1:2", "points")
)). -
#draw(using : String, expr : String)
Draw plot object with given
using
andwith
expressions (e.g.,plot.draw("1:2", "points")
)). -
#font_name(name : String)
Set the font name for the plot (e.g., Helvetica, Georgia, Times).
-
#font_size(size : Int)
Set the font size for the plot (e.g., 10, 12, 16).
-
#gnuplot(cmd : String)
Use this method to provide gnuplot commands to be executed before the plotting calls.
-
#grid : Grid
The vector of grid specs for the major and minor grid lines in the plot (for xtics, ytics, mxtics, etc.).
-
#legend : Legend
legend specs of the plot
-
#palette(name : Cryplot::Palette)
Set the palette of the colors for the plot.
-
#palette : Cryplot::Palette
gnu palette to be used
-
#palette=(palette : Cryplot::Palette)
gnu palette to be used
- #repr : String
- #samples(value : Int)
-
#save(filename : String)
Save the plot in a file, with its extension defining the file format.
-
#save_plot_data
write the current plot data to data file
-
#show
Show the plot in a popup-window Note: This removes temporary files after saving if
#autoclean
is enabled. -
#size(width : Int, height : Int)
Set the size of the plot (in unit of points, with 1 inch = 72 points).
-
#style_fill : FillStyle
The specs for the fill style of the plot elements in the plot that can be painted.
- #this
-
#title(text : String)
Set the title text of the plot
-
#title : Title
title of the plot
-
#to_s(io : IO) : Nil
convert this plot object into a gnuplot formatted string.
Constructor Detail
Instance Method Detail
Toggle automatic cleaning of temporary files (enabled by default)
clear all draw and gnuplot commands Note: This method leaves all other plot properties untouched.
Draw plot object with given what
, using
and with
expressions (e.g., plot.draw("sin(x)*cos(x)", "", "linespoints")
, (e.g., plot.draw("file.dat", "1:2", "points")
)).
Draw plot object with given using
and with
expressions (e.g., plot.draw("1:2", "points")
)).
Use this method to provide gnuplot commands to be executed before the plotting calls.
The vector of grid specs for the major and minor grid lines in the plot (for xtics, ytics, mxtics, etc.).
Save the plot in a file, with its extension defining the file format.
The extension of the file name determines the file format
The supported formats are: pdf
, eps
, svg
, png
, and jpeg
Thus, to save a plot in pdf
format, choose a file as in plot.pdf
.
Note: This removes temporary files after saving if #autoclean
is enabled. default is enabled
Show the plot in a popup-window
Note: This removes temporary files after saving if #autoclean
is enabled. default is enabled
Set the size of the plot (in unit of points, with 1 inch = 72 points).
The specs for the fill style of the plot elements in the plot that can be painted.