Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Problem

Airplane Alien Bridesmaids Cloudy with a Chance of Meatballs Exorcist Fantastic Mr. Fox Forrest Gump Hangover Harold and Kumar Go to White Castle The Help Incredibles Jaws Monsters, Inc Psycho Raiders of the Lost Ark Silver Linings Playbook Titanic Twilight Eclipse Up Zoolander

Using java;

Create an array that represents recommended ratings for the user. There should be 20 numbers in this array, one for each movie. higher the number, the more strongly your program thinks the user will like the movie. The number should be the average over all 30 ratings for the movie that are greater than 0 (only include ratings for users who have actually seen the movie). However, it should be a weighted average: people who are more similar to the current user should have a higher weight than people who are less similar.

Calculating Similarity

Your program is going to try to decide whether or not you might like a movie that you haven't yet seen. It's going to come up with a score, which represents the likelihood that you'll enjoy it. If people who have tastes similar to yours seem to like it, the program will assign that movie a higher score. The question is, How do you determine similarity?

You can come up with your own way of judging how similar two people's ratings are. One suggestion is to compute what's called cosine similarity:

For person 1, compute the square of each movie rating for movies they have seen, and add these up and then take the square root. Store the result in a variable called p1. For example, if person 1 saw 3 movies and rated them 4, 4, and 2, then p1 = sqrt(4*4 + 4*4 + 2*2) = sqrt(36) = 6.

Do the same for person 2, and store the result in a variable called p2.

For each movie that both people have seen, compute the product of their ratings. Add up all of these products, and store the result in a variable called both. For example, if person 1 and person 2 both saw movies 7 and 14 (out of 20), and person 1 rated them as 4 for movie 7 and 2 for 14, and person 2 rated them as 2 for movie 7 and 3 for movie 14, then both = 4*2 + 2*3.

The cosine similarity score between person 1 and person 2 is (both / (p1 * p2)).

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M92822740

Have any Question?


Related Questions in Computer Engineering

Search the internet for 5 open source reporting software

Search the internet for 5 open source reporting software packages of your choice? Explain why you think these software packages are the best for BI/DSS Reporting? Choose one of them and do associated with the reporting s ...

What are some examples of when a data compression utility

What are some examples of when a data compression utility can be used for information stored on a computer's hard drive?

Start by assigning to variable answers a list containing an

Start by assigning to variable answers a list containing an arbitrary sequence of strings 'Y' and 'N'. For example: answers= ['Y','N','N','Y','N','Y','Y','Y','N','N','N'] Write Python statements corresponding to the foll ...

What is the difference between dekkers algorithm and igloo

What is the difference between Dekkers Algorithm and Igloo approach? Please provide examples that can explain this.

For the following reactionnbsp199nbspgrams ofnbspcarbon

For the following reaction,  19.9  grams of  carbon monoxide  are allowed to react with  14.4  grams of  oxygen gas . Carbon monoxide  ( g ) +  oxygen  ( g )  ------>  carbon dioxide  ( g ) What is the maximum amount of  ...

I really need help writing this c progam i have seen many

I really need help writing this C++ progam. I have seen many answers to this question on this site, but they are all deeply flawed. Design the following classes in C++. Person class is the base class for other classes. P ...

Question monicas reading comprehension score 22nbspmean

Question: Monica's reading comprehension score = 22  Mean fourth grade reading comprehension score = 19  Standard deviation of the fourth grade's reading comprehension = 1.8  Monica's z-score in math = 2.2  Mean fourth g ...

Based on land minerals and natural resources labor and

Based on land, minerals and natural resources, labor and entrepreneurial innovation, which country do you feel has the greatest long-term potential China or Russia.

In a survey of 3236 adults 1470 say they have started

In a survey of 3236 adults, 1470 say they have started paying bills online in the last year. Construct a? 99% confidence interval for the population proportion. Interpret the results.

Question suppose that a remote transmitter sends a message

Question : Suppose that a remote transmitter sends a message at 2500 Baud and the receiver is expecting the data rate to be 2400 Baud. Calculate the accumulated sample error for one character. Give the answer in bits.

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As