Click here to Skip to main content
15,946,320 members

Comments by Zhang, G. (Top 11 by date)

Zhang, G. 10-Dec-17 18:20pm View    
In fact, the list can accomplish this function.
however, the numpy.array has more attribute and functions to use. so I still want use the array to store the data.
Zhang, G. 10-Dec-17 17:51pm View    
I mean to use the numpy.array to store a two-dimensional data, the first dim store the file or line number and the second dim store the data. And the data in each file or each line has different sum number.

another example:
1, 2, 3, 4, 5
1, 2, 4
2, 3, 5, 9, 10, 2, 3, 4, 7
1, 2

I want to use an array x[lineNum][data] to store them

in the code, we usually use the numpy.vstack(x, item) to add the data of each line
to the array.
but the vstack requires the data of each line should be the same length,
it will works under condition that the len(x[0])=len(x[1])=len(x[2])=...=len(x[N])

How to use the array to accomplish this function?
Zhang, G. 9-May-14 2:17am View    
Because the u.Count is not a fixed value.
in fact, I want to define:
private int nx;
public int Nx{get...set...}
private List<double> u=new List<double> (Nx)
but it is not work.
Zhang, G. 11-Apr-14 21:48pm View    
Thank you!!
Zhang, G. 11-Apr-14 21:48pm View    
Thank you!!