Python Forum
accessing value array object
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
accessing value array object
#1
Hi
how do I get the value in this kind of object called xc :
array([x |--> 0.5798895118966687], dtype=object)
I would like to copy 0.5798895118966687 in a var named a
(I have been trying without success for ten minutes now. ;-( )
Reply
#2
Oops sorry, I found a way:float(xc[0])
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Appending object to array Busby 2 1,667 Jun-10-2020, 09:00 PM
Last Post: deanhystad
  Accessing method as function object ClassicalSoul 2 1,975 Feb-14-2020, 09:31 PM
Last Post: wavic
  accessing array without commas rjnabil1994 1 2,468 Feb-10-2019, 06:29 PM
Last Post: Larz60+

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020