0

I have a list of values:

val = [array([5, 6, 7, 8, 9, 2, 4, 5, 10]), array([4, 3, 4, 5, 1, 7, 6, 6, 7]), array([1, 2, 3, 4, 5, 6, 7, 8 ,9])]

All i want to do is apply a function to each of the elements and save the new computed values like:

val = val.apply((lambda x: myfunct(x)))

But it gives me an error.

magicsword
  • 1,179
  • 3
  • 16
  • 26
  • 1
    Not sure where you found `.apply()`. The function is [`map`](https://docs.python.org/3/library/functions.html#map), as in `map(myfunct, val)`. – Ry- Mar 23 '17 at 01:53
  • 1
    "But it gives me an error" -- why not say what that error is? – John Coleman Mar 23 '17 at 01:57

0 Answers0