Rank Algorithm is to analyse the video based on user experience on the comments of that video. Comments may contain positive as well as negative sentiment based on their view. Although based on likes and views
       it is easy to analyze the best video based on all the recommended video's but this phenomena fails in most of the cases. For example consider a YouTube channel X having 6 million subscribers for their channel it is easy to
       get an average of 3 million views within a day irrespective of the video, So based on this the video getting more likes and views can't be the best video in all the recommended video's based on the user experience on that
       video. Both postive and negative comments play a major role while computing the rank of the video.
      Step : 1      Start
      Step : 2     Let pos and neg be the list of postive and negative comments
      Step : 3     Calculate the percentage of postive comments by pos_perc=length(pos)/length(pos)+length(neg) and negative comments by neg_perc=length(neg)/length(pos)+length(neg)
      Step : 4     Compute the polarity sentiment of each and every comment in pos and neg by
                          for each comment in pos/neg comments
                          Compute comment.polarity for each and every comment and add those value to pos_list/neg_list
                          Later calculate the average polarity of positive comments by pos_pol=sum(pos_list)/len(pos_list) and negative comments by neg_pol=sum(neg_list)/len(neg_list)
      Step : 5     Calculate the percentage polarity of postive comments by pos_perc_pol=pos_perc * pos_pol and negative comments by neg_perc_pol=neg_perc * neg_pol
      Step : 6     Then compute the average of postive and negative polarity of comments to analyze the video by using pos_res=pos_perc_pol/pos_perc_pol+neg_perc_pol and neg_res=neg_perc_pol/pos_perc_pol+neg_perc_pol
      Step : 7     Based on pos_res and neg_res ranges we can compute the rank of video
      Step : 8      Stop
            1.    Polarity lies between [-1,1]
            2.    Rank lies between [0,1]
            //RANK ALGORITHM
            Algorithm    rank_Algo(list_of_comments)
            {
                  pos/neg_list=[  ]
                  for   comment:=1 to len(list_of_comments) do
                        {
                               pos/neg_list.add(comment.polarity)
                        }
                  pos/neg_comments_pol = sum(pos/neg_list)/len(pos/neg_list)
                  pos_perc=len(positive_comments)/len(positive_comments)+len(negative_comments)
                  neg_perc=len(negative_comments)/len(positive_comments)+len(negative_comments)
                  positive_polarity_percentage = pos_comments_pol*pos_perc
                  negative_polarity_percentage = neg_comments_pol*neg_perc
                  positive_rank = positive_polarity_percentage/positive_polarity_percentage+negative_polarity_percentage
                  negativetive_rank = negative_polarity_percentage/positive_polarity_percentage+negative_polarity_percentage
                  return  positive_rank  (or)  negative_rank
            }
      1.  Used for to analyze is best or not based on user experience.
      2.  Used in youtube recommendation system for to analyze best video.
      3.  Used by youtubers to know about their channel statistice.