mirror of
https://github.com/bitcoinresearchkit/brk.git
synced 2026-05-24 08:44:46 -07:00
global: added datasets
This commit is contained in:
@@ -31,10 +31,9 @@ In other words it's an alternative to [Glassnode](https://glassnode.com), [mempo
|
||||
|
||||
The toolkit can be used in various ways to accommodate as many needs as possible:
|
||||
|
||||
- **[Website](https://bitcoinresearchkit.org)** \
|
||||
- **[Website](https://bitview.space)** \
|
||||
Everyone is welcome to visit the official instance and showcase of the suite's capabilities. \
|
||||
It has a wide range of functionalities including charts, tables and simulations which you can visit for free and without the need for an account. \
|
||||
Also available at: [brekit.org](https://brekit.org) // [kibo.money](https://kibo.money) // [satonomics.xyz](https://satonomics.xyz)
|
||||
It has a wide range of functionalities including charts, tables and simulations which you can visit for free and without the need for an account.
|
||||
- **[API](https://github.com/bitcoinresearchkit/brk/tree/main/crates/brk_server#brk-server)** \
|
||||
Researchers and developers are free to use BRK's public API with  dataset variants at their disposal. \
|
||||
Just like the website, it's entirely free, with no authentication or rate-limiting.
|
||||
@@ -62,7 +61,7 @@ If you'd like to have your own instance hosted for you please contact [hosting@b
|
||||
- Updates delivered at your convenience
|
||||
- Direct communication for feature requests and support
|
||||
- Bitcoin Core or Knots with desired version
|
||||
- Optional subdomains: `*.bitcoinresearchkit.org`, `*.brekit.org`, `*.kibo.money` and `*.satonomics.xyz`
|
||||
- Optional subdomains
|
||||
- Logo featured in the Readme if desired
|
||||
|
||||
Pricing: `0.01 BTC / month` *or* `0.1 BTC / year`
|
||||
|
||||
@@ -78,15 +78,25 @@ impl Vecs {
|
||||
Source::None,
|
||||
version + VERSION + Version::ZERO,
|
||||
indexes,
|
||||
VecBuilderOptions::default().add_sum().add_cumulative(),
|
||||
VecBuilderOptions::default()
|
||||
.add_sum()
|
||||
.add_minmax()
|
||||
.add_average()
|
||||
.add_percentiles()
|
||||
.add_cumulative(),
|
||||
)?,
|
||||
indexes_to_block_size: ComputedVecsFromHeight::forced_import(
|
||||
&db,
|
||||
"block_size",
|
||||
Source::None,
|
||||
Source::Compute,
|
||||
version + VERSION + Version::ZERO,
|
||||
indexes,
|
||||
VecBuilderOptions::default().add_sum().add_cumulative(),
|
||||
VecBuilderOptions::default()
|
||||
.add_sum()
|
||||
.add_minmax()
|
||||
.add_average()
|
||||
.add_percentiles()
|
||||
.add_cumulative(),
|
||||
)?,
|
||||
height_to_vbytes: EagerVec::forced_import_compressed(
|
||||
&db,
|
||||
@@ -99,7 +109,12 @@ impl Vecs {
|
||||
Source::None,
|
||||
version + VERSION + Version::ZERO,
|
||||
indexes,
|
||||
VecBuilderOptions::default().add_sum().add_cumulative(),
|
||||
VecBuilderOptions::default()
|
||||
.add_sum()
|
||||
.add_minmax()
|
||||
.add_average()
|
||||
.add_percentiles()
|
||||
.add_cumulative(),
|
||||
)?,
|
||||
difficultyepoch_to_timestamp: EagerVec::forced_import_compressed(
|
||||
&db,
|
||||
|
||||
@@ -79,8 +79,8 @@ impl Vecs {
|
||||
version,
|
||||
indexes,
|
||||
price,
|
||||
compute_relative_to_all,
|
||||
false,
|
||||
compute_relative_to_all,
|
||||
false,
|
||||
)?,
|
||||
})
|
||||
|
||||
@@ -52,12 +52,16 @@ pub struct Vecs {
|
||||
pub indexes_to_coindays_destroyed: ComputedVecsFromHeight<StoredF64>,
|
||||
pub dateindex_to_spent_output_profit_ratio: Option<EagerVec<DateIndex, StoredF32>>,
|
||||
pub dateindex_to_spent_output_profit_ratio_7d_ema: Option<EagerVec<DateIndex, StoredF32>>,
|
||||
pub dateindex_to_spent_output_profit_ratio_30d_ema: Option<EagerVec<DateIndex, StoredF32>>,
|
||||
pub dateindex_to_adjusted_spent_output_profit_ratio: Option<EagerVec<DateIndex, StoredF32>>,
|
||||
pub dateindex_to_adjusted_spent_output_profit_ratio_7d_ema:
|
||||
Option<EagerVec<DateIndex, StoredF32>>,
|
||||
pub dateindex_to_adjusted_spent_output_profit_ratio_30d_ema:
|
||||
Option<EagerVec<DateIndex, StoredF32>>,
|
||||
pub indexes_to_realized_cap_30d_change: Option<ComputedVecsFromDateIndex<Dollars>>,
|
||||
pub dateindex_to_sell_side_risk_ratio: Option<EagerVec<DateIndex, StoredF32>>,
|
||||
pub dateindex_to_sell_side_risk_ratio_7d_ema: Option<EagerVec<DateIndex, StoredF32>>,
|
||||
pub dateindex_to_sell_side_risk_ratio_30d_ema: Option<EagerVec<DateIndex, StoredF32>>,
|
||||
pub indexes_to_adjusted_value_created: Option<ComputedVecsFromHeight<Dollars>>,
|
||||
pub indexes_to_adjusted_value_destroyed: Option<ComputedVecsFromHeight<Dollars>>,
|
||||
pub indexes_to_negative_realized_loss: Option<ComputedVecsFromHeight<Dollars>>,
|
||||
@@ -83,8 +87,18 @@ pub struct Vecs {
|
||||
pub indexes_to_negative_unrealized_loss: Option<ComputedVecsFromDateIndex<Dollars>>,
|
||||
pub height_to_net_unrealized_profit_and_loss: Option<EagerVec<Height, Dollars>>,
|
||||
pub indexes_to_net_unrealized_profit_and_loss: Option<ComputedVecsFromDateIndex<Dollars>>,
|
||||
pub height_to_unrealized_profit_relative_to_market_cap: Option<EagerVec<Height, StoredF32>>,
|
||||
pub height_to_unrealized_loss_relative_to_market_cap: Option<EagerVec<Height, StoredF32>>,
|
||||
pub height_to_negative_unrealized_loss_relative_to_market_cap:
|
||||
Option<EagerVec<Height, StoredF32>>,
|
||||
pub height_to_net_unrealized_profit_and_loss_relative_to_market_cap:
|
||||
Option<EagerVec<Height, StoredF32>>,
|
||||
pub indexes_to_unrealized_profit_relative_to_market_cap:
|
||||
Option<ComputedVecsFromDateIndex<StoredF32>>,
|
||||
pub indexes_to_unrealized_loss_relative_to_market_cap:
|
||||
Option<ComputedVecsFromDateIndex<StoredF32>>,
|
||||
pub indexes_to_negative_unrealized_loss_relative_to_market_cap:
|
||||
Option<ComputedVecsFromDateIndex<StoredF32>>,
|
||||
pub indexes_to_net_unrealized_profit_and_loss_relative_to_market_cap:
|
||||
Option<ComputedVecsFromDateIndex<StoredF32>>,
|
||||
pub indexes_to_realized_profit_relative_to_realized_cap:
|
||||
@@ -136,8 +150,8 @@ impl Vecs {
|
||||
version: Version,
|
||||
indexes: &indexes::Vecs,
|
||||
price: Option<&price::Vecs>,
|
||||
extended: bool,
|
||||
compute_relative_to_all: bool,
|
||||
ratio_extended: bool,
|
||||
compute_adjusted: bool,
|
||||
) -> Result<Self> {
|
||||
let compute_dollars = price.is_some();
|
||||
@@ -420,7 +434,7 @@ impl Vecs {
|
||||
Source::None,
|
||||
version + VERSION + Version::ZERO,
|
||||
indexes,
|
||||
ratio_extended,
|
||||
extended,
|
||||
)
|
||||
.unwrap()
|
||||
}),
|
||||
@@ -612,6 +626,15 @@ impl Vecs {
|
||||
)
|
||||
.unwrap()
|
||||
}),
|
||||
dateindex_to_sell_side_risk_ratio_30d_ema: compute_dollars.then(|| {
|
||||
EagerVec::forced_import(
|
||||
db,
|
||||
&suffix("sell_side_risk_ratio_30d_ema"),
|
||||
version + VERSION + Version::ONE,
|
||||
format,
|
||||
)
|
||||
.unwrap()
|
||||
}),
|
||||
dateindex_to_spent_output_profit_ratio: compute_dollars.then(|| {
|
||||
EagerVec::forced_import(
|
||||
db,
|
||||
@@ -630,6 +653,15 @@ impl Vecs {
|
||||
)
|
||||
.unwrap()
|
||||
}),
|
||||
dateindex_to_spent_output_profit_ratio_30d_ema: compute_dollars.then(|| {
|
||||
EagerVec::forced_import(
|
||||
db,
|
||||
&suffix("spent_output_profit_ratio_30d_ema"),
|
||||
version + VERSION + Version::ZERO,
|
||||
format,
|
||||
)
|
||||
.unwrap()
|
||||
}),
|
||||
dateindex_to_adjusted_spent_output_profit_ratio: (compute_dollars && compute_adjusted).then(|| {
|
||||
EagerVec::forced_import(
|
||||
db,
|
||||
@@ -648,6 +680,15 @@ impl Vecs {
|
||||
)
|
||||
.unwrap()
|
||||
}),
|
||||
dateindex_to_adjusted_spent_output_profit_ratio_30d_ema: (compute_dollars && compute_adjusted).then(|| {
|
||||
EagerVec::forced_import(
|
||||
db,
|
||||
&suffix("adjusted_spent_output_profit_ratio_30d_ema"),
|
||||
version + VERSION + Version::ZERO,
|
||||
format,
|
||||
)
|
||||
.unwrap()
|
||||
}),
|
||||
height_to_halved_supply_value: ComputedHeightValueVecs::forced_import(
|
||||
db,
|
||||
&suffix("halved_supply"),
|
||||
@@ -705,6 +746,39 @@ impl Vecs {
|
||||
)
|
||||
.unwrap()
|
||||
}),
|
||||
height_to_unrealized_profit_relative_to_market_cap: compute_dollars.then(
|
||||
|| {
|
||||
EagerVec::forced_import(
|
||||
db,
|
||||
&suffix("unrealized_profit_relative_to_market_cap"),
|
||||
version + VERSION + Version::ZERO,
|
||||
format,
|
||||
)
|
||||
.unwrap()
|
||||
},
|
||||
),
|
||||
height_to_unrealized_loss_relative_to_market_cap: compute_dollars.then(
|
||||
|| {
|
||||
EagerVec::forced_import(
|
||||
db,
|
||||
&suffix("unrealized_loss_relative_to_market_cap"),
|
||||
version + VERSION + Version::ZERO,
|
||||
format,
|
||||
)
|
||||
.unwrap()
|
||||
},
|
||||
),
|
||||
height_to_negative_unrealized_loss_relative_to_market_cap: compute_dollars.then(
|
||||
|| {
|
||||
EagerVec::forced_import(
|
||||
db,
|
||||
&suffix("negative_unrealized_loss_relative_to_market_cap"),
|
||||
version + VERSION + Version::ZERO,
|
||||
format,
|
||||
)
|
||||
.unwrap()
|
||||
},
|
||||
),
|
||||
height_to_net_unrealized_profit_and_loss_relative_to_market_cap: compute_dollars.then(
|
||||
|| {
|
||||
EagerVec::forced_import(
|
||||
@@ -716,6 +790,45 @@ impl Vecs {
|
||||
.unwrap()
|
||||
},
|
||||
),
|
||||
indexes_to_unrealized_profit_relative_to_market_cap: compute_dollars.then(
|
||||
|| {
|
||||
ComputedVecsFromDateIndex::forced_import(
|
||||
db,
|
||||
&suffix("unrealized_profit_relative_to_market_cap"),
|
||||
Source::Compute,
|
||||
version + VERSION + Version::ONE,
|
||||
indexes,
|
||||
VecBuilderOptions::default().add_last(),
|
||||
)
|
||||
.unwrap()
|
||||
},
|
||||
),
|
||||
indexes_to_unrealized_loss_relative_to_market_cap: compute_dollars.then(
|
||||
|| {
|
||||
ComputedVecsFromDateIndex::forced_import(
|
||||
db,
|
||||
&suffix("unrealized_loss_relative_to_market_cap"),
|
||||
Source::Compute,
|
||||
version + VERSION + Version::ONE,
|
||||
indexes,
|
||||
VecBuilderOptions::default().add_last(),
|
||||
)
|
||||
.unwrap()
|
||||
},
|
||||
),
|
||||
indexes_to_negative_unrealized_loss_relative_to_market_cap: compute_dollars.then(
|
||||
|| {
|
||||
ComputedVecsFromDateIndex::forced_import(
|
||||
db,
|
||||
&suffix("negative_unrealized_loss_relative_to_market_cap"),
|
||||
Source::Compute,
|
||||
version + VERSION + Version::ONE,
|
||||
indexes,
|
||||
VecBuilderOptions::default().add_last(),
|
||||
)
|
||||
.unwrap()
|
||||
},
|
||||
),
|
||||
indexes_to_net_unrealized_profit_and_loss_relative_to_market_cap: compute_dollars.then(
|
||||
|| {
|
||||
ComputedVecsFromDateIndex::forced_import(
|
||||
@@ -2220,6 +2333,18 @@ impl Vecs {
|
||||
exit,
|
||||
)?;
|
||||
|
||||
self.dateindex_to_spent_output_profit_ratio_30d_ema
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
.compute_ema(
|
||||
starting_indexes.dateindex,
|
||||
self.dateindex_to_spent_output_profit_ratio
|
||||
.as_ref()
|
||||
.unwrap(),
|
||||
30,
|
||||
exit,
|
||||
)?;
|
||||
|
||||
self.dateindex_to_sell_side_risk_ratio
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
@@ -2248,6 +2373,16 @@ impl Vecs {
|
||||
exit,
|
||||
)?;
|
||||
|
||||
self.dateindex_to_sell_side_risk_ratio_30d_ema
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
.compute_ema(
|
||||
starting_indexes.dateindex,
|
||||
self.dateindex_to_sell_side_risk_ratio.as_ref().unwrap(),
|
||||
30,
|
||||
exit,
|
||||
)?;
|
||||
|
||||
self.indexes_to_supply_in_profit
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
@@ -2369,6 +2504,33 @@ impl Vecs {
|
||||
Ok(())
|
||||
},
|
||||
)?;
|
||||
self.height_to_unrealized_profit_relative_to_market_cap
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
.compute_percentage(
|
||||
starting_indexes.height,
|
||||
self.height_to_unrealized_profit.as_ref().unwrap(),
|
||||
&market.height_to_marketcap,
|
||||
exit,
|
||||
)?;
|
||||
self.height_to_unrealized_loss_relative_to_market_cap
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
.compute_percentage(
|
||||
starting_indexes.height,
|
||||
self.height_to_unrealized_loss.as_ref().unwrap(),
|
||||
&market.height_to_marketcap,
|
||||
exit,
|
||||
)?;
|
||||
self.height_to_negative_unrealized_loss_relative_to_market_cap
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
.compute_percentage(
|
||||
starting_indexes.height,
|
||||
self.height_to_negative_unrealized_loss.as_ref().unwrap(),
|
||||
&market.height_to_marketcap,
|
||||
exit,
|
||||
)?;
|
||||
self.height_to_net_unrealized_profit_and_loss_relative_to_market_cap
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
@@ -2380,6 +2542,65 @@ impl Vecs {
|
||||
&market.height_to_marketcap,
|
||||
exit,
|
||||
)?;
|
||||
self.indexes_to_unrealized_profit_relative_to_market_cap
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
.compute_all(
|
||||
indexer,
|
||||
indexes,
|
||||
starting_indexes,
|
||||
exit,
|
||||
|vec, _, _, starting_indexes, exit| {
|
||||
vec.compute_percentage(
|
||||
starting_indexes.dateindex,
|
||||
self.dateindex_to_unrealized_profit.as_ref().unwrap(),
|
||||
market.indexes_to_marketcap.dateindex.as_ref().unwrap(),
|
||||
exit,
|
||||
)?;
|
||||
Ok(())
|
||||
},
|
||||
)?;
|
||||
self.indexes_to_unrealized_loss_relative_to_market_cap
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
.compute_all(
|
||||
indexer,
|
||||
indexes,
|
||||
starting_indexes,
|
||||
exit,
|
||||
|vec, _, _, starting_indexes, exit| {
|
||||
vec.compute_percentage(
|
||||
starting_indexes.dateindex,
|
||||
self.dateindex_to_unrealized_loss.as_ref().unwrap(),
|
||||
market.indexes_to_marketcap.dateindex.as_ref().unwrap(),
|
||||
exit,
|
||||
)?;
|
||||
Ok(())
|
||||
},
|
||||
)?;
|
||||
self.indexes_to_negative_unrealized_loss_relative_to_market_cap
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
.compute_all(
|
||||
indexer,
|
||||
indexes,
|
||||
starting_indexes,
|
||||
exit,
|
||||
|vec, _, _, starting_indexes, exit| {
|
||||
vec.compute_percentage(
|
||||
starting_indexes.dateindex,
|
||||
self.indexes_to_negative_unrealized_loss
|
||||
.as_ref()
|
||||
.unwrap()
|
||||
.dateindex
|
||||
.as_ref()
|
||||
.unwrap(),
|
||||
market.indexes_to_marketcap.dateindex.as_ref().unwrap(),
|
||||
exit,
|
||||
)?;
|
||||
Ok(())
|
||||
},
|
||||
)?;
|
||||
self.indexes_to_net_unrealized_profit_and_loss_relative_to_market_cap
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
@@ -2822,6 +3043,18 @@ impl Vecs {
|
||||
7,
|
||||
exit,
|
||||
)?;
|
||||
|
||||
self.dateindex_to_adjusted_spent_output_profit_ratio_30d_ema
|
||||
.as_mut()
|
||||
.unwrap()
|
||||
.compute_ema(
|
||||
starting_indexes.dateindex,
|
||||
self.dateindex_to_adjusted_spent_output_profit_ratio
|
||||
.as_ref()
|
||||
.unwrap(),
|
||||
30,
|
||||
exit,
|
||||
)?;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2891,12 +3124,18 @@ impl Vecs {
|
||||
self.dateindex_to_spent_output_profit_ratio_7d_ema
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v as &dyn AnyCollectableVec]),
|
||||
self.dateindex_to_spent_output_profit_ratio_30d_ema
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v as &dyn AnyCollectableVec]),
|
||||
self.dateindex_to_adjusted_spent_output_profit_ratio
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v as &dyn AnyCollectableVec]),
|
||||
self.dateindex_to_adjusted_spent_output_profit_ratio_7d_ema
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v as &dyn AnyCollectableVec]),
|
||||
self.dateindex_to_adjusted_spent_output_profit_ratio_30d_ema
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v as &dyn AnyCollectableVec]),
|
||||
self.indexes_to_value_destroyed
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| v.vecs()),
|
||||
@@ -2918,6 +3157,9 @@ impl Vecs {
|
||||
self.dateindex_to_sell_side_risk_ratio_7d_ema
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v]),
|
||||
self.dateindex_to_sell_side_risk_ratio_30d_ema
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v]),
|
||||
self.height_to_supply_in_profit
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v]),
|
||||
@@ -2988,9 +3230,27 @@ impl Vecs {
|
||||
self.indexes_to_net_unrealized_profit_and_loss
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| v.vecs()),
|
||||
self.height_to_unrealized_profit_relative_to_market_cap
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v]),
|
||||
self.height_to_unrealized_loss_relative_to_market_cap
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v]),
|
||||
self.height_to_negative_unrealized_loss_relative_to_market_cap
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v]),
|
||||
self.height_to_net_unrealized_profit_and_loss_relative_to_market_cap
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| vec![v]),
|
||||
self.indexes_to_unrealized_profit_relative_to_market_cap
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| v.vecs()),
|
||||
self.indexes_to_unrealized_loss_relative_to_market_cap
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| v.vecs()),
|
||||
self.indexes_to_negative_unrealized_loss_relative_to_market_cap
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| v.vecs()),
|
||||
self.indexes_to_net_unrealized_profit_and_loss_relative_to_market_cap
|
||||
.as_ref()
|
||||
.map_or(vec![], |v| v.vecs()),
|
||||
|
||||
@@ -32,8 +32,8 @@ impl Vecs {
|
||||
indexes: &indexes::Vecs,
|
||||
price: Option<&price::Vecs>,
|
||||
states_path: Option<&Path>,
|
||||
extended: bool,
|
||||
compute_relative_to_all: bool,
|
||||
ratio_extended: bool,
|
||||
compute_adjusted: bool,
|
||||
) -> Result<Self> {
|
||||
let compute_dollars = price.is_some();
|
||||
@@ -56,8 +56,8 @@ impl Vecs {
|
||||
version,
|
||||
indexes,
|
||||
price,
|
||||
extended,
|
||||
compute_relative_to_all,
|
||||
ratio_extended,
|
||||
compute_adjusted,
|
||||
)?,
|
||||
})
|
||||
|
||||
@@ -42,8 +42,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
)?,
|
||||
term: ByTerm {
|
||||
@@ -143,8 +143,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
p2pk33: utxo_cohort::Vecs::forced_import(
|
||||
@@ -155,8 +155,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
p2pkh: utxo_cohort::Vecs::forced_import(
|
||||
@@ -167,8 +167,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
p2sh: utxo_cohort::Vecs::forced_import(
|
||||
@@ -179,8 +179,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
p2wpkh: utxo_cohort::Vecs::forced_import(
|
||||
@@ -191,8 +191,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
p2wsh: utxo_cohort::Vecs::forced_import(
|
||||
@@ -203,8 +203,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
p2tr: utxo_cohort::Vecs::forced_import(
|
||||
@@ -215,8 +215,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
p2a: utxo_cohort::Vecs::forced_import(
|
||||
@@ -227,8 +227,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
p2ms: utxo_cohort::Vecs::forced_import(
|
||||
@@ -239,8 +239,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
empty: utxo_cohort::Vecs::forced_import(
|
||||
@@ -251,8 +251,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
unknown: utxo_cohort::Vecs::forced_import(
|
||||
@@ -263,8 +263,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
},
|
||||
@@ -955,8 +955,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1sat_to_10sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -967,8 +967,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10sats_to_100sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -979,8 +979,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100sats_to_1k_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -991,8 +991,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1k_sats_to_10k_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1003,8 +1003,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10k_sats_to_100k_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1015,8 +1015,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100k_sats_to_1m_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1027,8 +1027,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1m_sats_to_10m_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1039,8 +1039,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10m_sats_to_1btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1051,8 +1051,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1btc_to_10btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1063,8 +1063,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10btc_to_100btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1075,8 +1075,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100btc_to_1k_btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1087,8 +1087,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1k_btc_to_10k_btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1099,8 +1099,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10k_btc_to_100k_btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1111,8 +1111,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100k_btc_or_more: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1123,8 +1123,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
Some(states_path),
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
},
|
||||
@@ -1137,8 +1137,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1149,8 +1149,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1k_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1161,8 +1161,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10k_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1173,8 +1173,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100k_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1185,8 +1185,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1m_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1197,8 +1197,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10m_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1209,8 +1209,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1221,8 +1221,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1233,8 +1233,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1245,8 +1245,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1k_btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1257,8 +1257,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10k_btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1269,8 +1269,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100k_btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1281,8 +1281,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
},
|
||||
@@ -1295,8 +1295,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1307,8 +1307,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1319,8 +1319,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1k_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1331,8 +1331,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10k_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1343,8 +1343,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100k_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1355,8 +1355,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1m_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1367,8 +1367,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10m_sats: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1379,8 +1379,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1391,8 +1391,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1403,8 +1403,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_100btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1415,8 +1415,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_1k_btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1427,8 +1427,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
_10k_btc: utxo_cohort::Vecs::forced_import(
|
||||
@@ -1439,8 +1439,8 @@ impl Vecs {
|
||||
indexes,
|
||||
price,
|
||||
None,
|
||||
true,
|
||||
false,
|
||||
true,
|
||||
false,
|
||||
)?,
|
||||
},
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="description" content="Bitcoin with X-ray vision" />
|
||||
<meta name="description" content="Bitcoin transparency, amplified" />
|
||||
<meta
|
||||
name="viewport"
|
||||
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"
|
||||
@@ -449,7 +449,7 @@
|
||||
text-transform: uppercase;
|
||||
font-size: var(--font-size-xl);
|
||||
line-height: var(--line-height-xl);
|
||||
font-weight: 325;
|
||||
font-weight: 350;
|
||||
}
|
||||
|
||||
h3 {
|
||||
@@ -1745,7 +1745,9 @@
|
||||
<div class="shadow-bottom"></div>
|
||||
<div id="resize-bar"></div>
|
||||
|
||||
<nav id="nav" hidden></nav>
|
||||
<nav id="nav" hidden>
|
||||
<!-- <h4>bitview</h4> -->
|
||||
</nav>
|
||||
|
||||
<search id="search" hidden>
|
||||
<header>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "Bitcoin Research Kit",
|
||||
"short_name": "₿RK",
|
||||
"description": "A better, FOSS, Bitcoin-only, self-hostable Glassnode",
|
||||
"name": "bitview",
|
||||
"short_name": "bitview",
|
||||
"description": "Bitcoin transparency, amplified",
|
||||
"categories": [
|
||||
"bitcoin",
|
||||
"on-chain",
|
||||
|
||||
@@ -113,13 +113,15 @@ export function init({
|
||||
chartBottomRightCanvas.replaceWith(screenshotButton);
|
||||
screenshotButton.addEventListener("click", () => {
|
||||
packages.modernScreenshot().then(async ({ screenshot }) => {
|
||||
elements.body.dataset.screenshot = "true";
|
||||
charts.dataset.screenshot = "true";
|
||||
charts.append(domain);
|
||||
seriesTypeField.hidden = true;
|
||||
try {
|
||||
await screenshot(charts);
|
||||
} catch {}
|
||||
charts.removeChild(domain);
|
||||
seriesTypeField.hidden = false;
|
||||
elements.body.dataset.screenshot = "false";
|
||||
charts.dataset.screenshot = "false";
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
@@ -24,7 +24,6 @@
|
||||
* "Gigabytes" |
|
||||
* "Hash" |
|
||||
* "Index" |
|
||||
* "mb" |
|
||||
* "percentage" |
|
||||
* "Ratio" |
|
||||
* "Sats" |
|
||||
@@ -854,7 +853,11 @@ function createUtils() {
|
||||
}
|
||||
if (
|
||||
(!unit || thoroughUnitCheck) &&
|
||||
(id === "txid" || (id.endsWith("bytes") && !id.endsWith("vbytes")))
|
||||
(id === "txid" ||
|
||||
(id.endsWith("bytes") && !id.endsWith("vbytes")) ||
|
||||
id.endsWith("base_size") ||
|
||||
id.endsWith("total_size") ||
|
||||
id.includes("block_size"))
|
||||
) {
|
||||
if (unit) throw Error(`Unit "${unit}" already assigned "${id}"`);
|
||||
unit = "Bytes";
|
||||
@@ -863,15 +866,6 @@ function createUtils() {
|
||||
if (unit) throw Error(`Unit "${unit}" already assigned "${id}"`);
|
||||
unit = "sd";
|
||||
}
|
||||
if (
|
||||
(!unit || thoroughUnitCheck) &&
|
||||
(id.endsWith("_size") ||
|
||||
id.endsWith("_size_sum") ||
|
||||
id.endsWith("_size_cumulative"))
|
||||
) {
|
||||
if (unit) throw Error(`Unit "${unit}" already assigned "${id}"`);
|
||||
unit = "mb";
|
||||
}
|
||||
if (
|
||||
(!unit || thoroughUnitCheck) &&
|
||||
(id.includes("vsize") || id.includes("vbytes"))
|
||||
|
||||
@@ -1183,7 +1183,7 @@ function createPartialOptions({ env, colors, vecIdToIndexes }) {
|
||||
*/
|
||||
function createSumSeries({ key, title = "", color }) {
|
||||
return /** @satisfies {AnyFetchedSeriesBlueprint} */ ({
|
||||
key,
|
||||
key: key in vecIdToIndexes ? key : `${key}_sum`,
|
||||
title: `Sum ${title}`,
|
||||
color: color ?? colors.orange,
|
||||
});
|
||||
@@ -1256,14 +1256,23 @@ function createPartialOptions({ env, colors, vecIdToIndexes }) {
|
||||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {VecIdAverageBase & CumulativeVecIdBase & VecIdMinBase & VecIdMaxBase & VecId90pBase & VecId75pBase & VecIdMedianBase & VecId25pBase & VecId10pBase} key
|
||||
*/
|
||||
function createSumCumulativeMinMaxPercentilesSeries(key) {
|
||||
return [
|
||||
...createSumCumulativeSeries({ concat: key }),
|
||||
...createMinMaxPercentilesSeries({ concat: key }),
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {VecIdAverageBase & CumulativeVecIdBase & VecIdMinBase & VecIdMaxBase & VecId90pBase & VecId75pBase & VecIdMedianBase & VecId25pBase & VecId10pBase} key
|
||||
*/
|
||||
function createAverageSumCumulativeMinMaxPercentilesSeries(key) {
|
||||
return [
|
||||
createAverageSeries({ concat: key }),
|
||||
...createSumCumulativeSeries({ concat: key }),
|
||||
...createMinMaxPercentilesSeries({ concat: key }),
|
||||
...createSumCumulativeMinMaxPercentilesSeries(key),
|
||||
];
|
||||
}
|
||||
|
||||
@@ -2279,6 +2288,22 @@ function createPartialOptions({ env, colors, vecIdToIndexes }) {
|
||||
},
|
||||
},
|
||||
}),
|
||||
...(asoprKey in vecIdToIndexes
|
||||
? [
|
||||
/** @satisfies {FetchedBaselineSeriesBlueprint} */ ({
|
||||
type: "Baseline",
|
||||
key: asoprKey,
|
||||
title: "adjusted",
|
||||
colors: [colors.yellow, colors.fuchsia],
|
||||
defaultActive: false,
|
||||
options: {
|
||||
baseValue: {
|
||||
price: 1,
|
||||
},
|
||||
},
|
||||
}),
|
||||
]
|
||||
: []),
|
||||
/** @satisfies {FetchedBaselineSeriesBlueprint} */ ({
|
||||
type: "Baseline",
|
||||
key: `${soprKey}_7d_ema`,
|
||||
@@ -2295,8 +2320,22 @@ function createPartialOptions({ env, colors, vecIdToIndexes }) {
|
||||
? [
|
||||
/** @satisfies {FetchedBaselineSeriesBlueprint} */ ({
|
||||
type: "Baseline",
|
||||
key: asoprKey,
|
||||
title: "adjusted",
|
||||
key: `${asoprKey}_7d_ema`,
|
||||
title: "adj. 7d ema",
|
||||
colors: [colors.amber, colors.purple],
|
||||
defaultActive: false,
|
||||
options: {
|
||||
baseValue: {
|
||||
price: 1,
|
||||
},
|
||||
},
|
||||
}),
|
||||
]
|
||||
: []),
|
||||
/** @satisfies {FetchedBaselineSeriesBlueprint} */ ({
|
||||
type: "Baseline",
|
||||
key: `${soprKey}_30d_ema`,
|
||||
title: "30d ema",
|
||||
colors: [colors.avocado, colors.pink],
|
||||
defaultActive: false,
|
||||
options: {
|
||||
@@ -2305,11 +2344,13 @@ function createPartialOptions({ env, colors, vecIdToIndexes }) {
|
||||
},
|
||||
},
|
||||
}),
|
||||
...(asoprKey in vecIdToIndexes
|
||||
? [
|
||||
/** @satisfies {FetchedBaselineSeriesBlueprint} */ ({
|
||||
type: "Baseline",
|
||||
key: `${asoprKey}_7d_ema`,
|
||||
title: "adj. 7d ema",
|
||||
colors: [colors.yellow, colors.fuchsia],
|
||||
key: `${asoprKey}_30d_ema`,
|
||||
title: "adj. 30d ema",
|
||||
colors: [colors.orange, colors.violet],
|
||||
defaultActive: false,
|
||||
options: {
|
||||
baseValue: {
|
||||
@@ -2577,6 +2618,12 @@ function createPartialOptions({ env, colors, vecIdToIndexes }) {
|
||||
color: colors.red,
|
||||
defaultActive: false,
|
||||
}),
|
||||
createBaseSeries({
|
||||
key: `${fixKey(key)}sell_side_risk_ratio_30d_ema`,
|
||||
name: "30d ema",
|
||||
color: colors.rose,
|
||||
defaultActive: false,
|
||||
}),
|
||||
])
|
||||
: list.flatMap(({ color, name, key }) => [
|
||||
createBaseSeries({
|
||||
@@ -2613,10 +2660,30 @@ function createPartialOptions({ env, colors, vecIdToIndexes }) {
|
||||
name: "Negative Loss",
|
||||
color: colors.red,
|
||||
}),
|
||||
createBaseSeries({
|
||||
key: `${fixKey(args.key)}unrealized_profit_relative_to_market_cap`,
|
||||
name: "Profit",
|
||||
color: colors.green,
|
||||
}),
|
||||
createBaseSeries({
|
||||
key: `${fixKey(args.key)}unrealized_loss_relative_to_market_cap`,
|
||||
name: "Loss",
|
||||
color: colors.red,
|
||||
defaultActive: false,
|
||||
}),
|
||||
createBaseSeries({
|
||||
key: `${fixKey(args.key)}negative_unrealized_loss_relative_to_market_cap`,
|
||||
name: "Negative Loss",
|
||||
color: colors.red,
|
||||
}),
|
||||
createPriceLine({
|
||||
unit: "USD",
|
||||
defaultActive: false,
|
||||
}),
|
||||
createPriceLine({
|
||||
unit: "%mcap",
|
||||
defaultActive: false,
|
||||
}),
|
||||
],
|
||||
},
|
||||
]
|
||||
@@ -3270,33 +3337,29 @@ function createPartialOptions({ env, colors, vecIdToIndexes }) {
|
||||
bottom: [
|
||||
createBaseSeries({
|
||||
key: "total_size",
|
||||
name: "Size",
|
||||
}),
|
||||
...createSumCumulativeSeries({
|
||||
concat: "block_size",
|
||||
}),
|
||||
],
|
||||
},
|
||||
{
|
||||
name: "Bytes",
|
||||
title: "Block Bytes",
|
||||
bottom: [
|
||||
createBaseSeries({
|
||||
key: "weight",
|
||||
name: "Weight",
|
||||
}),
|
||||
...createSumCumulativeSeries({
|
||||
concat: "block_weight",
|
||||
common: "weight",
|
||||
name: "raw",
|
||||
}),
|
||||
createBaseSeries({
|
||||
key: "vbytes",
|
||||
name: "Vbytes",
|
||||
name: "raw",
|
||||
}),
|
||||
...createSumCumulativeSeries({
|
||||
concat: "block_vbytes",
|
||||
common: "Vbytes",
|
||||
createBaseSeries({
|
||||
key: "weight",
|
||||
name: "raw",
|
||||
}),
|
||||
// createBaseSeries({
|
||||
// key: "weight",
|
||||
// name: "Weight",
|
||||
// }),
|
||||
...createAverageSumCumulativeMinMaxPercentilesSeries(
|
||||
"block_size",
|
||||
),
|
||||
...createAverageSumCumulativeMinMaxPercentilesSeries(
|
||||
"block_weight",
|
||||
),
|
||||
...createAverageSumCumulativeMinMaxPercentilesSeries(
|
||||
"block_vbytes",
|
||||
),
|
||||
],
|
||||
},
|
||||
],
|
||||
@@ -3313,8 +3376,8 @@ function createPartialOptions({ env, colors, vecIdToIndexes }) {
|
||||
}),
|
||||
},
|
||||
{
|
||||
name: "Bytes",
|
||||
title: "Transaction Bytes",
|
||||
name: "Size",
|
||||
title: "Transaction Size",
|
||||
bottom: [
|
||||
createAverageSeries({ concat: "tx_weight", title: "Weight" }),
|
||||
...createMinMaxPercentilesSeries({
|
||||
|
||||
Reference in New Issue
Block a user