List of Arclines
[Data Format Handling functions]

Functions

static int xsh_arclist_lambda_compare (const void *one, const void *two)
void xsh_arclist_lambda_sort (xsh_arclist *list)
 sort arcline list by increasing lambda
int xsh_arclist_get_size (xsh_arclist *list)
 get size of arcline list
int xsh_arclist_get_nbrejected (xsh_arclist *list)
 get nb lines rejected in arcline list
float xsh_arclist_get_wavelength (xsh_arclist *list, int idx)
 get wavelength of a line in the arcline list
void xsh_arclist_reject (xsh_arclist *list, int idx)
 reject a line from the list
void xsh_arclist_restore (xsh_arclist *list, int idx)
 restore a line from the list
int xsh_arclist_is_rejected (xsh_arclist *list, int idx)
 give if a line is rejected
cpl_propertylist * xsh_arclist_get_header (xsh_arclist *list)
 get header of the table
void xsh_dump_arclist (xsh_arclist *list)
 Dump main info about an arcline_list.
xsh_arclistxsh_arclist_load (cpl_frame *frame)
 load an arcline list frame in arclist structure
void xsh_arcline_free (xsh_arcline **arc)
 free memory associated to a arcline
void xsh_arclist_free (xsh_arclist **list)
 free memory associated to a arclist
void xsh_arclist_clean_from_list (xsh_arclist *list, double *lambda, int size)
 Clean an arclist according to a list of valid lambda.
void xsh_arclist_clean_from_list_not_flagged (xsh_arclist *list, double *lambda, int *flag, int size)
void xsh_arclist_clean (xsh_arclist *list)
cpl_frame * xsh_arclist_save (xsh_arclist *list, const char *filename, const char *tag)
 save a arclist to a frame

Function Documentation

void xsh_arcline_free ( xsh_arcline **  arc  ) 

free memory associated to a arcline

Parameters:
arc the arcline to free

Definition at line 341 of file xsh_data_arclist.c.

Referenced by xsh_arclist_clean(), and xsh_arclist_free().

void xsh_arclist_clean ( xsh_arclist list  ) 
void xsh_arclist_clean_from_list ( xsh_arclist list,
double *  lambda,
int  size 
)

Clean an arclist according to a list of valid lambda.

Parameters:
[in] list The arclist (order by increasing wavelength)
[in] lambda The lambda array (order by increasing wavelength)
[in] size The size of lambda array

Definition at line 393 of file xsh_data_arclist.c.

References check, xsh_arclist::nbrejected, xsh_arclist::size, WAVELENGTH_PRECISION, xsh_arclist_clean(), xsh_arclist_get_wavelength(), xsh_arclist_reject(), XSH_ASSURE_NOT_NULL, and XSH_REGDEBUG.

Referenced by xsh_detect_arclines().

void xsh_arclist_clean_from_list_not_flagged ( xsh_arclist list,
double *  lambda,
int *  flag,
int  size 
)
void xsh_arclist_free ( xsh_arclist **  list  ) 

free memory associated to a arclist

Parameters:
list the arclist to free

Definition at line 361 of file xsh_data_arclist.c.

References xsh_arcline_free(), XSH_FREE, and xsh_free_propertylist().

Referenced by clean_arclist_data(), xsh_afcthetab_create(), xsh_arclist_load(), xsh_create_order_table(), xsh_detect_arclines(), and xsh_detect_arclines_dan().

cpl_propertylist* xsh_arclist_get_header ( xsh_arclist list  ) 

get header of the table

Parameters:
list the arclist
Returns:
the header associated to the table

Definition at line 224 of file xsh_data_arclist.c.

References xsh_arclist::header, and XSH_ASSURE_NOT_NULL.

Referenced by xsh_detect_arclines(), and xsh_detect_arclines_dan().

int xsh_arclist_get_nbrejected ( xsh_arclist list  ) 

get nb lines rejected in arcline list

Parameters:
list pointer to arcline_list
Returns:
the number of rejected lines

Definition at line 119 of file xsh_data_arclist.c.

References xsh_arclist::nbrejected, and XSH_ASSURE_NOT_NULL.

int xsh_arclist_get_size ( xsh_arclist list  ) 

get size of arcline list

Parameters:
list pointer to arcline_list
Returns:
the size

Definition at line 100 of file xsh_data_arclist.c.

References xsh_arclist::size, and XSH_ASSURE_NOT_NULL.

Referenced by clean_arclist_data(), theo_tab_filter(), theo_tab_model(), xsh_afcthetab_create(), xsh_create_order_table(), xsh_detect_arclines(), and xsh_detect_arclines_dan().

float xsh_arclist_get_wavelength ( xsh_arclist list,
int  idx 
)

get wavelength of a line in the arcline list

Parameters:
list pointer to arcline_list
idx index in the list
Returns:
the wavelength of the arcline

Definition at line 138 of file xsh_data_arclist.c.

References xsh_arclist::list, size, xsh_arcline::wavelength, XSH_ASSURE_NOT_ILLEGAL, and XSH_ASSURE_NOT_NULL.

Referenced by clean_arclist_data(), main(), theo_tab_filter(), theo_tab_model(), xsh_afcthetab_create(), xsh_arclist_clean_from_list(), and xsh_arclist_clean_from_list_not_flagged().

int xsh_arclist_is_rejected ( xsh_arclist list,
int  idx 
)

give if a line is rejected

Parameters:
list pointer to arcline_list
idx Index of the arc in the list
Returns:
1 if the line is rejected else 0

Definition at line 205 of file xsh_data_arclist.c.

References xsh_arclist::rejected, size, XSH_ASSURE_NOT_ILLEGAL, and XSH_ASSURE_NOT_NULL.

Referenced by xsh_arclist_clean().

static int xsh_arclist_lambda_compare ( const void *  one,
const void *  two 
) [static]

Definition at line 59 of file xsh_data_arclist.c.

References xsh_arcline::wavelength.

Referenced by xsh_arclist_lambda_sort().

void xsh_arclist_lambda_sort ( xsh_arclist list  ) 

sort arcline list by increasing lambda

Parameters:
list pointer to arcline_list

Definition at line 87 of file xsh_data_arclist.c.

References xsh_arclist::list, xsh_arclist::size, and xsh_arclist_lambda_compare().

Referenced by xsh_detect_arclines(), and xsh_detect_arclines_dan().

xsh_arclist* xsh_arclist_load ( cpl_frame *  frame  ) 
void xsh_arclist_reject ( xsh_arclist list,
int  idx 
)

reject a line from the list

Parameters:
list pointer to arcline_list
idx index of the line to reject

Definition at line 158 of file xsh_data_arclist.c.

References xsh_arclist::nbrejected, xsh_arclist::rejected, size, XSH_ASSURE_NOT_ILLEGAL, and XSH_ASSURE_NOT_NULL.

Referenced by clean_arclist_data(), theo_tab_filter(), theo_tab_model(), xsh_arclist_clean_from_list(), and xsh_arclist_clean_from_list_not_flagged().

void xsh_arclist_restore ( xsh_arclist list,
int  idx 
)

restore a line from the list

Parameters:
list pointer to arcline_list
idx index of the line to reject

Definition at line 181 of file xsh_data_arclist.c.

References xsh_arclist::nbrejected, xsh_arclist::rejected, size, XSH_ASSURE_NOT_ILLEGAL, and XSH_ASSURE_NOT_NULL.

cpl_frame* xsh_arclist_save ( xsh_arclist list,
const char *  filename,
const char *  tag 
)
void xsh_dump_arclist ( xsh_arclist list  ) 

Dump main info about an arcline_list.

Parameters:
list pointer to arcline_list

Definition at line 241 of file xsh_data_arclist.c.

References xsh_arcline::comment, xsh_arcline::flux, xsh_arclist::list, xsh_arcline::name, xsh_arclist::size, xsh_arcline::wavelength, XSH_ASSURE_NOT_NULL, and xsh_msg.


Generated on 13 Mar 2013 for X-shooter Pipeline Reference Manual by  doxygen 1.6.1