If I read an ascii file with read_ascii() like so:

  a = read_ascii(file)

The "a" group has a data attribute which contains the entire data table as a 2D array. It also has 1D arrays for each column from the data table. Those 1D arrays have attribute names taken from the column labels.

If I do something to change the data table, is there a function that I can call that repopulates the 1D arrays with the columns of the altered data table?

For example:

  a = read_ascii(file) is, say, array<shape=(5,500)> =[:, (0 .. 10)]

now is, say, array<shape=(5,11)>

  a.repopulate_arrays()  # <---- the thing i am looking for....

Now, a.i0, etc should be array<shape=(11,)>

Hope that's clear.


 Bruce Ravel  ------------------------------------

 National Institute of Standards and Technology
 Synchrotron Science Group at NSLS-II
 Building 743, Room 114
 Upton NY, 11973

Ifeffit mailing list

Reply via email to