-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Description
I've been using this routine to print out all the attributes of the ObsSequence object. Worth having as a utility routine?
import inspect
routines = []
non_routines = []
for attr in dir(obs_seq):
if attr.startswith('__'):
continue
value = getattr(obs_seq, attr)
if inspect.isroutine(value):
routines.append(attr)
else:
non_routines.append(attr)
print("\nNon-routines (data attributes):")
for n in non_routines:
print(" -", n)
print("Routines (methods/functions):")
for r in routines:
print(" -", r)
Metadata
Metadata
Assignees
Labels
No labels