obspy.io.sac.sactrace.SACTrace._from_arrays¶
- classmethod SACTrace._from_arrays(hf=None, hi=None, hs=None, data=None)[source]¶
Low-level array-based constructor.
This constructor is good for getting a “blank” SAC object, and is used in other, perhaps more useful, alternate constructors (“See Also”). No value checking is done and header values are completely overwritten with the provided arrays, which is why this is a hidden constructor.
Parameters: - hf (numpy.ndarray of floats) SAC float header array
- hi (numpy.ndarray of ints) SAC int header array
- hs (numpy.ndarray of str) SAC string header array
- data SAC data array, optional.
If omitted or None, the header arrays are intialized according to arrayio.init_header_arrays(). If data is omitted, it is simply set to None on the corresponding SACTrace.
Example
>>> sac = SACTrace._from_arrays() >>> print(sac) Reference Time = XX/XX/XX (XXX) XX:XX:XX.XXXXXX iztype not set lcalda = False leven = False lovrok = False lpspol = False