Answers for "Python NumPy asarray_chkfinite Function Example Raises Value Error"

0

Python NumPy asarray_chkfinite Function Example Raises Value Error

# welcome to softhunt.net
# Python program explaining
# numpy.asarray_chkfinite() function
# when value error occurs

import numpy as np

my_list = [1, 2, 3, 4, np.nan]

print ("Input scalar : ", my_list)
	
out_arr = np.asarray_chkfinite(my_list)
print ("output fortan array from input scalar : ", out_arr)
Posted by: Guest on April-24-2022

Python Answers by Framework

Browse Popular Code Answers by Language