Changeset 568


Ignore:
Timestamp:
Mar 7, 2012, 4:11:07 PM (13 years ago)
Author:
tnavarro
Message:

tool to read and plot not-binned data - useful for data from observations

Location:
trunk/UTIL/PYTHON
Files:
2 added
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/UTIL/PYTHON/myplot.py

    r562 r568  
    223223        subh = 99999
    224224    elif numplot == 1:
    225         subv = 99999
    226         subh = 99999
     225        subv = 1
     226        subh = 1
    227227    elif numplot == 2:
    228228        subv = 1 #2
     
    999999           
    10001000  return zesaxis
     1001
     1002## Author: TN
     1003def readdata(data,datatype,coord1,coord2):
     1004## Read sparse data
     1005  from numpy import empty
     1006  if datatype is 'txt':
     1007     if len(data[coord1].shape) == 1:
     1008         return data[coord1][:]
     1009     elif len(data[coord1].shape) == 2:
     1010         return data[coord1][:,int(coord2)-1]
     1011     else:
     1012         errormess('error in readdata')
     1013  elif datatype is 'sav':
     1014     return data[coord1][coord2]
     1015  else:
     1016     errormess(datatype+' type is not supported!')
     1017
    10011018
    10021019## Author: AS
Note: See TracChangeset for help on using the changeset viewer.