Search found 4 matches

by Aisangam
29 Mar 2019
Forum: General Discussions
Topic: Sessions and Cookies
Replies: 1
Views: 87

Re: Sessions and Cookies

Thanks for the Questions. This is not as difficult as you think. Please see the below solution To understand the difference between session and cookies, please understand the concept of http. What is http is an important question which should come to us if you are sending request or receive respons...
by Aisangam
27 Mar 2019
Forum: Fixing Errors Python
Topic: Convering dictionary into dataframe pandas python
Replies: 1
Views: 88

Re: Convering dictionary into dataframe pandas python

As I could look into the code, you have made the dictionary which holds both key and value. Data frame will take these keys as the headers and values as the rows. I hope you will also visit http://www.aisangam.com/blog/quick-introduction-to-understand-pandas-and-dataframe/ to get used to basics of p...
by Aisangam
27 Mar 2019
Forum: Fixing Errors Python
Topic: ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all() | Python
Replies: 1
Views: 61

Re: ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all() | Python

@ programmer as i could see that you are trying to use or operator for two condition. Please execute the below code instead of

Code: Select all

print(array[array<0.5 or array>0.5])
Code to execute

Code: Select all

print(np.logical_or(array[array<0.5,array>0.5)
I hope this will resolve your error.
by Aisangam
26 Mar 2019
Forum: Fixing Errors Python
Topic: AttributeError: 'float' object has no attribute 'lower' | Python
Replies: 0
Views: 50

AttributeError: 'float' object has no attribute 'lower' | Python

I have come across this error many times while playing with pandas. I have been trying to transform all the rows of a data frame into lower case. While I was performing the task i.e is df['column']=df['column'].apply(lambda x:x.lower()) I got the below error:- AttributeError Traceback (most recent c...