Project 350.14 Profitable app store profiles

The problem could very well lay elsewhere, but right now I think the problem is that one of my replace statements isn’t functioning correctly, but I’m not sure as to why.

I have two replace statements that are supposed to take a string and remove the commas and then the plus signs. After these replace statements I plan on turning the string into a float. The issue that I’m running into is that the replace statements seem to not fully remove all of the plus symbols and then the float conversion throws an error. I’m not sure what I’m doing wrong or how to fix this.

Any help would be appreciated. Thank you.

I’ll send out a link to my github where I have the rest of the notebook and the datasets, but I think the problem is within the photo, so it should be unnecessary.
Github: https://github.com/direnz/dataquest_python_basics

Any help would be appreciated. Thank you.

Hey Charlesd,

I think your problem is that you are making the changes you want(replacing ‘,’ and the ‘+’), but then you are not assigning those changes back to your variable. Try changing lines 10 & 11 in your code to the following:

n_installs = n_installs.replace(',', '')
n_installs = n_installs.replace('+', '')

Hope that helps!!

Oh my gosh, you’re right. I completely forgot to store the changed string into a variable. I can’t believe I didn’t catch that.

But thank you for your help!

It’s much appreciated. :grinning: