ConnectTool
 All Classes Namespaces Files Functions Variables Pages
Classes | Functions | Variables
plot_common Namespace Reference

Classes

class  PlotError
 

Functions

def sphere3D
 
def equator
 
def negative_color
 Compute hex code of the corresponding negative color. More...
 
def timeserie
 Plot a timeserie object. More...
 
def timeserie_axe
 Make axis for a timeserie plot. More...
 
def map2D
 
def fieldline3D
 
def fieldline2D
 Plot a list of fieldlines in a 2D plot. More...
 
def slice2D
 
def chole
 Plot a coronal hole element Chole. More...
 

Variables

dictionary colormaps
 

Function Documentation

def plot_common.chole (   sub,
  choles 
)

Plot a coronal hole element Chole.

Parameters
[in]sub,:an existant Axis or SubplotBase object
[in]choles,:list of module_chole.Chole() objects.
[out]img_chole,:list Artist object

Here is the caller graph for this function:

def plot_common.equator (   sub,
  color 
)
Plot dashed equator line.
Input:
  * sub: an existant matplotlib.axes._subplots.Axes3DSubplot object
  * color
Output:
  * eq: matplotlib.lines.Line2D object
def plot_common.fieldline2D (   sub,
  fieldlines,
  color,
  label,
  proj = 'rlon' 
)

Plot a list of fieldlines in a 2D plot.

Parameters
[in]sub,:an existant matplotlib.axes._subplots.Axes3DSubplot object created with polar projection (sub = fig.add_subplot(111, projection='polar'))
[in]fieldlines,:list of fieldlines
[in]color
[in]label,:legend for the first fieldline only
[in]proj,:'rlon' for radius,longitude plot, 'rlat' for radius,latitude plot.
[out]fl,:list of matplotlib.lines.Line2D objects
def plot_common.fieldline3D (   sub,
  fieldlines,
  color,
  label 
)
Plot a list of fieldlines.
Input:
  * sub: an existant matplotlib.axes._subplots.Axes3DSubplot object
  * fieldlines: list of fieldlines
  * color
  * label: legend for the first fieldline only
Output:
  * fl: list of mpl_toolkits.mplot3d.art3d objects

Here is the call graph for this function:

def plot_common.map2D (   sub,
  plotmap_type,
  map2D_data,
  vmin,
  vmax,
  zorder 
)
Plot a map2D background image.
Input:
  * sub: an existant Axis or SubplotBase object
  * plotmap_type: sth in ['WSO','NSO','ADAPT','SDO171','SDO193','SOHO171','SOHO195']
  * map2D_data: map2D object to be plot
  * vmin,vmax: min and max plot range
  * zorder: order of apparition in plot (0 means background, >0 foreground)
Output:
  * bimg: Artist object

Here is the call graph for this function:

def plot_common.negative_color (   color)

Compute hex code of the corresponding negative color.

Parameters
[in]color,:string for color
[out]negative,:hex code for negative color

Here is the caller graph for this function:

def plot_common.slice2D (   sub,
  cube3D_data,
  var,
  dim,
  i,
  vmin,
  vmax,
  zorder 
)
Plot a cube3D slice background image.
Input:
  * sub: an existant Axis or SubplotBase object
  * cube3D_data: cube3D object to be plot
  * var: br, bthe, bphi or b1, b2, b3
  * dim: 0 or 1 or 2. Slice dim to be plot.
  * i: index of the slice.
  * zorder: order of apparition in plot (0 means background, >0 foreground)
Output:
  * bimg: Artist object

Here is the call graph for this function:

def plot_common.sphere3D (   sub,
  x0,
  y0,
  z0,
  r,
  color 
)
Plot a sphere.
Input:
  * sub: an existant matplotlib.axes._subplots.Axes3DSubplot object
  * x0,y0,z0,r: center cartesian coordinate and radius
  * color
Output:
  * sphere: mpl_toolkits.mplot3d.art3d.Poly3DCollection object
def plot_common.timeserie (   sub,
  timeserie,
  color,
  index = 0,
  color_positive = False 
)

Plot a timeserie object.

Parameters
[in]sub,:an existant Axis or SubplotBase object
[in]timeserie,:map2D object to be plot
[in]color
[in]index,:as timeserie data is a tuple, select only the index-element of this tuple
[in]color_positive,:boolean. False by default. If True, input color for positive value, negative input color for negative
[out]Artistobject

Here is the call graph for this function:

def plot_common.timeserie_axe (   sub,
  timeserie,
  index = 0 
)

Make axis for a timeserie plot.

Variable Documentation

dictionary plot_common.colormaps
Initial value:
1 = {
2 'STD' : 'Greys',
3 'OBS_MAPS_WSO_ORIGIN' : 'Greys_r',
4 'OBS_MAPS_WSO_FILLED' : 'Greys_r',
5 'OBS_MAPS_NSO' : 'Greys_r',
6 'OBS_MAPS_ADAPT40' : 'Greys_r',
7 'OBS_MAPS_ADAPT41' : 'Greys_r',
8 'OBS_MAPS_SDO_AIA_171' : 'sdoaia171',
9 'OBS_MAPS_SDO_AIA_193' : 'sdoaia193',
10 'OBS_MAPS_SDO_HMI' : 'hmimag',
11 'OBS_MAPS_SOHO_EIT_171' : 'sohoeit171',
12 'OBS_MAPS_SOHO_EIT_195' : 'sohoeit195',
13 'OBS_MAPS_EUV2CARMAP_SDOSTA_171' : 'sdoaia171',
14 'OBS_MAPS_EUV2CARMAP_SDOSTA_193' : 'sdoaia193',
15 'OBS_MAPS_EUV2CARMAP_SDOSTA_304' : 'sdoaia304',
16 'QSLSQUASHER' : 'Greys',
17 }