13 Replies Latest reply: Jun 28, 2017 2:26 PM by kevin vargas RSS

    Filtering out data

    Jess K

      Dear all

       

      I am working with the following data and is required to list the genres of movies that Lawyers liked the most (based on Rating).

      I need to create a bar chart to list the Title and the Total Rating (only ratings by Lawyers and exclude all other occupation).

      What codes do I place in my expression to calculate the total ratings of lawyers only?

       

      Thank you!

       

           

      MovieIDTitleRatingGenresUserIDGenderOccupation
      1Toy Story (1995)5Animation719MLawyer
      2Jumanji (1995)4Adventure1056MStudent
      3Grumpier Old Men (1995)4Comedy1187FLawyer
      4Waiting to Exhale (1995)5Comedy1200MLawyer
      5Father of the Bride Part II (1995)5Comedy1296MLawyer
      6Heat (1995)4Action1458MTeacher
      7Sabrina (1995)5Comedy1509MLawyer
      8Tom and Huck (1995)3Children's1573MStudent
      9Sudden Death (1995)4Action1919MLawyer
      10GoldenEye (1995)3Action1926FLawyer
      11American PresidentThe (1995)3Drama2045FTeacher
      12Dracula: Dead and Loving It (1995)5Horror2120MStudent
      13Balto (1995)5Children's2169MStudent
      14Nixon (1995)5Drama3234FLawyer
      15Cutthroat Island (1995)5Action3594MLawyer
      16Casino (1995)4Thriller3780MLawyer
      17Sense and Sensibility (1995)4Drama4633MLawyer
      18Four Rooms (1995)5Thriller4707MTeacher
      19Ace Ventura: When Nature Calls (1995)5Comedy5074MLawyer