writing codes(algorithm) with Matlab (octave) for kanpsack and optimization?

Anonymous
timer Asked: Nov 15th, 2016

Question description

Please solve the three problems in the attachment with Matlab(or Octave). Code quality and instructions are explained at the end of the word document. Please follow those instructions.

One of the questions is as below for your reference.

1. Portfolio optimization

Imagine you're currently working on Wall Street and your boss asks you to analyse some historic pricing data to figure out when would have been the best time to buy a certain stock and when would have been the best time to sell the stock.

You are given a vector of data with historic prices and your job is to write a MATLAB function which:

. Gives the index of the price vector at which to buy the stock

. Gives the index of the price vector at which to sell the stock

. Gives the profit that could have been obtained

You may assume that there are no transaction costs, that you can't buy and sell the stock in the same period, and that time is linear so you must buy a stock before selling it.


Thank you very much.

Studypool has helped 1,244,100 students
flag Report DMCA
Similar Questions
Hot Questions
Related Tags
Study Guides

Brown University





1271 Tutors

California Institute of Technology




2131 Tutors

Carnegie Mellon University




982 Tutors

Columbia University





1256 Tutors

Dartmouth University





2113 Tutors

Emory University





2279 Tutors

Harvard University





599 Tutors

Massachusetts Institute of Technology



2319 Tutors

New York University





1645 Tutors

Notre Dam University





1911 Tutors

Oklahoma University





2122 Tutors

Pennsylvania State University





932 Tutors

Princeton University





1211 Tutors

Stanford University





983 Tutors

University of California





1282 Tutors

Oxford University





123 Tutors

Yale University





2325 Tutors