Skip to content

Commit ea746dc

Browse files
committed
update stats
1 parent fe9d951 commit ea746dc

File tree

2 files changed

+22
-9
lines changed

2 files changed

+22
-9
lines changed

client/src/components/StatsTable.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ const StatsTable = ({ summaryStats, benchmarkStats, dataLabel, productId }) => {
3232
</Table.Row>
3333
<Table.Row>
3434
<Table.Cell>Annualized Volatility</Table.Cell>
35-
<Table.Cell>{numeral(benchmarkStats.annualizedReturn).format('0,0.0%')}</Table.Cell>
36-
<Table.Cell>{numeral(annualizedReturn).format('0,0.0%')}</Table.Cell>
35+
<Table.Cell>{numeral(benchmarkStats.annualizedVolatility).format('0,0.0%')}</Table.Cell>
36+
<Table.Cell>{numeral(annualizedVolatility).format('0,0.0%')}</Table.Cell>
3737
</Table.Row>
3838
<Table.Row>
3939
<Table.Cell>Sharpe Ratio</Table.Cell>

client/src/components/SummaryStats.js

Lines changed: 20 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -74,13 +74,26 @@ class SummaryStats extends Component {
7474
<Container>
7575
<Segment>
7676
<div className="ui action input">
77-
<ReactFileReader handleFiles={this.handleFiles} fileTypes={'.csv'}>
78-
<Input type="text" placeholder="Upload CSV File" disabled />
79-
<Input type="file" />
80-
</ReactFileReader>
81-
<Button icon>
82-
<Icon name="attach"/>
83-
</Button>
77+
<table>
78+
<tr>
79+
<td>
80+
<Button onClick={this.handleUpdateBenchmark} >
81+
Update Benchmark
82+
</Button>
83+
</td>
84+
<td>
85+
<ReactFileReader handleFiles={this.handleFiles} fileTypes={'.csv'}>
86+
<Input type="text" placeholder="Upload CSV File" disabled />
87+
<Input type="file" />
88+
</ReactFileReader>
89+
</td>
90+
<td>
91+
<Button icon>
92+
<Icon name="attach" />
93+
</Button>
94+
</td>
95+
</tr>
96+
</table>
8497
</div>
8598
<Divider hidden />
8699
<StatsTable

0 commit comments

Comments
 (0)