StokesCylindricalPlus.h
1 /***************************************************************************
2  *
3  * Copyright (C) 2010 by Jonathan Khoo
4  * Licensed under the Academic Free License version 2.1
5  *
6  ***************************************************************************/
7 
8 #ifndef __Pulsar_StokesCylindricalPlus_h
9 #define __Pulsar_StokesCylindricalPlus_h
10 
11 #include "Pulsar/MultiPhase.h"
12 #include "Pulsar/PosAngPlot.h"
13 #include "Pulsar/StokesPlot.h"
14 
15 namespace Pulsar {
16 
17  class PolnProfile;
18 
20  class StokesCylindricalPlus : public MultiPhase {
21 
22  public:
24  StokesCylindricalPlus (float crop = 0.0);
25 
28 
31 
32  TextInterface::Parser* get_interface_again ();
33 
34  // Text interface to the StokesCylindricalPlus class
35  class Interface : public TextInterface::To<StokesCylindricalPlus> {
36  public:
37  Interface (StokesCylindricalPlus* = 0);
38  };
39 
41  void prepare (const Archive*);
42 
44  void set_subint (const Index& _isubint) { isubint = _isubint; }
45  Index get_subint () const { return isubint; }
46 
48  void set_chan (const Index& _ichan) { ichan = _ichan; }
49  Index get_chan () const { return ichan; }
50 
52  StokesPlot* get_flux () { return &flux; }
53 
55  StokesPlot* get_flux_cropped () { return &flux_cropped; }
56 
58  PosAngPlot* get_orientation () { return &orientation; }
59 
61  void set_flux_crop (const float _crop);
62  float get_flux_crop () const { return crop; }
63 
64  protected:
65  StokesPlot flux;
66  StokesPlot flux_cropped;
67  PosAngPlot orientation;
68  Index isubint;
69  Index ichan;
70  float crop;
71 
72  template<class T> void prepare (T* plot)
73  {
74  plot->set_subint (isubint);
75  plot->set_chan (ichan);
76  }
77  };
78 }
79 
80 #endif
void set_plot_colours(const std::string &plot)
Set the colour for each value plotted.
Definition: StokesPlot.h:53
void set_viewport(float x0, float x1, float y0, float y1)
Set the viewport (normalized device coordinates)
Definition: PlotFrame.C:256
PlotAxis * get_x_axis(bool allow_transpose)
Get the x-axis.
Definition: PlotFrame.C:204
Combines an index value and integrate flag.
Definition: Index.h:24
void prepare(const Archive *)
Ensure that frames are properly initialized.
Definition: StokesCylindricalPlus.C:69
PlotLabel * get_label_below()
Get the below-frame label.
Definition: PlotFrame.h:74
void plot(const Archive *)
Plot in the current viewport.
Definition: MultiPlot.C:43
StokesPlot * get_flux_cropped()
Get the StokesPlot (lower, cropped)
Definition: StokesCylindricalPlus.h:60
PlotAxis * get_y_axis(bool allow_transpose)
Get the y-axis.
Definition: PlotFrame.C:228
The primary interface to pulsar observational data.
Definition: Archive.h:45
PosAngPlot * get_orientation()
Get the PosAngPlot.
Definition: StokesCylindricalPlus.h:63
void rem_opt(char opt)
Remove from the options to be passed to pgbox for this axis.
Definition: PlotAxis.C:30
TextInterface::Parser * get_interface()
Get the text interface to the configuration attributes.
Definition: StokesCylindricalPlus.C:64
PlotLabel * get_label_above()
Get the above-frame label.
Definition: PlotAttributes.h:59
StokesPlot * get_flux()
Get the StokesPlot.
Definition: StokesCylindricalPlus.h:57
Plots a polarization pulse profile.
Definition: StokesPlot.h:24
StokesCylindricalPlus(float crop=0.0)
Default constructor.
Definition: StokesCylindricalPlus.C:11
void set_plot_lines(const std::string &plot)
Set the line style for each value plotted.
Definition: StokesPlot.h:57
void manage(Plot *)
Auto-manage a plot.
Definition: MultiPlot.C:130
Plots the position angle of the linearly polarized radiation.
Definition: PosAngPlot.h:24
Plots a single pulse profile.
Definition: StokesCylindricalPlus.h:25
virtual PlotFrame * get_frame()
Get the frame.
Definition: FramedPlot.C:27
void set_plot_values(const std::string &plot)
Set the values to be plotted (one or more of I,Q,U,V,L,p)
Definition: StokesPlot.h:49
void set_label(const std::string &_label, bool overwrite)
Set the label to be drawn on the axis.
Definition: PlotAxis.C:37
void set_chan(const Index &_ichan)
Set the frequency channel to plot (where applicable)
Definition: StokesCylindricalPlus.h:53
void set_flux_crop(const float _crop)
Set the y-axis zoom value.
Definition: StokesCylindricalPlus.C:58
~StokesCylindricalPlus()
Destructor.
Definition: StokesCylindricalPlus.C:56
Defines the PSRCHIVE library.
Definition: CalSource.h:17
void set_subint(const Index &_isubint)
Set the sub-integration to plot (where applicable)
Definition: StokesCylindricalPlus.h:49
void set_all(const std::string &label)
Set all labels to the specified value.
Definition: PlotLabel.h:70

Generated using doxygen 1.8.17