Sven Günther
8b4cad9f19
Replaced the placeholder spec with a real unit test that instantiates PortfolioService, stubs dependencies, calls
getSummary, and asserts the returned summary fields (including annualizedDividendYield and computed totals). The new test
lives in apps/api/src/app/portfolio/portfolio.service.spec.ts.
2 weeks ago
Sven Günther
6b167a917e
Add calculation and display of annualized dividend yield based on dividends received in the last 12 months relative to the investment cost basis.
Implementation:
- Add annualizedDividendYield property to TimelinePosition, PortfolioSnapshot, and PortfolioSummary interfaces
- Calculate individual position yield based on last 12 months dividends / investment with currency effects
- Aggregate portfolio-wide yield in PortfolioSnapshot
- Extract and include yield in PortfolioSummary via PortfolioService
Tests:
- Add comprehensive tests with single position (MSFT)
- Add multi-position test (MSFT + IBM) to verify aggregation
- Add PortfolioService integration tests
- Add IBM mock data to CurrentRateService
- Update cash test to include new property
2 weeks ago
Thomas Kaul
fcc2ab1a48
Feature/change color assignment by annualized performance in treemap chart ( #3617 )
* Change color assignment to annualized performance
* Update changelog
2 years ago
Thomas Kaul
f2cb671c7f
Feature/optimize get porfolio details endpoint ( #3366 )
* Eliminate getPerformance() from getSummary() function
* Disable cache for getDetails()
* Add hint to portfolio summary
* Update changelog
2 years ago
Thomas Kaul
d7b579e3e8
Feature/refactor getAnnualizedPerformancePercent to portfolio calculator ( #3226 )
* Move getAnnualizedPerformancePercent() to portfolio calculator
2 years ago
Francisco Silva
8cd6c34ed8
Feature/introduce portfolio calculator factory ( #3214 )
* Introduce portfolio calculator factory
* Update changelog
2 years ago
Thomas Kaul
63a61fb492
Move portfolio calculator ( #3204 )
* Move portfolio calculator
2 years ago
Thomas Kaul
5788c6474e
Refactor portfolio calculator ( #3203 )
* Refactor portfolio calculator
* Consume Activity[]
* Change computeTransactionPoints() to private
* Eliminate getTransactionPoints()
* Update changelog
2 years ago
Thomas Kaul
a33f8d5bed
Upgrade @types/big.js to version 6.2.2 ( #3191 )
* Upgrade @types/big.js to version 6.2.2
* Refactor imports
2 years ago
Thomas Kaul
5596e5f03b
Feature/integrate wealth items into transaction point concept ( #3084 )
* Integrate (wealth) items into transaction point concept
* Update changelog
2 years ago
Thomas Kaul
67ae86763e
Handle premium data provider in getQuotes() ( #3020 )
* Handle premium data provider in getQuotes()
2 years ago
Thomas Kaul
e921ed7f52
Reorder imports ( #2988 )
2 years ago
gizmodus
be801b481e
Feature/Add exchange rate effects to portfolio calculation ( #2834 )
* Add exchange rate effects to portfolio calculation
* Update changelog
---------
Co-authored-by: Thomas Kaul <4159106+dtslvr@users.noreply.github.com>
2 years ago
Thomas Kaul
67f2b326f3
Switch to new calculation engine ( #814 )
* Switch to new calculation engine
* Clean up old portfolio calculation engine (#815 )
* Rename new portfolio calculation engine (#816 )
* Update changelog
4 years ago
Thomas Kaul
7df53896f3
Feature/start eliminating data source from order ( #622 )
* Start eliminating dataSource from order
* Update changelog
4 years ago
Thomas Kaul
07de8f87fc
Set market prices explicitly ( #618 )
* Set market prices explicitly
* Set comments explicitly
4 years ago
Thomas Kaul
3b9a8fabb5
Clean up ( #574 )
4 years ago
Valentin Zickner
5d39b267ab
write portfolio calculator test case for symbol BALN.SW (refs #554 ) ( #572 )
4 years ago
Thomas Kaul
e78755c280
Replace OrderType with Type (prisma) ( #560 )
4 years ago
Thomas Kaul
1c2ca5b96b
Feature/accentuate all time high and low ( #428 )
* Accentuate all time high and all time low
* Update changelog
Co-authored-by: Valentin Zickner <ghostfolio@zickner.ch>
4 years ago
Thomas Kaul
dcee651098
Feature/support unlimited currencies ( #387 )
* Support unlimited currencies
* Update changelog
4 years ago
Thomas Kaul
0f72673ef4
Feature/respect data source in symbol data endpoint ( #370 )
* Respect data source in symbol data endpoint
* Respect data source in the data provider service
* Combine symbol with data source in get() of data provider service
* Improve search functionality for multiple data sources
* Update changelog
4 years ago
Valentin Zickner
d2aeeb3e88
optimize annual performance calculation ( #367 )
* Optimize annual performance calculation
* Update changelog
Co-authored-by: Valentin Zickner <github@zickner.ch>
Co-authored-by: Thomas <4159106+dtslvr@users.noreply.github.com>
4 years ago
Valentin Zickner
48ab862bb6
net performance for current positions ( #330 )
* implement fees for transaction points #324
* add net performance to current positions #324
* add net performance to calculate timeline #324
* make timeline fee accumulated by default #324
* Update changelog
Co-authored-by: Valentin Zickner <github@zickner.ch>
Co-authored-by: Thomas <4159106+dtslvr@users.noreply.github.com>
4 years ago
Valentin Zickner
308b218487
introduce basic module structure for data provider ( #278 )
* introduce basic module structure for data provider
* introduce DataGatheringModule
* introduce ExchangeRateDataModule
* introduce ImpersonationModule
* move RulesService
* cleanup portfolio module
* Sort imports
Co-authored-by: Valentin Zickner <github@zickner.ch>
Co-authored-by: Thomas <4159106+dtslvr@users.noreply.github.com>
5 years ago
Valentin Zickner
dfcf826b4f
implement support for buy-sell(-buy) scenario ( #262 )
Co-authored-by: Valentin Zickner <github@zickner.ch>
5 years ago
Thomas
4bd41ffa41
Feature/eliminate name from timeline position ( #245 )
* Eliminate name from timeline position: Get the name from the symbolProfileService instead
* Update changelog
5 years ago
Valentin Zickner
4bbd17a37a
fix tests
5 years ago
Valentin Zickner
d23addb673
change getDetails to portfolio-calculator.ts
Co-authored-by: Thomas <dotsilver@gmail.com>
5 years ago
Thomas
fb15cebb64
Add test ( #237 )
* Add test
* fix calculation for overall gross performance percentage
Co-authored-by: Valentin Zickner <github@zickner.ch>
5 years ago
Valentin Zickner
9c51a257ae
fix performance of combination of investments
5 years ago
Thomas
9821b7f8f0
Add TWR test scenario 1 ( #236 )
* Add TWR test scenario 1
* fix second transaction item
* change time-weighted rate algorithm
Co-authored-by: Valentin Zickner <valentin.zickner@flowable.com>
5 years ago
Thomas
cbdb68e2f8
Refactoring
5 years ago
Thomas
e7ef1d426e
Refactoring
5 years ago
Thomas
39cba0a8eb
Refactoring
5 years ago
Thomas
a90c314e30
Refactoring
5 years ago
Thomas
5e9cecc6c1
Refactoring
5 years ago
Thomas
cbb81916ee
Sort imports
5 years ago
Valentin Zickner
ea66081073
move interfaces to separate files
5 years ago
Thomas
e522722aa6
Update comment
5 years ago
Valentin Zickner
03ca5d7663
add further tests for portfolio-calculator with one transaction
5 years ago
Valentin Zickner
136563c949
fix single buy test
5 years ago
Thomas
948c45c602
Update test
5 years ago
Thomas
e0be792e46
Re-enable all tests
5 years ago
Thomas
c3d010135f
Add test for single buy
5 years ago
Valentin Zickner
34c13c80ec
add error handling for current positions
5 years ago
Valentin Zickner
f65a108436
change hardcoded timestamp in test to timezone specific
5 years ago
Valentin Zickner
852902d1ab
add current position calculation with holding period return calculation
5 years ago
Thomas
ee89822bfe
Fix tests
5 years ago
Thomas
e2c23703dc
Fix tests
5 years ago