Closed g-weatherill closed 6 years ago
Hey,
I see the point of doing that. What about about making the class callable like a function (via __call__
instead of evaluate()
?) it basically maintains the current functionality (which might be handy, to postpone calculatation if needed) and adds yours by simply typing "()". Something like:
obj = NewmarkBeta(...) # as it is now. Evaluate later
result = NewmarkBeta(...)() # evaluate it now
As we already discussed, are there plans to separate plotting stuff from base code, so that if we include the code as backend we might never need to import matplotlib
? This might be of great help
Two changes are proposed that would modify the calls to specific functions:
Change the
smtk.response_spectrum.Response Spectrum
class to execute the response spectrum analysis immediate on instantiationChange the
smtk.trellis.trellis_plots.BaseTrellis
class so that.create_plot()
is not run on instantiation. Instead a simple.plot()
function should be added which is called subsequently. This can permit generation of trellis ground motion values without invoking the plotting functionality