Giter Club home page Giter Club logo

depression-tweets's Introduction

Depression Tweets Analysis ๐Ÿ“Š

Depression is a common illness worldwide, with more than 264 million people affected. Depression is different from usual mood fluctuations and short-lived emotional responses to challenges in everyday life. Especially when long-lasting and with moderate or severe intensity, depression may become a serious health condition. It can cause the affected person to suffer greatly and function poorly at work, at school and in the family. At its worst, depression can lead to suicide. Close to 800 000 people die due to suicide every year. Suicide is the second leading cause of death in 15-29-year-olds.
-- WHO

Sentiment analysis for depression based on Twitter posts. The aim of this project is to analyze linguistic markers in social media posts and creating a model that can give an invidual insight into user's mental mealth.

Big shoutout to twintproject for their handy tweets scraping tool - Twint.

Models

Tensorflow

To detect whether the post contains anxious linguistic markers, using the Tensorflow library I builded a CNN of a simple architecture with a summary shown below.

In the end the model had accuracy of 96.98% and the loss of 0.14%.

Sklearn

An approach to try different classifiers available in Sklearn library, such as:

  • KNeighborsRegressor(K-nn)
  • Lasso
  • Ridge
  • ElasticNet
  • GradientBoostingRegressor
  • RandomForestRegressor
  • ExtraTreesRegressor


From left to right: R^2 score, Mean Squared Error, Mean Absolute Error

The RandomForestClassifier turnt out to be the best among them with final score of 99.19% accuracy, so even better than neural network.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.