Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
Parameters
----------
grand_up, grand_down : array-like
Series of voltages responses to positive (`grand_up`) and negative (`grand_down`) current pulses
t : array-like
Time values for `grand_up` and `grand_down`
storage_directory : str
Path to storage directory for files
Returns
-------
upfile, downfile : str
Paths to the saved files
"""
Manifest.safe_mkdir(storage_directory)
upfile = os.path.join(storage_directory, "upbase.dat")
downfile = os.path.join(storage_directory, "downbase.dat")
with open(upfile, 'w') as f:
np.savetxt(f, np.column_stack((t, grand_up)))
with open(downfile, 'w') as f:
np.savetxt(f, np.column_stack((t, grand_down)))
return upfile, downfile