User Profile

Collapse

Profile Sidebar

Collapse
Benjamin Gross
Benjamin Gross
Last Activity: Jun 10 '11, 07:56 PM
Joined: Jun 4 '11
Location: New York, NY
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • I'm fairly new to Python (programming) so I don't feel all that comfortable creating classes right now. Thanks so much for your input and suggestions.
    See more | Go to post

    Leave a comment:


  • I starting off using a list of lists. However, I need to pass pairs of vectors (a date column along with a float column) into another function for processing.

    In a numpy array, this consist of:
    Code:
    numpyArray[:,0:2]
    It doesn't seem like there's as clean a way to do this with lists when I'm reading in an entire matrix of data. That's why i was thinking that the numpy.array() was probably the correct data type for me...
    See more | Go to post

    Leave a comment:


  • Thanks bvdet!

    If have different types in each column, (say of string() and float()) is there any easy way for me to use the map functionality in the list comprehension you provided to account for the different data types?

    Thanks for your help!
    See more | Go to post

    Leave a comment:


  • Import .csv to numpy instead of list to numpy

    Currently when I import a data file, I create a list, and then use the
    Code:
    numpy.array(lst)
    method to convert the list into a numpy array.

    However, ideally I would like to not have to use a transition data type before converting it to a numpy array (and import the .csv file directly into a numpy array).

    I have tried the
    Code:
    numpy.genfromtext()
    method, however, that does not keep the inherent matrix structure I am attempting...
    See more | Go to post
No activity results to display
Show More
Working...