Changeset 126 for trunk/SRC


Ignore:
Timestamp:
07/06/06 16:13:57 (18 years ago)
Author:
pinsard
Message:

improvements of Calendar/*.pro header

Location:
trunk/SRC/Calendar
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/SRC/Calendar/date2jul.pro

    r118 r126  
    44;+ 
    55; 
    6 ; @file_comments gives julian day equivalent of a date in yyyymmdd format  
     6; @file_comments  
     7; gives julian day equivalent of a date in yyyymmdd format 
    78; 
    89; @categories calendar 
     
    1011; @param date {in}{required} date in yyyymmdd format 
    1112; 
    12 ; @keyword /GRADS {in}{optional}  
    13 ;               if  1 <= year <= 49 --> year = 2000 + year 
    14 ;               if 50 <= year <= 99 --> year = 1900 + year 
     13; @keyword GRADS {in}{optional} 
     14; if  1 <= year <= 49 --> year = 2000 + year 
     15; if 50 <= year <= 99 --> year = 1900 + year 
    1516; 
    1617; @returns date in julian day 
    1718; 
    18 ; @examples  
     19; @examples 
    1920; 
    20 ;    IDL> jday = juldate(19930124) 
    21 ;    IDL> print, date2jul(19931205) EQ julday(12,5,1993)  
     21; IDL> jday = juldate(19930124) 
     22; IDL> print, date2jul(19931205) EQ julday(12,5,1993) 
    2223;       1 
    23 ;    IDL> print, date2jul(931205,/grads) EQ julday(12,5,1993)  
     24; IDL> print, date2jul(931205,/grads) EQ julday(12,5,1993) 
    2425;       1 
    2526; 
  • trunk/SRC/Calendar/date2string.pro

    r118 r126  
    44;+ 
    55; 
    6 ; @file_comments create a nice and readable format to print a date 
     6; @file_comments 
     7; create a nice and readable format to print a date 
    78; 
    89; @categories calendar, string 
     
    1617; @returns a string containing the date in a easy readable format 
    1718; 
    18 ; @examples  
     19; @examples 
    1920; 
    20 ;    IDL> print, date2string(19900123) 
     21; IDL> print, date2string(19900123) 
    2122;    Jan 23, 1990 
    22 ;    IDL> print, date2string(19900123, format = '(C(CMOA))') 
     23; IDL> print, date2string(19900123, format = '(C(CMOA))') 
    2324;    JAN 23, 1990 
    2425; 
  • trunk/SRC/Calendar/daysinmonth.pro

    r118 r126  
    44;+ 
    55; 
    6 ; @file_comments give the number of days in a specific month 
     6; @file_comments 
     7; give the number of days in a specific month 
    78; 
    89; @categories calendar 
    910; 
    10 ; @param month {in}{optional}  
    11 ; @param year {in}{optional}  
    12 ; Year is used only if the  common variable key_caltype = 'greg'.  
    13 ; In that case, month and year must have the same number of elements.  
     11; @param month {in}{optional} 
     12; @param year {in}{optional} 
     13; Year is used only if the  common variable key_caltype = 'greg'. 
     14; In that case, month and year must have the same number of elements. 
    1415; If not provided, we take month and year from "time" common variable. 
    1516; 
     
    1718; 
    1819; @uses cm_4cal 
    19 ;         
    20 ; @examples  
     20; 
     21; @examples 
    2122; IDL> ndays = daysinmonth(2, 2000) 
    2223; 
     
    6061      days_in_mth = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31] 
    6162      return, days_in_mth[month-1] + leapyr(year)*(month EQ 2) 
    62     END  
     63    END 
    6364    ELSE:return, report('only 3 types of calendar are accepted: greg, 360d and noleap') 
    6465  ENDCASE 
    6566 
    66 END  
     67END 
  • trunk/SRC/Calendar/jul2date.pro

    r118 r126  
    44;+ 
    55; 
    6 ; @file_comments gives yyyymmdd date equivalent of a julian day 
     6; @file_comments 
     7; gives yyyymmdd date equivalent of a julian day 
    78; 
    89; @categories calendar 
     
    1213; @returns date in yyyymmdd format 
    1314; 
    14 ; @examples  
     15; @examples 
    1516; 
    16 ;    IDL> print, jul2date(julday(12,23,1999)) 
     17; IDL> print, jul2date(julday(12,23,1999)) 
    1718;        19991223 
    1819; 
  • trunk/SRC/Calendar/leapyr.pro

    r118 r126  
    22;+ 
    33; 
    4 ; @file_comments determine whether the input year is a leap year or not 
     4; @file_comments 
     5; determine whether the input year is a leap year or not 
    56; Very useful for finding number of days in a year. 
    67; eg. NUM_DAYS_IN_YR = 365 + leapyr(year) 
     
    1011; @param year {in}{required} year to be tested as a leap year 
    1112; 
    12 ; @returns 0 then not a leap year  
     13; @returns 0 then not a leap year 
    1314;          1 then year is a leap year 
    1415; 
     
    2526;       November 2004: correction for century years... S. Masson; 
    2627; 
    27 ;       Every year divisible by 4 is a leap year.  
    28 ;       But every year divisible by 100 is NOT a leap year  
     28;       Every year divisible by 4 is a leap year. 
     29;       But every year divisible by 100 is NOT a leap year 
    2930;       Unless the year is also divisible by 400, then it is still a 
    3031;       leap year. 
    3132;       This means that year 1800, 1900, 2100, 2200, 2300 and 2500 are 
    32 ;       NOT leap years, while year 2000 and 2400 are leap years.  
     33;       NOT leap years, while year 2000 and 2400 are leap years. 
    3334;       + supress the automatic change 89 -> 1989 
    3435; 
     
    4950  IF n_elements(key_caltype) EQ 0 THEN key_caltype = 'greg' 
    5051; 
    51   IF key_caltype NE 'greg' THEN BEGIN  
     52  IF key_caltype NE 'greg' THEN BEGIN 
    5253    sd = size(yr, /dimensions) 
    5354    IF sd[0] EQ 0 THEN return, 0b ELSE return, bytarr(size(yr, /dimensions)) 
  • trunk/SRC/Calendar/monthname.pro

    r118 r126  
    44;+ 
    55; 
    6 ; @file_comments gives the name of a month 
     6; @file_comments 
     7; gives the name of a month 
    78; 
    89; @categories calendar 
    9 ;  
     10; 
    1011; @param mm1 {in}{required}  the month number (from 1 to 12) 
    1112; 
     
    1617; @returns the month's name 
    1718; 
    18 ; @examples  
     19; @examples 
    1920; IDL> name=monthname(2) 
    2021; 
Note: See TracChangeset for help on using the changeset viewer.