Difference between revisions of "Página de pruebas"

From Sinfronteras
Jump to: navigation, search
Line 1: Line 1:
==Assignment - Stock Market Simulator==
+
==Data analysis==
 +
Data analysis is the process of inspecting, cleansing, transforming, and modelling data with a goal of discovering useful information, suggesting conclusions, and supporting decision-making.
  
===Assignment Introduction===
 
You have been asked to design and implement a simulator of a simplified ''model of a stock market''.
 
  
The program is going  to simulate both companies  and investors, following the specific requirements described below.
+
'''Data mining''' is a particular data analysis technique that focuses on the modelling and knowledge discovery for predictive rather than purely descriptive purposes, while business intelligence covers data analysis that relies heavily on aggregation, focusing on business information.
  
When  the  simulation has been completed,  you  must  present  the  user a  menu  with a  list  of  possible reports for them to see the result.
 
  
===Specific Requirements===
+
In statistical applications, data analysis can be divided into:
* '''The system must create dynamically 100 companies. All of them must have:'''
+
* '''Descriptive statistics''',
:* A unique ID
+
* '''Exploratory data analysis (EDA)''', and  
:* A random number of shares (between 500 and 1000)
+
* '''Confirmatory data analysis (CDA)'''.
:* A random share price (between 10 and 100)
 
:* Any other attribute that you consider relevant to the context
 
  
  
* '''The system must create dynamically 100 investors. All of them must have:'''
+
In particular, data analysis typically includes '''data retrieval''' and '''data cleaning (pre-processing) stages'''.
:* A unique ID
 
:* Arandom budget between 1000 and 10000
 
:* Any other attribute that you consider relevant to the context
 
  
  
* '''Once all the companies have been created, the simulator should run a "trading day". This will run transactions were investors buy shares in the companies that exist, following the rules below:'''
+
'''Exploratory Data:''' In statistics, the exploratory data analysis (EDA) is an approach to analyzing data sets to summarize their main characteristics, often with visual methods.
:* If a company sells 10 shares, the share price should double up.
 
  
:* If any 10 shares are sold (from any company), and a company hasn't sold any, the price must reduce in half.
 
  
:* Investors can do as many transactions as they like, but must buy only one share per transaction. Investors must try to buy shares in as many possible companies to guarantee the safety of their investment.
+
'''Confirmatory Analysis:'''
 +
In statistics, confirmatory analysis (CA) or confirmatory factor analysis (CFA) is a special form of factor analysis, most commonly used in social research.  
  
:* The simulator should stop when all shares have been sold, or all investors have spent all their money.
 
  
 +
'''Empirical Research:'''
  
* '''You are required to present the user with a menu to display the result of the simulation, with the following options:'''
 
:* Company with the highest capital(number of shares times share price).
 
:* Company with the lowest capital (number of shares times share price).
 
:* If there are more than one company at the top or bottom position, they all should be displayed in the result.
 
:* Investor with the highest number of shares.
 
:* Investor that has invested in the most companies.
 
:* Investor with the lowest number of shares.
 
:* Investor that has invested in the least number of companies.
 
:* It there is more than one investor in any of the positions, they all should be displayed in the result.
 
  
 +
'''Statistical Significance:'''
  
* '''At least three design patterns must be implemented in your project.'''
 
  
===Extra marks===
 
If you would like to achieve a distinction consider adding some extra layers of functionality, such as, but not limited to:
 
* Implementing data persistency through a file or external database, or any other aspect that might be relevant to the context.
 
  
* Implementation of a multi threaded environment to simulate several investors trading at the same time.
+
'''Descriptive Data Analysis:'''
 +
* Rather than find hidden information in the data, descriptive data analysis looks to summarise the dataset.
 +
* They are commonly implemented measures included in the descriptive data analysis:
 +
** Central tendency (mean, mode, median)
 +
** Variability (standard deviation, min/max)
  
* Other reports such as total number of transactions.
 
  
===Informe===
+
'''Exploratory Data Analysis:'''
 +
* Generate Summaries and make general statements about the data, and its relationships within the data is the heart of Exploratory Data Analysis.
  
====Problemas encontrados====
+
* We generally make assumptions on the entire population but mostly just work with small samples. Why are we allowed to do this??? Two important definitions:
* Sincronizar los id entre la base de datos y los objetos creados en running time
+
** Population: A precise definition of all possible outcomes, measurements or values for which inference will be made about.
 +
** Sample: A portion of the population which is representative of the population (at least ideally).
 +
 
 +
 
 +
 
 +
Types of Variable: https://statistics.laerd.com/statistical-guides/types-of-variable.php
 +
 
 +
===Central tendency===
 +
https://statistics.laerd.com/statistical-guides/measures-central-tendency-mean-mode-median.php
 +
 
 +
A central tendency (or measure of central tendency) is a single value that attempts to describe a set of data by identifying the central position within that set of data.
 +
 
 +
'''The mean''' (often called the average) is most likely the measure of central tendency that you are most familiar with, but there are others, such as the median and the mode.
 +
 
 +
'''The mean, median and mode''' are all valid measures of central tendency, but under different conditions, some measures of central tendency become more appropriate to use than others. In the following sections, we will look at the mean, mode and median, and learn how to calculate them and under what conditions they are most appropriate to be used.
 +
 
 +
====Mean====
 +
Mean (Arithmetic)
 +
 
 +
The mean (or average) is the most popular and well known measure of central tendency.
 +
 
 +
The mean is equal to the sum of all the values in the data set divided by the number of values in the data set.
 +
 
 +
So, if we have <math>n</math> values in a data set and they have values x1, x2, ..., xn, the sample mean, usually denoted by (pronounced x bar), is:

Revision as of 22:44, 27 March 2019

Data analysis

Data analysis is the process of inspecting, cleansing, transforming, and modelling data with a goal of discovering useful information, suggesting conclusions, and supporting decision-making.


Data mining is a particular data analysis technique that focuses on the modelling and knowledge discovery for predictive rather than purely descriptive purposes, while business intelligence covers data analysis that relies heavily on aggregation, focusing on business information.


In statistical applications, data analysis can be divided into:

  • Descriptive statistics,
  • Exploratory data analysis (EDA), and
  • Confirmatory data analysis (CDA).


In particular, data analysis typically includes data retrieval and data cleaning (pre-processing) stages.


Exploratory Data: In statistics, the exploratory data analysis (EDA) is an approach to analyzing data sets to summarize their main characteristics, often with visual methods.


Confirmatory Analysis: In statistics, confirmatory analysis (CA) or confirmatory factor analysis (CFA) is a special form of factor analysis, most commonly used in social research.


Empirical Research:


Statistical Significance:


Descriptive Data Analysis:

  • Rather than find hidden information in the data, descriptive data analysis looks to summarise the dataset.
  • They are commonly implemented measures included in the descriptive data analysis:
    • Central tendency (mean, mode, median)
    • Variability (standard deviation, min/max)


Exploratory Data Analysis:

  • Generate Summaries and make general statements about the data, and its relationships within the data is the heart of Exploratory Data Analysis.
  • We generally make assumptions on the entire population but mostly just work with small samples. Why are we allowed to do this??? Two important definitions:
    • Population: A precise definition of all possible outcomes, measurements or values for which inference will be made about.
    • Sample: A portion of the population which is representative of the population (at least ideally).


Types of Variable: https://statistics.laerd.com/statistical-guides/types-of-variable.php

Central tendency

https://statistics.laerd.com/statistical-guides/measures-central-tendency-mean-mode-median.php

A central tendency (or measure of central tendency) is a single value that attempts to describe a set of data by identifying the central position within that set of data.

The mean (often called the average) is most likely the measure of central tendency that you are most familiar with, but there are others, such as the median and the mode.

The mean, median and mode are all valid measures of central tendency, but under different conditions, some measures of central tendency become more appropriate to use than others. In the following sections, we will look at the mean, mode and median, and learn how to calculate them and under what conditions they are most appropriate to be used.

Mean

Mean (Arithmetic)

The mean (or average) is the most popular and well known measure of central tendency.

The mean is equal to the sum of all the values in the data set divided by the number of values in the data set.

So, if we have values in a data set and they have values x1, x2, ..., xn, the sample mean, usually denoted by (pronounced x bar), is: