Skip to content
This repository has been archived by the owner on May 16, 2023. It is now read-only.

Commit

Permalink
asd (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
cosmincatalin committed Sep 29, 2022
1 parent 80480cf commit ab109aa
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 21 deletions.
4 changes: 2 additions & 2 deletions Finance/.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
<metadata>
<id>CosminSanda.Finance</id>
<version>1.0.1</version>
<version>1.0.2</version>
<title>Yahoo Earnings Calendar</title>
<authors>Cosmin Catalin Sanda</authors>
<owners>cosmincatalin</owners>
Expand All @@ -15,7 +15,7 @@
<tags>finance scraper</tags>
<dependencies>
<group>
<dependency id="CsvHelper" version="28.0.1" />
<dependency id="CsvHelper" version="28.0.0" />
<dependency id="Newtonsoft.Json" version="13.0.1" />
<dependency id="ServiceStack.Text" version="6.3.0" />
</group>
Expand Down
2 changes: 1 addition & 1 deletion Finance/Finance.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="CsvHelper" Version="28.0.1" />
<PackageReference Include="CsvHelper" Version="28.0.0" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
<PackageReference Include="ServiceStack.Text" Version="6.3.0" />
</ItemGroup>
Expand Down
29 changes: 11 additions & 18 deletions notebooks/demo.dib
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,11 @@

#r "nuget: CosminSanda.Finance"
#r "nuget: XPlot.Plotly.Interactive"
#r "nuget: CsvHelper"
#r "nuget: ServiceStack.Text"

#!csharp

using XPlot.Plotly;
using CosminSanda.Finance;
using CosminSanda.Finance.Records;

#!csharp

Expand All @@ -29,18 +26,14 @@ var quotes = await Quotes.GetQuotesAround("TWTR", lastDate, 3);

#!csharp

var chart4 = Chart.Candlestick(quotes.Select(o => new Tuple<string, double, double, double, double>(
o.Date.ToDateTime(TimeOnly.Parse("10:00 PM")).ToString("yyyy-MM-dd"),
o.Open,
o.High,
o.Low,
o.Close
)));

chart4.WithLayout(new Layout.Layout{
title="OHLC"
});

#!csharp

chart4
Chart
.Candlestick(quotes.Select(o => new Tuple<string, double, double, double, double>(
o.Date.ToDateTime(TimeOnly.Parse("10:00 PM")).ToString("yyyy-MM-dd"),
o.Open,
o.High,
o.Low,
o.Close
)))
.WithLayout(new Layout.Layout{
title="OHLC"
})

0 comments on commit ab109aa

Please sign in to comment.