Returns a deepcopy of the Catalog object.
Return type: | Catalog |
---|---|
Returns: | Copy of current catalog. |
Examples
Create a Catalog and copy it
>>> from obspy.core.event import readEvents
>>> cat = readEvents()
>>> cat2 = cat.copy()
The two objects are not the same:
>>> cat is cat2
False
But they have equal data:
>>> cat == cat2
True
The following example shows how to make an alias but not copy the data. Any changes on st3 would also change the contents of st.
>>> cat3 = cat
>>> cat is cat3
True
>>> cat == cat3
True