Candlesticks are a common visualisation used to show the trends in a trading system. The candlesticks...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Candlesticks are a common visualisation used to show the trends in a trading system. The candlesticks show what happens in a series of time windows, in terms of the starting price, the end price and the highest and lowest prices seen. The following image shows a graphical plot of candlestick data: Price 120 100 80 May 1 2023 May 2 May 3 May 4 Open High Low Close 2023-05-01 100 120 80 110 2023-05-02 110 130 100 120 2023-05-03 90 100 70 80 2023-05-04 95 110 70 100 2023-05-05 80 120 75 115 May S Figure 1: example of a graphical candlestick plot. Each box represents the trading activity in a time period. The top and bottom of a box (the candle) represent the opening and closing value of a product. The top and bottom of the lines (the candlesticks) represent the highest and lowest value seen in that time frame. The red box on May 3rd indicates the value was lower at close than open, so value went down. You do not need to make a graphical plot - you will be making a text based plot. In the first task, you need to compute candlestick data from the exchange data for a particular product. Here is an example of the fields needed for candlestick data: Date TOTAL 15 MEAN price (total value / total price): 3 20 6.67 You can see that the mean price is 6.67. Close: the average price per unit in this time frame (same as Open, but for the current time frame) High: highest price seen this time frame Low: lowest price seen this time frame You should implement the candlestick data computation using a function which returns the following data type: std::vector<Candlestick> Note that it returns a vector of Candlestick objects. You will need to define your own Candlestick class that is suitable for representing candlestick data. One Candlestick object represents one candlestick. TASK 2: Create a text-based plot of the candlestick data Price 120 100 80 May 1 2023 May 2 May 3 May 4 May 5 The second task involves creating a text-based plot of the candlestick data. The figure above shows an example of a graphical plot. You should try and create something like that using text output. We recommend that you approach this by first manually typing out what kind of characters you might use in your plot to represent different things. Use your text editor to do this. E.g. you might use a '-' to represent the top of a box and a 'l' to represent the stalk. Once you know what you are aiming for, you should write C++ function that takes a vector of Candlestick objects as its input and generates a plot from that data. You will need to cope with quite a few problems here for example, how can you round the data so it is an appropriate range for your text-based plotter? How can you deal with horizontal and vertical positioning? You should attempt to use object-oriented techniques to make your code as neat and well organised as possible. TASK 3: Plot a text graph of some other trading data Task 3 involves plotting a text-based graph of some other trading data. It is up to you to decide what that data is, but it should be somehow derived from the crypto-currency data. Again, you need to plot it using text characters, and you should probably start by manually creating the text graph in your text editor do you know what you are aiming for, as we suggested for the previous task. Candlesticks are a common visualisation used to show the trends in a trading system. The candlesticks show what happens in a series of time windows, in terms of the starting price, the end price and the highest and lowest prices seen. The following image shows a graphical plot of candlestick data: Price 120 100 80 May 1 2023 May 2 May 3 May 4 Open High Low Close 2023-05-01 100 120 80 110 2023-05-02 110 130 100 120 2023-05-03 90 100 70 80 2023-05-04 95 110 70 100 2023-05-05 80 120 75 115 May S Figure 1: example of a graphical candlestick plot. Each box represents the trading activity in a time period. The top and bottom of a box (the candle) represent the opening and closing value of a product. The top and bottom of the lines (the candlesticks) represent the highest and lowest value seen in that time frame. The red box on May 3rd indicates the value was lower at close than open, so value went down. You do not need to make a graphical plot - you will be making a text based plot. In the first task, you need to compute candlestick data from the exchange data for a particular product. Here is an example of the fields needed for candlestick data: Date TOTAL 15 MEAN price (total value / total price): 3 20 6.67 You can see that the mean price is 6.67. Close: the average price per unit in this time frame (same as Open, but for the current time frame) High: highest price seen this time frame Low: lowest price seen this time frame You should implement the candlestick data computation using a function which returns the following data type: std::vector<Candlestick> Note that it returns a vector of Candlestick objects. You will need to define your own Candlestick class that is suitable for representing candlestick data. One Candlestick object represents one candlestick. TASK 2: Create a text-based plot of the candlestick data Price 120 100 80 May 1 2023 May 2 May 3 May 4 May 5 The second task involves creating a text-based plot of the candlestick data. The figure above shows an example of a graphical plot. You should try and create something like that using text output. We recommend that you approach this by first manually typing out what kind of characters you might use in your plot to represent different things. Use your text editor to do this. E.g. you might use a '-' to represent the top of a box and a 'l' to represent the stalk. Once you know what you are aiming for, you should write C++ function that takes a vector of Candlestick objects as its input and generates a plot from that data. You will need to cope with quite a few problems here for example, how can you round the data so it is an appropriate range for your text-based plotter? How can you deal with horizontal and vertical positioning? You should attempt to use object-oriented techniques to make your code as neat and well organised as possible. TASK 3: Plot a text graph of some other trading data Task 3 involves plotting a text-based graph of some other trading data. It is up to you to decide what that data is, but it should be somehow derived from the crypto-currency data. Again, you need to plot it using text characters, and you should probably start by manually creating the text graph in your text editor do you know what you are aiming for, as we suggested for the previous task.
Expert Answer:
Answer rating: 100% (QA)
Here I will provide you the solution of your asked query step by step with coding and an explanation of coe as well Here we will do all the 3 tasks step by step So here is the solution for the provide... View the full answer
Related Book For
Posted Date:
Students also viewed these programming questions
-
Planning is one of the most important management functions in any business. A front office managers first step in planning should involve determine the departments goals. Planning also includes...
-
Mike and Linda are a married couple who file jointly and have $100,000 of taxable income. They have three dependent children who are full-time students in 2022. Mike and Linda provided $8,000 of...
-
Chatham plant of Morril's Small Motor Division produces a major subassembly for a 6.0 horsepower motor for lawn mowers. The plant uses a standard costing system for production costing and control....
-
What is the profitability index for the following set of cash flows if the relevant discount rate is 10 percent? What if the discount rate is 15 percent? If it is 22 percent? Year...
-
Match the measures of worth in the first column with one (or more) of the analysis approaches that is (are) appropriate for that measure. Measure of Worth (a) Annual Worth (b) External Rate of Return...
-
For 2010, Sampsell Inc. computed its annual postretirement expense as $240,900. Sampsells contribution to the plan during 2010 was $180,000. Prepare Sampsells 2010 entry to record postretirement...
-
4. Consider the tables of values for the two functions shown. x y = f(x) -2 5 y = g(x) -2 -1 6 -1 0 8 1 1 7 0 2 9 2 Complete the table of values for the composite function y = f(g(x)). - x y =...
-
Cynthia Cooper is the accounting manager for a manufacturing company. One of her responsibilities at year-end is to determine how to account for the company's contingencies. She has proposed a...
-
What are some developmental and lifespan areas of interest that I should keep in mind when caring for a person with Diabetes mellitus?
-
A piping system has an assumed corrosion rate of 0.010 inch per year. An inspection shows an actual short term corrosion rate of 0.021 inch per year .The proper course of action would be to: A. Place...
-
In this task, you are required to use your organisation's digital system and program to gather and record the budget information for three different organisations / clients specified in the...
-
correct any mistake Hi Gents, I made some changes to the Operating Instruction RES-P-015. These modifications were implemented based on the recommendations provided by the Operating Committee. I have...
-
An investment dealer spread is: Multiple Choice commissions from buyers. fees from other investment dealers in the syndicate. artificially supporting the share price during and after the offering....
-
You are a CM / GC that has the capability to do your own concrete work.Your contract with the owner on a project allows you to do your own work on a lump sum basis, as long as you are the low bidder...
-
1. There are two countries, France and Belgium. There is one good, chocolate. The French supply of chocolate is given by P = Q + 5. The French demand for chocolate is given by P = 300 5Q. The...
-
In a paragraph of approximately 150-200 words, analyze a film or TV/Streaming Show poster of your choosing by focusing on the ways in which representations in the poster are gendered. Include an...
-
Solve the following stiff initial-value problem using the Runge-Kutta fourth-order method with (a) h = 0.1 and (b) h = 0.025. u'1 = 32u1 + 66u2 + 2/3 t + 2/3 , 0 t 0.5, u1(0) = 1/3; u'2 = 66u1 ...
-
The following statements are needed to prove Theorem 6.12. a. Show that if A1 exists, it is unique. b. Show that if A is nonsingular, then (A1)1 = A. c. Show that if A and B are nonsingular nn...
-
Let f be defined on [a, b], and let the nodes a = x0 < x1 < x2 = b be given. A quadratic spline interpolating function S consists of the quadratic polynomial S0(x) = a0 + b0(x x0) + c0(x x0)2 on...
-
The purchasing officer for The Majestic Emporium has prepared a purchases budget for the financial year ending 31 March 2020, based on the following data. The cost of sales is 65% of sales, and the...
-
Greyt Dog Beds Ltd manufactures dog beds specifically designed for greyhounds and whippets. The company purchases all the required materials from external suppliers and designs and assembles the...
-
Ketton Ltd is in the process of preparing direct labour and factory overhead budgets for the year ending 30 June 2020. Relevant data are set out below. Required (a) Prepare the direct labour budget...
Study smarter with the SolutionInn App