about 1 year ago
Need a lil help with Python coding.
I have a data frame as:
Tweet Text word1 word2 word3 word4
Tweet1 0.23 0 0 0
Tweet2 0 0.45 0 0
The values in the columns word1 word2 word3 word4 are created from TFIDF vectorizer
I want to multiply these values by a custom weight basis the location of the words in the tweet.
Like I will check if word1 is in the first half os Tweet1 then multiply by 0.75 if the word2 is in second half of tweet2 then multiply by 0.25
How do I code this logic in Python.
Any help please??
Starting with Chrome version 45, NPAPI is no longer supported for Google Chrome. For more information, see Chrome and NPAPI (blog.chromium.org).
Firefox and Microsoft Internet Explorer are recommended browsers for websites using java applets.
Chrome Version Support
Are you sure, you want to delete this comment?
Terms of Service
| © copyright 2021 FindNerd.com. All rights reserved.
Sign up using