Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions pkg/model/quotation.go
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ func (datastore *DB) GetAssetPriceUSDCache(asset dia.Asset) (price float64, err
return
}

// GetSortedQuotations returns quotations for all assets in @assets, sorted by 24h volume
// GetSortedAssetQuotations returns quotations for all assets in @assets, sorted by 24h volume
// in descending order.
func (datastore *DB) GetSortedAssetQuotations(assets []dia.Asset) ([]AssetQuotation, error) {
var quotations []AssetQuotation
Expand Down Expand Up @@ -343,7 +343,7 @@ func (datastore *DB) GetOldestQuotation(asset dia.Asset) (quotation AssetQuotati
// HISTORICAL QUOTES
// ------------------------------------------------------------------------------

// SetHistoricalQuote stores a historical quote for an asset symbol at a specific time into postgres.
// SetHistoricalQuotation stores a historical quote for an asset symbol at a specific time into postgres.
func (rdb *RelDB) SetHistoricalQuotation(quotation AssetQuotation) error {
queryString := `
INSERT INTO %s (asset_id,price,quote_time,source)
Expand Down
2 changes: 1 addition & 1 deletion pkg/utils/statistics.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ func ComputeMedian(samples []float64) (median float64) {
return
}

// vwap returns the volume weighted average price for the slices @prices and @volumes.
// Vwap returns the volume weighted average price for the slices @prices and @volumes.
func Vwap(prices []float64, volumes []float64) (float64, error) {
//log.Info("prices, volumes: ", prices, volumes)
if len(prices) != len(volumes) {
Expand Down