67 void SetTitle(
const std::string& title);
79 void SetExtra(
const std::string& extra);
185 void Add(
double x,
double y);
194 void Add(
double x,
double y,
double errorDelta);
204 void Add(
double x,
double y,
double xErrorDelta,
double yErrorDelta);
253 Gnuplot2dFunction(
const std::string& title =
"Untitled",
const std::string& function =
"");
291 void SetStyle(
const std::string& style);
300 void Add(
double x,
double y,
double z);
348 Gnuplot3dFunction(
const std::string& title =
"Untitled",
const std::string& function =
"");
378 Gnuplot(
const std::string& outputFilename =
"",
const std::string& title =
"");
404 void SetTitle(
const std::string& title);
410 void SetLegend(
const std::string& xLegend,
const std::string& yLegend);
415 void SetExtra(
const std::string& extra);
449 void GenerateOutput(std::ostream& osControl, std::ostream& osData, std::string dataFileName);
526 void GenerateOutput(std::ostream& osControl, std::ostream& osData, std::string dataFileName);
Class to represent a 2D points plot.
void AddEmptyLine()
Add an empty line in the data output sequence.
static Style m_defaultStyle
default plot style
static void SetDefaultStyle(Style style)
Change default style for all newly created objects.
ErrorBars
Whether errorbars should be used for this dataset.
static void SetDefaultErrorBars(ErrorBars errorBars)
Change default errorbars style for all newly created objects.
void SetErrorBars(ErrorBars errorBars)
std::vector< Point > PointSet
The set of points in the dataset.
void SetStyle(Style style)
void Add(double x, double y)
Style
The plotting style to use for this dataset.
static ErrorBars m_defaultErrorBars
default error bars type
Class to represent a 2D function expression plot.
void SetFunction(const std::string &function)
Class to represent a 3D points plot.
void AddEmptyLine()
Add an empty line in the data output sequence.
std::vector< Point > PointSet
The set of points in the dataset.
static std::string m_defaultStyle
default plot style
void Add(double x, double y, double z)
static void SetDefaultStyle(const std::string &style)
Change default style for all newly created objects.
void SetStyle(const std::string &style)
Class to represent a 3D function expression plot.
void SetFunction(const std::string &function)
a simple class to group together multiple gnuplots into one file, e.g.
std::string m_outputFilename
Output file name.
void AddPlot(const Gnuplot &plot)
void SetTerminal(const std::string &terminal)
Gnuplot & GetPlot(unsigned int id)
Return a pointer to one of the added plots.
std::string m_terminal
Gnuplot "terminal" to use.
Plots m_plots
Plots in the collection.
void GenerateOutput(std::ostream &os)
std::vector< Gnuplot > Plots
Type of the Gnuplot collection.
Abstract class to store a plot line to be used by ns3::Gnuplot.
static void SetDefaultExtra(const std::string &extra)
Change extra formatting style parameters for newly created objects.
GnuplotDataset & operator=(const GnuplotDataset &original)
Reference-counting assignment operator.
void SetExtra(const std::string &extra)
Add extra formatting parameters to this dataset.
Data * m_data
Reference counted data object.
static std::string m_defaultExtra
Extra gnuplot parameters set on every newly created dataset.
void SetTitle(const std::string &title)
Change line title.
~GnuplotDataset()
Reference-counting destructor.
a simple class to generate gnuplot-ready plotting commands from a set of datasets.
std::string m_yLegend
Y axis legend.
void AddDataset(const GnuplotDataset &dataset)
void SetLegend(const std::string &xLegend, const std::string &yLegend)
void SetTerminal(const std::string &terminal)
std::string m_terminal
Gnuplot "terminal" to use.
std::string m_extra
extra parameters for the plot
unsigned int m_dataFileDatasetIndex
Data set index to plot.
void AppendExtra(const std::string &extra)
Datasets m_datasets
Data sets.
void GenerateOutput(std::ostream &os)
Writes gnuplot commands and data values to a single output stream.
std::string m_title
Plot title.
std::vector< GnuplotDataset > Datasets
Type for Datasets to be used in plots.
void SetDataFileDatasetIndex(unsigned int index)
Sets the current data stream index in the data file.
std::string m_xLegend
X axis legend.
std::string m_outputFilename
Output file name.
void SetExtra(const std::string &extra)
void SetTitle(const std::string &title)
void SetOutputFilename(const std::string &outputFilename)
bool m_generateOneOutputFile
true if only one plot will be generated
static std::string DetectTerminal(const std::string &filename)
Crude attempt to auto-detect the correct terminal setting by inspecting the filename's extension.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
Structure storing the data to for a 2D plot.
bool empty
the point is empty
Structure storing the function to be used for a 2D plot.
Structure storing the data for a 3D plot.
bool empty
the point is empty
Structure storing the function to be used for a 3D plot.
Structure storing the data to plot.