arviz.InferenceData.stack — ArviZ dev documentation (original) (raw)
InferenceData.stack(dimensions=None, groups=None, filter_groups=None, inplace=False, **kwargs)[source]#
Perform an xarray stacking on all groups.
Stack any number of existing dimensions into a single new dimension. Loops groups to perform Dataset.stack(key=value) for every kwarg if value is a dimension of the dataset. The selection is performed on all relevant groups (like posterior, prior, sample stats) while non relevant groups like observed data are omitted. See xarray.Dataset.stack()
Parameters:
dimensionsdict, optional
Names of new dimensions, and the existing dimensions that they replace.
groups: str or list of str, optional
Groups where the selection is to be applied. Can either be group names or metagroup names.
filter_groups{None, “like”, “regex”}, optional
If None
(default), interpret groups as the real group or metagroup names. If “like”, interpret groups as substrings of the real group or metagroup names. If “regex”, interpret groups as regular expressions on the real group or metagroup names. A la pandas.filter
.
inplacebool, optional
If True
, modify the InferenceData object inplace, otherwise, return the modified copy.
kwargsdict, optional
It must be accepted by xarray.Dataset.stack().
Returns:
A new InferenceData object by default. When inplace==True
perform selection in-place and return None
See also
Stack any number of existing dimensions into a single new dimension.
Perform an xarray unstacking on all groups of InferenceData object.
Examples
Use stack
to stack any number of existing dimensions into a single new dimension. We first check the original object:
import arviz as az idata = az.load_arviz_data("rugby") idata
- posterior
<xarray.Dataset> Size: 452kB
Dimensions: (chain: 4, draw: 500, team: 6)
Coordinates:- chain (chain) int64 32B 0 1 2 3
- draw (draw) int64 4kB 0 1 2 3 4 5 6 7 ... 493 494 495 496 497 498 499
- team (team) <U8 192B 'Wales' 'France' 'Ireland' ... 'Italy' 'England'
Data variables:
home (chain, draw) float64 16kB ...
intercept (chain, draw) float64 16kB ...
atts_star (chain, draw, team) float64 96kB ...
defs_star (chain, draw, team) float64 96kB ...
sd_att (chain, draw) float64 16kB ...
sd_def (chain, draw) float64 16kB ...
atts (chain, draw, team) float64 96kB ...
defs (chain, draw, team) float64 96kB ...
Attributes:
created_at: 2024-03-06T20:46:23.841916
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9
sampling_time: 8.503105401992798
tuning_steps: 1000- Dimensions:
* chain: 4
* draw: 500
* team: 6 - Coordinates: (3)
* chain
(chain)
int64
0 1 2 3
* draw
(draw)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(500,))
* team
(team)
<U8
'Wales' 'France' ... 'England'
array(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'],
dtype='<U8') - Data variables: (8)
* home
(chain, draw)
float64
...
[2000 values with dtype=float64]
* intercept
(chain, draw)
float64
...
[2000 values with dtype=float64]
* atts_star
(chain, draw, team)
float64
...
[12000 values with dtype=float64]
* defs_star
(chain, draw, team)
float64
...
[12000 values with dtype=float64]
* sd_att
(chain, draw)
float64
...
[2000 values with dtype=float64]
* sd_def
(chain, draw)
float64
...
[2000 values with dtype=float64]
* atts
(chain, draw, team)
float64
...
[12000 values with dtype=float64]
* defs
(chain, draw, team)
float64
...
[12000 values with dtype=float64] - Indexes: (3)
* PandasIndex
PandasIndex(Index([0, 1, 2, 3], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
...
490, 491, 492, 493, 494, 495, 496, 497, 498, 499],
dtype='int64', name='draw', length=500))
* PandasIndex
PandasIndex(Index(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'], dtype='object', name='team')) - Attributes: (6)
created_at :
2024-03-06T20:46:23.841916
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
sampling_time :
8.503105401992798
tuning_steps :
1000
- Dimensions:
- posterior_predictive
<xarray.Dataset> Size: 2MB
Dimensions: (chain: 4, draw: 500, match: 60)
Coordinates:- chain (chain) int64 32B 0 1 2 3
- draw (draw) int64 4kB 0 1 2 3 4 5 6 ... 493 494 495 496 497 498 499
- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
home_team (match) <U8 2kB ...
away_team (match) <U8 2kB ...
Data variables:
home_points (chain, draw, match) int64 960kB ...
away_points (chain, draw, match) int64 960kB ...
Attributes:
created_at: 2024-03-06T20:46:25.689246
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* chain: 4
* draw: 500
* match: 60 - Coordinates: (5)
* chain
(chain)
int64
0 1 2 3
* draw
(draw)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(500,))
* match
(match)
<U16
'Wales Italy' ... 'Ireland England'
array(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'], dtype='<U16')
* home_team
(match)
<U8
...
[60 values with dtype=<U8]
* away_team
(match)
<U8
...
[60 values with dtype=<U8] - Data variables: (2)
* home_points
(chain, draw, match)
int64
...
[120000 values with dtype=int64]
* away_points
(chain, draw, match)
int64
...
[120000 values with dtype=int64] - Indexes: (3)
* PandasIndex
PandasIndex(Index([0, 1, 2, 3], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
...
490, 491, 492, 493, 494, 495, 496, 497, 498, 499],
dtype='int64', name='draw', length=500))
* PandasIndex
PandasIndex(Index(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'],
dtype='object', name='match')) - Attributes: (4)
created_at :
2024-03-06T20:46:25.689246
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- log_likelihood
<xarray.Dataset> Size: 2MB
Dimensions: (chain: 4, draw: 500, match: 60)
Coordinates:- chain (chain) int64 32B 0 1 2 3
- draw (draw) int64 4kB 0 1 2 3 4 5 6 ... 493 494 495 496 497 498 499
- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
home_team (match) <U8 2kB ...
away_team (match) <U8 2kB ...
Data variables:
home_points (chain, draw, match) float64 960kB ...
away_points (chain, draw, match) float64 960kB ...
Attributes:
created_at: 2024-03-06T20:46:24.120642
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* chain: 4
* draw: 500
* match: 60 - Coordinates: (5)
* chain
(chain)
int64
0 1 2 3
* draw
(draw)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(500,))
* match
(match)
<U16
'Wales Italy' ... 'Ireland England'
array(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'], dtype='<U16')
* home_team
(match)
<U8
...
[60 values with dtype=<U8]
* away_team
(match)
<U8
...
[60 values with dtype=<U8] - Data variables: (2)
* home_points
(chain, draw, match)
float64
...
[120000 values with dtype=float64]
* away_points
(chain, draw, match)
float64
...
[120000 values with dtype=float64] - Indexes: (3)
* PandasIndex
PandasIndex(Index([0, 1, 2, 3], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
...
490, 491, 492, 493, 494, 495, 496, 497, 498, 499],
dtype='int64', name='draw', length=500))
* PandasIndex
PandasIndex(Index(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'],
dtype='object', name='match')) - Attributes: (4)
created_at :
2024-03-06T20:46:24.120642
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- log_prior
<xarray.Dataset> Size: 260kB
Dimensions: (chain: 4, draw: 500, team: 6)
Coordinates:- chain (chain) int64 32B 0 1 2 3
- draw (draw) int64 4kB 0 1 2 3 4 5 6 7 ... 493 494 495 496 497 498 499
- team (team) <U8 192B 'Wales' 'France' 'Ireland' ... 'Italy' 'England'
Data variables:
home (chain, draw) float64 16kB ...
sd_att (chain, draw) float64 16kB ...
sd_def (chain, draw) float64 16kB ...
intercept (chain, draw) float64 16kB ...
atts_star (chain, draw, team) float64 96kB ...
defs_star (chain, draw, team) float64 96kB ...
Attributes:
created_at: 2024-03-06T20:46:24.377610
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* chain: 4
* draw: 500
* team: 6 - Coordinates: (3)
* chain
(chain)
int64
0 1 2 3
* draw
(draw)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(500,))
* team
(team)
<U8
'Wales' 'France' ... 'England'
array(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'],
dtype='<U8') - Data variables: (6)
* home
(chain, draw)
float64
...
[2000 values with dtype=float64]
* sd_att
(chain, draw)
float64
...
[2000 values with dtype=float64]
* sd_def
(chain, draw)
float64
...
[2000 values with dtype=float64]
* intercept
(chain, draw)
float64
...
[2000 values with dtype=float64]
* atts_star
(chain, draw, team)
float64
...
[12000 values with dtype=float64]
* defs_star
(chain, draw, team)
float64
...
[12000 values with dtype=float64] - Indexes: (3)
* PandasIndex
PandasIndex(Index([0, 1, 2, 3], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
...
490, 491, 492, 493, 494, 495, 496, 497, 498, 499],
dtype='int64', name='draw', length=500))
* PandasIndex
PandasIndex(Index(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'], dtype='object', name='team')) - Attributes: (4)
created_at :
2024-03-06T20:46:24.377610
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- sample_stats
<xarray.Dataset> Size: 248kB
Dimensions: (chain: 4, draw: 500)
Coordinates:- chain (chain) int64 32B 0 1 2 3
- draw (draw) int64 4kB 0 1 2 3 4 5 ... 495 496 497 498 499
Data variables: (12/17)
max_energy_error (chain, draw) float64 16kB ...
index_in_trajectory (chain, draw) int64 16kB ...
smallest_eigval (chain, draw) float64 16kB ...
perf_counter_start (chain, draw) float64 16kB ...
largest_eigval (chain, draw) float64 16kB ...
step_size (chain, draw) float64 16kB ...
... ...
reached_max_treedepth (chain, draw) bool 2kB ...
perf_counter_diff (chain, draw) float64 16kB ...
tree_depth (chain, draw) int64 16kB ...
process_time_diff (chain, draw) float64 16kB ...
step_size_bar (chain, draw) float64 16kB ...
energy (chain, draw) float64 16kB ...
Attributes:
created_at: 2024-03-06T20:46:23.854033
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9
sampling_time: 8.503105401992798
tuning_steps: 1000- Dimensions:
* chain: 4
* draw: 500 - Coordinates: (2)
* chain
(chain)
int64
0 1 2 3
* draw
(draw)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(500,)) - Data variables: (17)
* max_energy_error
(chain, draw)
float64
...
[2000 values with dtype=float64]
* index_in_trajectory
(chain, draw)
int64
...
[2000 values with dtype=int64]
* smallest_eigval
(chain, draw)
float64
...
[2000 values with dtype=float64]
* perf_counter_start
(chain, draw)
float64
...
[2000 values with dtype=float64]
* largest_eigval
(chain, draw)
float64
...
[2000 values with dtype=float64]
* step_size
(chain, draw)
float64
...
[2000 values with dtype=float64]
* n_steps
(chain, draw)
float64
...
[2000 values with dtype=float64]
* lp
(chain, draw)
float64
...
[2000 values with dtype=float64]
* diverging
(chain, draw)
bool
...
[2000 values with dtype=bool]
* energy_error
(chain, draw)
float64
...
[2000 values with dtype=float64]
* acceptance_rate
(chain, draw)
float64
...
[2000 values with dtype=float64]
* reached_max_treedepth
(chain, draw)
bool
...
[2000 values with dtype=bool]
* perf_counter_diff
(chain, draw)
float64
...
[2000 values with dtype=float64]
* tree_depth
(chain, draw)
int64
...
[2000 values with dtype=int64]
* process_time_diff
(chain, draw)
float64
...
[2000 values with dtype=float64]
* step_size_bar
(chain, draw)
float64
...
[2000 values with dtype=float64]
* energy
(chain, draw)
float64
...
[2000 values with dtype=float64] - Indexes: (2)
* PandasIndex
PandasIndex(Index([0, 1, 2, 3], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
...
490, 491, 492, 493, 494, 495, 496, 497, 498, 499],
dtype='int64', name='draw', length=500)) - Attributes: (6)
created_at :
2024-03-06T20:46:23.854033
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
sampling_time :
8.503105401992798
tuning_steps :
1000
- Dimensions:
- prior
<xarray.Dataset> Size: 116kB
Dimensions: (chain: 1, draw: 500, team: 6)
Coordinates:- chain (chain) int64 8B 0
- draw (draw) int64 4kB 0 1 2 3 4 5 6 7 ... 493 494 495 496 497 498 499
- team (team) <U8 192B 'Wales' 'France' 'Ireland' ... 'Italy' 'England'
Data variables:
atts_star (chain, draw, team) float64 24kB ...
sd_att (chain, draw) float64 4kB ...
atts (chain, draw, team) float64 24kB ...
sd_def (chain, draw) float64 4kB ...
defs (chain, draw, team) float64 24kB ...
intercept (chain, draw) float64 4kB ...
home (chain, draw) float64 4kB ...
defs_star (chain, draw, team) float64 24kB ...
Attributes:
created_at: 2024-03-06T20:46:09.475945
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* chain: 1
* draw: 500
* team: 6 - Coordinates: (3)
* chain
(chain)
int64
0
* draw
(draw)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(500,))
* team
(team)
<U8
'Wales' 'France' ... 'England'
array(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'],
dtype='<U8') - Data variables: (8)
* atts_star
(chain, draw, team)
float64
...
[3000 values with dtype=float64]
* sd_att
(chain, draw)
float64
...
[500 values with dtype=float64]
* atts
(chain, draw, team)
float64
...
[3000 values with dtype=float64]
* sd_def
(chain, draw)
float64
...
[500 values with dtype=float64]
* defs
(chain, draw, team)
float64
...
[3000 values with dtype=float64]
* intercept
(chain, draw)
float64
...
[500 values with dtype=float64]
* home
(chain, draw)
float64
...
[500 values with dtype=float64]
* defs_star
(chain, draw, team)
float64
...
[3000 values with dtype=float64] - Indexes: (3)
* PandasIndex
PandasIndex(Index([0], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
...
490, 491, 492, 493, 494, 495, 496, 497, 498, 499],
dtype='int64', name='draw', length=500))
* PandasIndex
PandasIndex(Index(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'], dtype='object', name='team')) - Attributes: (4)
created_at :
2024-03-06T20:46:09.475945
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- prior_predictive
<xarray.Dataset> Size: 492kB
Dimensions: (chain: 1, draw: 500, match: 60)
Coordinates:- chain (chain) int64 8B 0
- draw (draw) int64 4kB 0 1 2 3 4 5 6 ... 493 494 495 496 497 498 499
- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
home_team (match) <U8 2kB ...
away_team (match) <U8 2kB ...
Data variables:
away_points (chain, draw, match) int64 240kB ...
home_points (chain, draw, match) int64 240kB ...
Attributes:
created_at: 2024-03-06T20:46:09.479330
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* chain: 1
* draw: 500
* match: 60 - Coordinates: (5)
* chain
(chain)
int64
0
* draw
(draw)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(500,))
* match
(match)
<U16
'Wales Italy' ... 'Ireland England'
array(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'], dtype='<U16')
* home_team
(match)
<U8
...
[60 values with dtype=<U8]
* away_team
(match)
<U8
...
[60 values with dtype=<U8] - Data variables: (2)
* away_points
(chain, draw, match)
int64
...
[30000 values with dtype=int64]
* home_points
(chain, draw, match)
int64
...
[30000 values with dtype=int64] - Indexes: (3)
* PandasIndex
PandasIndex(Index([0], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
...
490, 491, 492, 493, 494, 495, 496, 497, 498, 499],
dtype='int64', name='draw', length=500))
* PandasIndex
PandasIndex(Index(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'],
dtype='object', name='match')) - Attributes: (4)
created_at :
2024-03-06T20:46:09.479330
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- observed_data
<xarray.Dataset> Size: 9kB
Dimensions: (match: 60)
Coordinates:- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
home_team (match) <U8 2kB ...
away_team (match) <U8 2kB ...
Data variables:
home_points (match) int64 480B ...
away_points (match) int64 480B ...
Attributes:
created_at: 2024-03-06T20:46:09.480812
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* match: 60 - Coordinates: (3)
* match
(match)
<U16
'Wales Italy' ... 'Ireland England'
array(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'], dtype='<U16')
* home_team
(match)
<U8
...
[60 values with dtype=<U8]
* away_team
(match)
<U8
...
[60 values with dtype=<U8] - Data variables: (2)
* home_points
(match)
int64
...
[60 values with dtype=int64]
* away_points
(match)
int64
...
[60 values with dtype=int64] - Indexes: (1)
* PandasIndex
PandasIndex(Index(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'],
dtype='object', name='match')) - Attributes: (4)
created_at :
2024-03-06T20:46:09.480812
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
- unconstrained_posterior
<xarray.Dataset> Size: 36kB
Dimensions: (chain: 4, draw: 500)
Coordinates:- chain (chain) int64 32B 0 1 2 3
- draw (draw) int64 4kB 0 1 2 3 4 5 6 7 ... 493 494 495 496 497 498 499
Data variables:
sd_att (chain, draw) float64 16kB ...
sd_def (chain, draw) float64 16kB ...
Attributes:
sd_att: pymc.logprob.transforms.LogTransform
sd_def: pymc.logprob.transforms.LogTransform- Dimensions:
* chain: 4
* draw: 500 - Coordinates: (2)
* chain
(chain)
int64
0 1 2 3
* draw
(draw)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(500,)) - Data variables: (2)
* sd_att
(chain, draw)
float64
...
[2000 values with dtype=float64]
* sd_def
(chain, draw)
float64
...
[2000 values with dtype=float64] - Indexes: (2)
* PandasIndex
PandasIndex(Index([0, 1, 2, 3], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
...
490, 491, 492, 493, 494, 495, 496, 497, 498, 499],
dtype='int64', name='draw', length=500)) - Attributes: (2)
sd_att :
pymc.logprob.transforms.LogTransform
sd_def :
pymc.logprob.transforms.LogTransform
- Dimensions:
In order to stack two dimensions chain
and draw
to sample
, we can use:
idata.stack(sample=["chain", "draw"], inplace=True) idata
- posterior
<xarray.Dataset> Size: 496kB
Dimensions: (sample: 2000, team: 6)
Coordinates:- team (team) <U8 192B 'Wales' 'France' 'Ireland' ... 'Italy' 'England'
- sample (sample) object 16kB MultiIndex
- chain (sample) int64 16kB 0 0 0 0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3 3 3
- draw (sample) int64 16kB 0 1 2 3 4 5 6 ... 493 494 495 496 497 498 499
Data variables:
home (sample) float64 16kB 0.1341 0.2025 0.2146 ... 0.1988 0.1177
intercept (sample) float64 16kB 2.949 2.907 2.888 ... 2.908 2.876 2.954
atts_star (team, sample) float64 96kB 0.3346 0.1301 ... 0.4086 0.3763
defs_star (team, sample) float64 96kB -0.4319 -0.1368 ... 0.001797 -0.4827
sd_att (sample) float64 16kB 0.3047 0.1598 0.1965 ... 0.4021 0.2962
sd_def (sample) float64 16kB 0.5739 0.4876 0.3242 ... 0.3384 0.3576
atts (team, sample) float64 96kB 0.1833 0.1542 ... 0.2989 0.3514
defs (team, sample) float64 96kB -0.09829 -0.1253 ... -0.1787 -0.2903
Attributes:
created_at: 2024-03-06T20:46:23.841916
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9
sampling_time: 8.503105401992798
tuning_steps: 1000- Dimensions:
* sample: 2000
* team: 6 - Coordinates: (4)
* team
(team)
<U8
'Wales' 'France' ... 'England'
array(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'],
dtype='<U8')
* sample
(sample)
object
MultiIndex
array([(0, 0), (0, 1), (0, 2), ..., (3, 497), (3, 498), (3, 499)],
shape=(202,), dtype=object)
* chain
(sample)
int64
0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3
array([0, 0, 0, ..., 3, 3, 3], shape=(202,))
* draw
(sample)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(202,)) - Data variables: (8)
* home
(sample)
float64
0.1341 0.2025 ... 0.1988 0.1177
array([0.13408519, 0.20247262, 0.21455892, ..., 0.17932739, 0.19881358,
0.11767652], shape=(2000,))
* intercept
(sample)
float64
2.949 2.907 2.888 ... 2.876 2.954
array([2.94887444, 2.90651711, 2.88779969, ..., 2.90827051, 2.87575421,
2.95354855], shape=(2000,))
* atts_star
(team, sample)
float64
0.3346 0.1301 ... 0.4086 0.3763
array([[ 0.3345804 , 0.13010732, 0.12930559, ..., 0.01957786,
0.34528579, 0.23011713],
[ 0.09127336, -0.12252053, -0.11542605, ..., -0.29095022,
0.00514874, -0.08794849],
[ 0.2622012 , 0.09345455, 0.04391594, ..., -0.15567664,
0.22387013, 0.14092251],
[ 0.01167204, -0.12397064, -0.1501342 , ..., -0.32603692,
-0.03426023, -0.19817556],
[-0.16773523, -0.29440377, -0.40474183, ..., -0.48014026,
-0.29042113, -0.31154567],
[ 0.3755542 , 0.17266724, 0.24817313, ..., 0.10377521,
0.40856436, 0.37630503]], shape=(6, 2000))
* defs_star
(team, sample)
float64
-0.4319 -0.1368 ... -0.4827
array([[-0.43185756, -0.13675304, -0.24804094, ..., -0.18692347,
0.00435018, -0.31681846],
[-0.40137989, -0.08412848, -0.12189797, ..., -0.05624302,
0.11161378, -0.24646802],
[-0.68291185, -0.32905182, -0.57025033, ..., -0.49108944,
-0.29887096, -0.59106925],
[-0.17161927, 0.17807832, 0.07661587, ..., -0.0213034 ,
0.46960521, 0.06063741],
[ 0.2225435 , 0.5470153 , 0.42543691, ..., 0.39009367,
0.79437464, 0.42188139],
[-0.53615971, -0.2438379 , -0.26712113, ..., -0.29332771,
0.00179694, -0.48268733]], shape=(6, 2000))
* sd_att
(sample)
float64
0.3047 0.1598 ... 0.4021 0.2962
array([0.30465845, 0.1597652 , 0.19652797, ..., 0.30586222, 0.40206892,
0.29615459], shape=(2000,))
* sd_def
(sample)
float64
0.5739 0.4876 ... 0.3384 0.3576
array([0.5738763 , 0.4876292 , 0.32421015, ..., 0.53621936, 0.33842797,
0.3576052 ], shape=(2000,))
* atts
(team, sample)
float64
0.1833 0.1542 ... 0.2989 0.3514
array([[ 0.18332274, 0.15421829, 0.17079016, ..., 0.20781969,
0.23558785, 0.2051713 ],
[-0.0599843 , -0.09840956, -0.07394147, ..., -0.1027084 ,
-0.10454921, -0.11289431],
[ 0.11094354, 0.11756552, 0.08540051, ..., 0.03256518,
0.11417219, 0.11597669],
[-0.13958562, -0.09985967, -0.10864963, ..., -0.13779509,
-0.14395817, -0.22312138],
[-0.31899289, -0.2702928 , -0.36325726, ..., -0.29189843,
-0.40011907, -0.3364915 ],
[ 0.22429654, 0.19677821, 0.2896577 , ..., 0.29201704,
0.29886641, 0.3513592 ]], shape=(6, 2000))
* defs
(team, sample)
float64
-0.09829 -0.1253 ... -0.2903
array([[-0.09829343, -0.12530677, -0.130498 , ..., -0.07712457,
-0.17612812, -0.12439775],
[-0.06781576, -0.07268221, -0.00435504, ..., 0.05355588,
-0.06886452, -0.05404731],
[-0.34934772, -0.31760555, -0.4527074 , ..., -0.38129055,
-0.47934926, -0.39864854],
[ 0.16194486, 0.18952459, 0.1941588 , ..., 0.08849549,
0.28912691, 0.25305812],
[ 0.55610763, 0.55846157, 0.54297984, ..., 0.49989256,
0.61389635, 0.6143021 ],
[-0.20259558, -0.23239163, -0.1495782 , ..., -0.18352882,
-0.17868136, -0.29026662]], shape=(6, 2000)) - Indexes: (2)
* PandasIndex
PandasIndex(Index(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'], dtype='object', name='team'))
* PandasMultiIndex
PandasIndex(MultiIndex([(0, 0),
(0, 1),
(0, 2),
(0, 3),
(0, 4),
(0, 5),
(0, 6),
(0, 7),
(0, 8),
(0, 9),
...
(3, 490),
(3, 491),
(3, 492),
(3, 493),
(3, 494),
(3, 495),
(3, 496),
(3, 497),
(3, 498),
(3, 499)],
name='sample', length=2000)) - Attributes: (6)
created_at :
2024-03-06T20:46:23.841916
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
sampling_time :
8.503105401992798
tuning_steps :
1000
- Dimensions:
- posterior_predictive
<xarray.Dataset> Size: 2MB
Dimensions: (match: 60, sample: 2000)
Coordinates:- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
home_team (match) <U8 2kB ...
away_team (match) <U8 2kB ... - sample (sample) object 16kB MultiIndex
- chain (sample) int64 16kB 0 0 0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3 3 3
- draw (sample) int64 16kB 0 1 2 3 4 5 6 ... 494 495 496 497 498 499
Data variables:
home_points (match, sample) int64 960kB 48 49 51 24 46 ... 18 23 19 22 12
away_points (match, sample) int64 960kB 12 12 8 12 6 10 ... 23 14 12 9 15
Attributes:
created_at: 2024-03-06T20:46:25.689246
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* match: 60
* sample: 2000 - Coordinates: (6)
* match
(match)
<U16
'Wales Italy' ... 'Ireland England'
array(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'], dtype='<U16')
* home_team
(match)
<U8
...
[60 values with dtype=<U8]
* away_team
(match)
<U8
...
[60 values with dtype=<U8]
* sample
(sample)
object
MultiIndex
array([(0, 0), (0, 1), (0, 2), ..., (3, 497), (3, 498), (3, 499)],
shape=(202,), dtype=object)
* chain
(sample)
int64
0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3
array([0, 0, 0, ..., 3, 3, 3], shape=(202,))
* draw
(sample)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(202,)) - Data variables: (2)
* home_points
(match, sample)
int64
48 49 51 24 46 ... 18 23 19 22 12
array([[48, 49, 51, ..., 51, 46, 48],
[22, 19, 17, ..., 18, 12, 11],
[23, 35, 25, ..., 27, 24, 23],
...,
[32, 32, 30, ..., 32, 32, 33],
[ 8, 14, 16, ..., 25, 16, 18],
[21, 19, 16, ..., 19, 22, 12]], shape=(60, 2000))
* away_points
(match, sample)
int64
12 12 8 12 6 10 ... 23 14 12 9 15
array([[12, 12, 8, ..., 13, 8, 15],
[24, 22, 24, ..., 27, 18, 21],
[10, 11, 7, ..., 13, 12, 13],
...,
[14, 17, 12, ..., 17, 14, 15],
[20, 12, 23, ..., 25, 19, 28],
[17, 18, 11, ..., 12, 9, 15]], shape=(60, 2000)) - Indexes: (2)
* PandasIndex
PandasIndex(Index(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'],
dtype='object', name='match'))
* PandasMultiIndex
PandasIndex(MultiIndex([(0, 0),
(0, 1),
(0, 2),
(0, 3),
(0, 4),
(0, 5),
(0, 6),
(0, 7),
(0, 8),
(0, 9),
...
(3, 490),
(3, 491),
(3, 492),
(3, 493),
(3, 494),
(3, 495),
(3, 496),
(3, 497),
(3, 498),
(3, 499)],
name='sample', length=2000)) - Attributes: (4)
created_at :
2024-03-06T20:46:25.689246
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
- log_likelihood
<xarray.Dataset> Size: 2MB
Dimensions: (match: 60, sample: 2000)
Coordinates:- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
home_team (match) <U8 2kB ...
away_team (match) <U8 2kB ... - sample (sample) object 16kB MultiIndex
- chain (sample) int64 16kB 0 0 0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3 3 3
- draw (sample) int64 16kB 0 1 2 3 4 5 6 ... 494 495 496 497 498 499
Data variables:
home_points (match, sample) float64 960kB -9.405 -9.389 ... -3.71 -3.011
away_points (match, sample) float64 960kB -2.499 -2.552 ... -3.354 -4.934
Attributes:
created_at: 2024-03-06T20:46:24.120642
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* match: 60
* sample: 2000 - Coordinates: (6)
* match
(match)
<U16
'Wales Italy' ... 'Ireland England'
array(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'], dtype='<U16')
* home_team
(match)
<U8
...
[60 values with dtype=<U8]
* away_team
(match)
<U8
...
[60 values with dtype=<U8]
* sample
(sample)
object
MultiIndex
array([(0, 0), (0, 1), (0, 2), ..., (3, 497), (3, 498), (3, 499)],
shape=(202,), dtype=object)
* chain
(sample)
int64
0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3
array([0, 0, 0, ..., 3, 3, 3], shape=(202,))
* draw
(sample)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(202,)) - Data variables: (2)
* home_points
(match, sample)
float64
-9.405 -9.389 ... -3.71 -3.011
array([[ -9.40503813, -9.38868719, -9.26371557, ..., -8.80657574,
-11.95856088, -11.06567206],
[ -4.71505119, -5.11864814, -4.20549105, ..., -4.89336187,
-4.98973966, -6.30407661],
[ -2.59590512, -2.68932022, -2.62319735, ..., -2.79317224,
-2.90002593, -2.75753056],
...,
[ -2.87036205, -3.22804065, -3.04604495, ..., -2.70667107,
-3.08894235, -2.74088467],
[ -2.47027792, -2.53861155, -2.5136005 , ..., -2.49613349,
-2.80229105, -2.669195 ],
[ -3.57686697, -3.59668828, -3.92306146, ..., -3.22820606,
-3.70999097, -3.01053645]], shape=(60, 2000))
* away_points
(match, sample)
float64
-2.499 -2.552 ... -3.354 -4.934
array([[ -2.49890805, -2.55173379, -2.94632712, ..., -2.48069196,
-3.37593267, -2.60277523],
[ -2.57334919, -2.75994094, -2.51173119, ..., -2.58214111,
-2.57267635, -2.57661935],
[ -3.52372672, -3.694786 , -2.86203961, ..., -3.14874369,
-2.57554921, -2.88481789],
...,
[-16.31078274, -16.87357685, -15.1606194 , ..., -14.95233646,
-15.87526202, -17.63904961],
[ -2.65778678, -2.45749429, -2.62417213, ..., -3.14087568,
-2.5879505 , -2.81325429],
[ -4.22853381, -3.94161543, -3.53167773, ..., -4.1908865 ,
-3.35392222, -4.93375258]], shape=(60, 2000)) - Indexes: (2)
* PandasIndex
PandasIndex(Index(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'],
dtype='object', name='match'))
* PandasMultiIndex
PandasIndex(MultiIndex([(0, 0),
(0, 1),
(0, 2),
(0, 3),
(0, 4),
(0, 5),
(0, 6),
(0, 7),
(0, 8),
(0, 9),
...
(3, 490),
(3, 491),
(3, 492),
(3, 493),
(3, 494),
(3, 495),
(3, 496),
(3, 497),
(3, 498),
(3, 499)],
name='sample', length=2000)) - Attributes: (4)
created_at :
2024-03-06T20:46:24.120642
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
- log_prior
<xarray.Dataset> Size: 304kB
Dimensions: (sample: 2000, team: 6)
Coordinates:- team (team) <U8 192B 'Wales' 'France' 'Ireland' ... 'Italy' 'England'
- sample (sample) object 16kB MultiIndex
- chain (sample) int64 16kB 0 0 0 0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3 3 3
- draw (sample) int64 16kB 0 1 2 3 4 5 6 ... 493 494 495 496 497 498 499
Data variables:
home (sample) float64 16kB -0.9279 -0.9394 -0.942 ... -0.9387 -0.9259
sd_att (sample) float64 16kB -0.9305 -0.9221 -0.9238 ... -0.9391 -0.9299
sd_def (sample) float64 16kB -0.9601 -0.9487 -0.9321 ... -0.9333 -0.9349
intercept (sample) float64 16kB -0.9202 -0.9233 -0.9252 ... -0.9267 -0.92
atts_star (team, sample) float64 96kB -0.3334 0.5835 ... -0.5241 -0.5093
defs_star (team, sample) float64 96kB -0.6467 -0.2401 ... 0.1645 -0.8016
Attributes:
created_at: 2024-03-06T20:46:24.377610
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* sample: 2000
* team: 6 - Coordinates: (4)
* team
(team)
<U8
'Wales' 'France' ... 'England'
array(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'],
dtype='<U8')
* sample
(sample)
object
MultiIndex
array([(0, 0), (0, 1), (0, 2), ..., (3, 497), (3, 498), (3, 499)],
shape=(202,), dtype=object)
* chain
(sample)
int64
0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3
array([0, 0, 0, ..., 3, 3, 3], shape=(202,))
* draw
(sample)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(202,)) - Data variables: (6)
* home
(sample)
float64
-0.9279 -0.9394 ... -0.9387 -0.9259
array([-0.92792795, -0.93943611, -0.9419563 , ..., -0.93501769,
-0.93870195, -0.92586241], shape=(2000,))
* sd_att
(sample)
float64
-0.9305 -0.9221 ... -0.9391 -0.9299
array([-0.93054063, -0.92212915, -0.92376644, ..., -0.9306325 ,
-0.93914596, -0.92990198], shape=(2000,))
* sd_def
(sample)
float64
-0.9601 -0.9487 ... -0.9333 -0.9349
array([-0.96010529, -0.94866131, -0.93207756, ..., -0.95487994,
-0.93325522, -0.93492372], shape=(2000,))
* intercept
(sample)
float64
-0.9202 -0.9233 ... -0.9267 -0.92
array([-0.92024544, -0.92330806, -0.92523299, ..., -0.92314568,
-0.92665704, -0.9200174 ], shape=(2000,))
* atts_star
(team, sample)
float64
-0.3334 0.5835 ... -0.5241 -0.5093
array([[-0.33341238, 0.58351564, 0.49156286, ..., 0.26363345,
-0.376552 , -0.00394248],
[ 0.22474762, 0.62106005, 0.53553591, ..., -0.1867525 ,
-0.00788875, 0.2538401 ],
[-0.10072504, 0.74402865, 0.68304505, ..., 0.13615353,
-0.16281733, 0.1847228 ],
[ 0.26889153, 0.61405828, 0.41621517, ..., -0.30245344,
-0.01143712, 0.0740459 ],
[ 0.11806281, -0.78271132, -1.41267939, ..., -0.96644247,
-0.26867753, -0.25538502],
[-0.49015622, 0.33109445, -0.08930457, ..., 0.20812402,
-0.5240923 , -0.50932423]], shape=(6, 2000))
* defs_star
(team, sample)
float64
-0.6467 -0.2401 ... 0.1645 -0.8016
array([[-0.64674576, -0.24006315, -0.08523527, ..., -0.35648588,
0.16442285, -0.28306192],
[-0.60819047, -0.21562106, 0.13674269, ..., -0.30122734,
0.11012122, -0.12812372],
[-1.07164516, -0.42841555, -1.33942406, ..., -0.71510514,
-0.22544095, -1.25657627],
[-0.40831339, -0.26742116, 0.17950234, ..., -0.29651578,
-0.79822191, 0.09501097],
[-0.43878767, -0.82993973, -0.65354339, ..., -0.56034668,
-2.59028298, -0.58650684],
[-0.80003434, -0.32576243, -0.13199193, ..., -0.44534713,
0.16449137, -0.80156201]], shape=(6, 2000)) - Indexes: (2)
* PandasIndex
PandasIndex(Index(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'], dtype='object', name='team'))
* PandasMultiIndex
PandasIndex(MultiIndex([(0, 0),
(0, 1),
(0, 2),
(0, 3),
(0, 4),
(0, 5),
(0, 6),
(0, 7),
(0, 8),
(0, 9),
...
(3, 490),
(3, 491),
(3, 492),
(3, 493),
(3, 494),
(3, 495),
(3, 496),
(3, 497),
(3, 498),
(3, 499)],
name='sample', length=2000)) - Attributes: (4)
created_at :
2024-03-06T20:46:24.377610
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- sample_stats
<xarray.Dataset> Size: 292kB
Dimensions: (sample: 2000)
Coordinates:- sample (sample) object 16kB MultiIndex
- chain (sample) int64 16kB 0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3
- draw (sample) int64 16kB 0 1 2 3 4 ... 495 496 497 498 499
Data variables: (12/17)
max_energy_error (sample) float64 16kB -0.5529 0.4738 ... -1.006
index_in_trajectory (sample) int64 16kB -5 -15 -4 -11 ... 17 24 -28 -20
smallest_eigval (sample) float64 16kB nan nan nan nan ... nan nan nan
perf_counter_start (sample) float64 16kB 9.249e+03 ... 9.251e+03
largest_eigval (sample) float64 16kB nan nan nan nan ... nan nan nan
step_size (sample) float64 16kB 0.3105 0.3105 ... 0.2495 0.2495
... ...
reached_max_treedepth (sample) bool 2kB False False False ... False False
perf_counter_diff (sample) float64 16kB 0.005344 0.005213 ... 0.006747
tree_depth (sample) int64 16kB 5 5 5 5 3 3 4 4 ... 5 5 3 6 6 5 5
process_time_diff (sample) float64 16kB 0.005344 0.005214 ... 0.006749
step_size_bar (sample) float64 16kB 0.2456 0.2456 ... 0.2186 0.2186
energy (sample) float64 16kB 539.7 539.7 ... 542.7 547.7
Attributes:
created_at: 2024-03-06T20:46:23.854033
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9
sampling_time: 8.503105401992798
tuning_steps: 1000- Dimensions:
* sample: 2000 - Coordinates: (3)
* sample
(sample)
object
MultiIndex
array([(0, 0), (0, 1), (0, 2), ..., (3, 497), (3, 498), (3, 499)],
shape=(202,), dtype=object)
* chain
(sample)
int64
0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3
array([0, 0, 0, ..., 3, 3, 3], shape=(202,))
* draw
(sample)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(202,)) - Data variables: (17)
* max_energy_error
(sample)
float64
-0.5529 0.4738 ... -1.753 -1.006
array([-0.55287234, 0.4737601 , 0.38146515, ..., -1.2172522 ,
-1.75266286, -1.00632993], shape=(2000,))
* index_in_trajectory
(sample)
int64
-5 -15 -4 -11 -1 ... 17 24 -28 -20
array([ -5, -15, -4, ..., 24, -28, -20], shape=(2000,))
* smallest_eigval
(sample)
float64
nan nan nan nan ... nan nan nan nan
array([nan, nan, nan, ..., nan, nan, nan], shape=(2000,))
* perf_counter_start
(sample)
float64
9.249e+03 9.249e+03 ... 9.251e+03
array([9248.82754331, 9248.8330349 , 9248.8383987 , ..., 9251.30902326,
9251.31643629, 9251.32183691], shape=(2000,))
* largest_eigval
(sample)
float64
nan nan nan nan ... nan nan nan nan
array([nan, nan, nan, ..., nan, nan, nan], shape=(2000,))
* step_size
(sample)
float64
0.3105 0.3105 ... 0.2495 0.2495
array([0.3104718, 0.3104718, 0.3104718, ..., 0.2495061, 0.2495061,
0.2495061], shape=(2000,))
* n_steps
(sample)
float64
31.0 31.0 31.0 ... 39.0 31.0 31.0
array([31., 31., 31., ..., 39., 31., 31.], shape=(2000,))
* lp
(sample)
float64
-532.0 -530.8 ... -537.5 -540.5
array([-531.98811454, -530.75687589, -530.48713886, ..., -538.81650266,
-537.50354916, -540.4738906 ], shape=(2000,))
* diverging
(sample)
bool
False False False ... False False
array([False, False, False, ..., False, False, False], shape=(2000,))
* energy_error
(sample)
float64
-0.4496 0.1285 ... -0.526 0.5242
array([-0.449581 , 0.12848133, -0.01048991, ..., 0.48898993,
-0.52595367, 0.52422027], shape=(2000,))
* acceptance_rate
(sample)
float64
0.9401 0.8446 0.8817 ... 1.0 0.8905
array([0.94014478, 0.84460776, 0.88171987, ..., 0.85377188, 1. ,
0.89048311], shape=(2000,))
* reached_max_treedepth
(sample)
bool
False False False ... False False
array([False, False, False, ..., False, False, False], shape=(2000,))
* perf_counter_diff
(sample)
float64
0.005344 0.005213 ... 0.006747
array([0.0053438 , 0.00521331, 0.0053572 , ..., 0.00716263, 0.00526279,
0.0067473 ], shape=(2000,))
* tree_depth
(sample)
int64
5 5 5 5 3 3 4 4 ... 4 5 5 3 6 6 5 5
array([5, 5, 5, ..., 6, 5, 5], shape=(2000,))
* process_time_diff
(sample)
float64
0.005344 0.005214 ... 0.006749
array([0.00534419, 0.00521375, 0.00535746, ..., 0.0071642 , 0.00526292,
0.00674856], shape=(2000,))
* step_size_bar
(sample)
float64
0.2456 0.2456 ... 0.2186 0.2186
array([0.24556179, 0.24556179, 0.24556179, ..., 0.21861927, 0.21861927,
0.21861927], shape=(2000,))
* energy
(sample)
float64
539.7 539.7 537.4 ... 542.7 547.7
array([539.72702595, 539.67305986, 537.35156684, ..., 546.40260103,
542.69269775, 547.74167364], shape=(2000,)) - Indexes: (1)
* PandasMultiIndex
PandasIndex(MultiIndex([(0, 0),
(0, 1),
(0, 2),
(0, 3),
(0, 4),
(0, 5),
(0, 6),
(0, 7),
(0, 8),
(0, 9),
...
(3, 490),
(3, 491),
(3, 492),
(3, 493),
(3, 494),
(3, 495),
(3, 496),
(3, 497),
(3, 498),
(3, 499)],
name='sample', length=2000)) - Attributes: (6)
created_at :
2024-03-06T20:46:23.854033
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
sampling_time :
8.503105401992798
tuning_steps :
1000
- Dimensions:
- prior
<xarray.Dataset> Size: 124kB
Dimensions: (team: 6, sample: 500)
Coordinates:- team (team) <U8 192B 'Wales' 'France' 'Ireland' ... 'Italy' 'England'
- sample (sample) object 4kB MultiIndex
- chain (sample) int64 4kB 0 0 0 0 0 0 0 0 0 0 0 ... 0 0 0 0 0 0 0 0 0 0
- draw (sample) int64 4kB 0 1 2 3 4 5 6 ... 493 494 495 496 497 498 499
Data variables:
atts_star (team, sample) float64 24kB -0.1165 -0.6705 ... 0.9718 0.645
sd_att (sample) float64 4kB 2.205 1.604 0.6585 ... 1.116 0.9112 1.459
atts (team, sample) float64 24kB -0.4148 -0.2689 ... 1.039 0.416
sd_def (sample) float64 4kB 0.01573 0.382 0.9764 ... 0.1869 2.879 1.323
defs (team, sample) float64 24kB -0.003092 0.2726 ... -1.412 -0.3131
intercept (sample) float64 4kB 1.172 3.866 2.439 4.324 ... 2.066 1.964 3.91
home (sample) float64 4kB 0.694 -0.6541 0.4198 ... -2.354 -0.9812
defs_star (team, sample) float64 24kB 0.003231 0.4705 ... -0.7006 0.001565
Attributes:
created_at: 2024-03-06T20:46:09.475945
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* team: 6
* sample: 500 - Coordinates: (4)
* team
(team)
<U8
'Wales' 'France' ... 'England'
array(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'],
dtype='<U8')
* sample
(sample)
object
MultiIndex
array([(0, 0), (0, 1), (0, 2), ..., (0, 497), (0, 498), (0, 499)],
shape=(202,), dtype=object)
* chain
(sample)
int64
0 0 0 0 0 0 0 0 ... 0 0 0 0 0 0 0 0
array([0, 0, 0, ..., 0, 0, 0], shape=(202,))
* draw
(sample)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(202,)) - Data variables: (8)
* atts_star
(team, sample)
float64
-0.1165 -0.6705 ... 0.9718 0.645
array([[-0.11653548, -0.67045656, -0.69838033, ..., 0.01926211,
-1.04638222, -0.432023 ],
[-0.76068888, 0.19873746, 0.23689877, ..., 0.03066497,
0.5622779 , 1.73440419],
[ 0.24774959, -1.4341374 , 1.10654263, ..., -0.69453399,
-0.70100014, -3.22005559],
[-1.66298142, 0.54366992, -0.26176343, ..., 1.0090901 ,
0.96508044, 3.61988443],
[ 4.17058201, -0.4159945 , 0.22528761, ..., -1.10046047,
-1.1534373 , -0.97328489],
[-0.08826983, -0.63106866, 0.52063122, ..., 1.27402601,
0.97180245, 0.64502926]], shape=(6, 500))
* sd_att
(sample)
float64
2.205 1.604 0.6585 ... 0.9112 1.459
array([2.20546369, 1.60356457, 0.65849302, 0.0572312 , 0.31562311,
2.26282831, 0.16691152, 0.59561427, 1.27063721, 1.36173294,
1.96728062, 2.48435848, 0.88213806, 0.64150973, 1.97634058,
1.18809564, 1.37980832, 1.37502331, 2.01922557, 0.04711769,
2.09144993, 0.79470926, 0.6518245 , 2.31796931, 1.1311066 ,
3.38204267, 2.60532898, 1.73966191, 1.05773776, 1.79633861,
2.82483306, 1.88425952, 1.51161539, 1.25111982, 2.57643833,
0.39642103, 2.27222944, 2.02843926, 0.01697714, 0.38724908,
0.19646502, 3.31025551, 1.32227486, 0.06342172, 0.68195723,
2.59481402, 1.14534856, 1.42103334, 1.58416535, 0.62023766,
4.27340613, 0.01080926, 0.1869434 , 1.34827065, 1.68025234,
0.48731921, 0.05645705, 0.38348926, 0.73786512, 0.33361236,
0.89157656, 0.61572163, 0.90265029, 2.17805297, 1.96418068,
1.80418375, 2.06542649, 2.74408555, 2.30604495, 0.99874451,
1.10860294, 0.65997802, 0.46789191, 1.4907774 , 0.69865055,
1.64931174, 1.13522103, 0.69872638, 3.15239885, 2.17428307,
0.98864123, 0.7919606 , 1.64172499, 1.39168035, 0.4406471 ,
2.01378242, 1.46100487, 0.45620004, 1.61901097, 1.43168856,
3.51815737, 0.79241495, 1.59222371, 1.92017755, 0.28487036,
3.3542204 , 0.2742325 , 0.38380064, 0.74659078, 1.74439873,
...
0.42997698, 0.29974895, 1.01655278, 4.38376933, 0.47918725,
1.98058231, 2.80093895, 1.93744658, 0.33026733, 5.93450881,
0.43642943, 4.73054438, 1.38211583, 0.134152 , 4.17213099,
1.33774156, 0.15394826, 0.50698738, 1.67131623, 2.44791313,
1.13146976, 3.03209901, 2.74220591, 1.66715335, 5.89795968,
1.90863078, 3.87343392, 0.99125713, 0.33856582, 1.82532308,
0.054058 , 0.76050408, 2.86417297, 1.65501302, 0.08617345,
1.07481481, 2.07591116, 0.89744735, 1.23646241, 1.18956069,
2.0922847 , 1.87442119, 4.24634847, 3.25426128, 1.07550273,
2.35581194, 0.59844341, 1.30532998, 0.10177707, 0.49751535,
0.45363006, 0.65138958, 2.32742978, 3.02956503, 0.33095512,
5.60594318, 1.33880515, 1.47036376, 3.43754041, 0.32298398,
2.14978813, 1.84183784, 4.00594407, 1.19448317, 0.3440357 ,
1.87511377, 1.56146392, 3.28352556, 0.57680717, 2.03868559,
2.66557225, 0.34487155, 0.10340286, 0.08913829, 1.82973108,
3.89887752, 4.07364688, 0.64811234, 0.05448153, 3.11940557,
0.61162175, 1.19922869, 1.21078004, 2.74243713, 0.01152906,
2.98603299, 0.4232183 , 1.36790322, 0.96100312, 2.75124642,
0.85042284, 0.77142185, 0.68109404, 0.06673708, 2.02325021,
0.44299416, 1.45761132, 1.11578256, 0.91120065, 1.4589616 ])
* atts
(team, sample)
float64
-0.4148 -0.2689 ... 1.039 0.416
array([[-0.41484481, -0.26891493, -0.88658307, ..., -0.07041268,
-0.97943907, -0.6610154 ],
[-1.05899821, 0.60027908, 0.04869603, ..., -0.05900982,
0.62922104, 1.50541179],
[-0.05055974, -1.03259578, 0.91833988, ..., -0.78420878,
-0.63405699, -3.44904799],
[-1.96129075, 0.94521155, -0.44996617, ..., 0.91941531,
1.03202359, 3.39089203],
[ 3.87227268, -0.01445287, 0.03708486, ..., -1.19013526,
-1.08649416, -1.20227729],
[-0.38657916, -0.22952704, 0.33242847, ..., 1.18435122,
1.03874559, 0.41603686]], shape=(6, 500))
* sd_def
(sample)
float64
0.01573 0.382 ... 2.879 1.323
array([1.57348085e-02, 3.81997203e-01, 9.76383097e-01, 4.60942144e+00,
2.79569278e+00, 1.75326632e+00, 6.50343175e-01, 2.89158499e+00,
2.18850160e+00, 9.65101971e-01, 2.49489685e+00, 1.63997925e+00,
2.62898959e+00, 3.33873613e+00, 1.40057308e+00, 1.91628264e+00,
4.05482468e-01, 1.17886411e+00, 2.85407142e+00, 1.90900872e+00,
1.86277626e-01, 3.14296879e+00, 1.22517761e+00, 3.43702280e+00,
1.64589157e+00, 3.53518192e+00, 1.40607878e+00, 1.68964973e-01,
1.30358743e-01, 3.44785953e+00, 1.89644001e+00, 1.93499325e+00,
1.36188421e+00, 1.65347386e+00, 2.89700613e+00, 2.01737625e+00,
1.37689799e+00, 3.86982613e-01, 2.19291523e+00, 3.17336490e+00,
5.10456145e+00, 3.23097690e+00, 5.06213366e-01, 2.53480536e-01,
9.26457022e-03, 1.70901471e+00, 1.75571911e+00, 9.39935556e-01,
2.07468195e+00, 1.09072030e+00, 2.97344555e+00, 4.29991964e-01,
1.95489050e+00, 2.78219175e+00, 2.74405452e-01, 3.94751510e+00,
3.49702605e-01, 2.80149241e+00, 5.43392842e-01, 1.27320783e+00,
4.52254364e-01, 2.03350955e+00, 2.20467680e+00, 1.03339478e+00,
6.94941153e-01, 3.54741328e-01, 2.99056844e+00, 5.89917836e-01,
3.11178691e+00, 1.86840652e+00, 4.56989766e+00, 3.39645937e-01,
3.66898419e+00, 1.07726208e-02, 5.22600556e+00, 3.16291225e-01,
1.03520431e+00, 2.89403917e-01, 2.90981246e+00, 1.86456705e+00,
...
1.20745716e+00, 1.28860539e+00, 2.85134827e+00, 2.85081988e+00,
1.91155657e+00, 4.55069455e-01, 6.25568028e-01, 4.49823836e+00,
1.31886661e+00, 1.63037087e+00, 6.64870658e-01, 5.12792031e-01,
2.57986290e+00, 2.70458814e+00, 3.50820414e-01, 6.22133865e-01,
7.61563556e-01, 1.61008884e+00, 1.05840101e+00, 2.04425085e+00,
3.21516366e-01, 6.56046830e-01, 8.16602448e-01, 3.09966769e-01,
3.47824395e-01, 3.09388949e+00, 3.14361229e+00, 4.85909061e+00,
1.46250101e+00, 3.38704445e+00, 1.98801950e+00, 1.18002011e+00,
3.08572727e+00, 1.44519852e-01, 9.87473814e-01, 8.88357425e-01,
1.03633193e+00, 2.64019204e+00, 1.70160752e+00, 2.59975123e+00,
1.14804571e-01, 3.41268935e+00, 1.15265234e+00, 7.39729312e-01,
1.42336752e+00, 2.84817590e+00, 2.51501115e+00, 3.82833334e-01,
1.34166825e+00, 8.66819847e-01, 2.57091346e+00, 2.61077232e+00,
7.85519913e-01, 2.70379184e+00, 2.20450420e+00, 1.89147421e+00,
1.02292882e+00, 3.57110744e+00, 1.15229707e+00, 1.19925144e+00,
8.27636321e-01, 4.46489327e-01, 4.98563900e-02, 1.07652379e+00,
2.46771725e-01, 2.69058611e+00, 3.40088155e+00, 4.45012094e+00,
1.57161448e+00, 9.64447987e-01, 8.14071375e-01, 9.48421314e-01,
3.03122983e+00, 5.69390156e-01, 2.28679780e-01, 7.48853728e-01,
2.69022286e+00, 1.86937729e-01, 2.87869004e+00, 1.32278217e+00])
* defs
(team, sample)
float64
-0.003092 0.2726 ... -1.412 -0.3131
array([[-3.09179024e-03, 2.72570341e-01, -2.18760328e-01, ...,
4.38152371e-02, -1.03437229e+00, -3.97338166e+00],
[ 2.01365891e-03, -4.15791536e-01, -3.67484861e-01, ...,
-2.10827978e-02, 2.62486870e+00, 1.06416996e+00],
[ 4.35137550e-03, -6.81952437e-02, -2.95711882e-01, ...,
-1.08161510e-01, -1.89319247e+00, 1.50133973e+00],
[ 1.19550750e-02, 2.54996511e-01, -1.61932686e+00, ...,
2.05526307e-01, 5.17614166e-01, 2.06652009e+00],
[-5.18010208e-03, 2.34591026e-01, 3.32208460e-01, ...,
-2.00045397e-01, 1.19748838e+00, -3.45545983e-01],
[-1.00482171e-02, -2.78171099e-01, 2.16907547e+00, ...,
7.99481607e-02, -1.41240648e+00, -3.13102125e-01]],
shape=(6, 500))
* intercept
(sample)
float64
1.172 3.866 2.439 ... 1.964 3.91
array([1.17171239, 3.86583539, 2.4391407 , 4.32375204, 4.1286731 ,
3.74389792, 2.32573896, 2.98106485, 4.22407409, 2.9102616 ,
2.81718585, 1.68395292, 2.53203057, 4.06034408, 3.98738926,
2.85474106, 5.80544728, 4.22797526, 2.01281423, 3.11958143,
2.02967296, 1.42041195, 1.52309998, 2.14085323, 2.80980621,
4.20356678, 4.36770697, 2.7701203 , 2.39197921, 4.72827613,
0.40895562, 0.68277932, 3.58754184, 3.01605691, 1.85861561,
2.46897923, 3.07434029, 4.79042202, 2.55829205, 3.08326682,
2.64343737, 2.93699907, 2.50526724, 2.10879168, 3.4822721 ,
4.11493029, 3.45049648, 3.81184193, 1.48230072, 2.7676012 ,
3.26422772, 6.2515801 , 2.97717842, 2.90682505, 0.61380645,
2.85194313, 2.51945318, 3.75241041, 2.74363401, 1.99825538,
1.72570557, 4.43276744, 3.286882 , 3.77154885, 3.72282446,
2.92992585, 3.14756233, 3.21077627, 2.37438185, 4.61198055,
2.2579503 , 4.22552193, 4.62147322, 2.43178186, 2.75424586,
2.05810517, 2.22095274, 2.81775414, 3.85760253, 1.81645922,
3.07797286, 3.10042588, 2.82731732, 2.76451102, 2.31603012,
2.09191251, 2.94787639, 3.41267728, 4.01540851, 1.68395962,
3.90255824, 3.51311609, 3.22077668, 3.55564564, 2.92992175,
4.13916929, 3.23918315, 4.73701308, 1.72554215, 3.64632833,
...
3.53385238, 3.96400821, 1.59826907, 3.02219264, 3.52326279,
3.65393681, 2.45093271, 3.48781452, 3.91658352, 2.34613589,
3.25259703, 3.17015047, 3.16667979, 2.67807086, 2.11603546,
2.49445479, 3.36514445, 3.75312481, 2.68802181, 3.56311092,
2.7881923 , 2.9298901 , 4.89720667, 2.42971259, 0.6225873 ,
2.5592003 , 1.85744705, 2.03308382, 3.31768733, 2.98958866,
3.91387202, 2.71859076, 1.2710949 , 3.32276425, 2.2595055 ,
3.1399085 , 1.02458187, 4.31634952, 2.52474757, 3.40448384,
2.56946285, 1.25752335, 3.24101351, 3.27148997, 3.04600494,
3.16909178, 0.96050023, 3.53995877, 1.77620765, 1.23913768,
3.79689061, 3.70796826, 4.01779955, 2.06952169, 1.78845668,
3.17405391, 3.35729718, 2.96860437, 2.48589282, 2.98871897,
2.79074732, 3.64750211, 4.79004281, 3.54907512, 4.3702815 ,
2.90392028, 4.67571219, 1.46078942, 2.96804312, 1.20384525,
2.39910022, 2.09806161, 1.5094592 , 2.96057022, 2.27529829,
2.5121504 , 3.2614401 , 1.94623525, 0.83043339, 2.35074068,
2.48219628, 1.91499112, 3.48524605, 1.41089192, 3.36072859,
1.34145238, 3.84084014, 2.27439918, 2.7224286 , 0.49485186,
3.27505445, 5.00079215, 1.55284319, 3.5372571 , 2.72486107,
3.12746627, 3.91281913, 2.06583832, 1.9641772 , 3.90958519])
* home
(sample)
float64
0.694 -0.6541 ... -2.354 -0.9812
array([ 6.94019010e-01, -6.54148558e-01, 4.19842561e-01, 4.52357938e-01,
1.67550552e+00, -5.84746186e-01, 3.99672486e-01, -3.59981861e-01,
-1.11943989e+00, -7.95849191e-01, -3.57524302e-01, 3.29908818e-01,
1.99050029e-01, -3.07320362e-01, 3.70982655e-01, -1.05024933e+00,
-3.86374347e-02, -2.87432993e-01, -3.99584991e-01, -7.54360970e-01,
-3.91055952e-01, 1.12648177e+00, 1.13782005e+00, -1.46756030e+00,
-6.23270594e-02, 5.93762667e-01, 6.89766188e-01, 6.58529125e-01,
2.53887470e+00, 7.37861043e-01, 1.52153875e+00, 5.25128792e-01,
6.08288741e-01, -5.20176254e-01, -4.07548322e-01, 3.12436660e-01,
5.72089182e-01, 9.10113563e-01, -2.38647462e-01, -1.93274333e+00,
1.33329493e+00, 1.26708569e+00, -2.60312405e-01, -2.09408981e-01,
6.22058381e-02, 1.62274770e+00, 1.85078925e+00, 1.57478535e+00,
3.54022119e-01, -2.90073123e+00, 2.60361790e-01, 3.50491879e-01,
6.55884293e-01, 1.08391449e+00, -9.71724147e-01, -1.17649262e-02,
-1.15137538e+00, -2.36670807e-01, -4.57763530e-01, -4.91458310e-01,
-7.80519532e-01, 9.18468164e-01, 1.63882355e+00, 3.64047913e-01,
9.49077393e-01, 2.57647408e-01, 1.10007503e+00, 2.20467011e-01,
-1.03676813e+00, -1.75840956e+00, -2.09426074e+00, 1.28916484e+00,
-1.00717848e-01, 1.29897321e+00, -1.00966990e+00, -7.29720030e-01,
-1.75303437e+00, -2.12672019e+00, -1.63778876e-01, -1.23038514e+00,
...
-6.72959667e-02, 1.18979647e+00, -5.70906964e-01, -5.33422753e-01,
5.57313743e-01, -3.40242094e-01, -7.71339059e-01, -1.64795159e+00,
3.23364432e-01, 4.19636745e-01, 1.39218545e-01, -6.32296490e-01,
1.75360522e+00, 3.17069405e-01, 8.67574665e-02, -8.02138964e-02,
-5.44626504e-01, 5.36624284e-01, -1.85674227e+00, 4.25120657e-01,
1.91597769e+00, 1.64710250e+00, 2.05062708e+00, -1.29138648e+00,
-1.13081138e+00, 1.71825699e+00, -1.17901610e+00, -2.18266184e+00,
2.80710902e-01, 8.47230767e-01, -9.98070398e-01, -2.52323036e-03,
1.27236263e+00, -4.28748136e-01, -4.78389814e-01, -2.57618292e-01,
-2.55398216e+00, 1.80280969e+00, 7.18542414e-02, 5.47958885e-01,
-1.41942776e-01, -1.00989963e+00, 9.56037099e-01, 8.61350999e-01,
1.39643843e+00, -4.31247252e-02, 1.45207993e+00, 1.38669486e+00,
2.11155213e+00, 6.11025889e-01, -5.52734558e-01, -3.64507848e-01,
-3.24557156e-01, 7.45261023e-02, -3.58371929e-01, -2.10579902e+00,
-4.98694010e-01, 4.41669667e-01, 1.13863989e+00, -7.64166652e-01,
-8.50958376e-01, -1.43011392e-01, 1.72559628e+00, -7.07022925e-01,
-3.65693218e-01, 8.25774096e-01, -5.77786876e-01, 1.95009045e-02,
-2.23607989e-01, 1.03349878e-01, 3.35059332e-01, -4.08040135e-02,
-5.83919972e-02, -1.29612438e+00, -1.43773047e+00, 2.74426161e-01,
-7.68347576e-01, 8.67820090e-01, -2.35387516e+00, -9.81185863e-01])
* defs_star
(team, sample)
float64
0.003231 0.4705 ... 0.001565
array([[ 3.23118332e-03, 4.70545390e-01, 1.34030478e-01, ...,
-7.30740868e-02, -3.22607494e-01, -3.65871420e+00],
[ 8.33663246e-03, -2.17816488e-01, -1.46940552e-02, ...,
-1.37972122e-01, 3.33663350e+00, 1.37883742e+00],
[ 1.06743491e-02, 1.29779805e-01, 5.70789234e-02, ...,
-2.25050834e-01, -1.18142767e+00, 1.81600719e+00],
[ 1.82780486e-02, 4.52971559e-01, -1.26653605e+00, ...,
8.86369828e-02, 1.22937897e+00, 2.38118755e+00],
[ 1.14287147e-03, 4.32566074e-01, 6.84999266e-01, ...,
-3.16934721e-01, 1.90925318e+00, -3.08785186e-02],
[-3.72524356e-03, -8.01960503e-02, 2.52186627e+00, ...,
-3.69411632e-02, -7.00641675e-01, 1.56533900e-03]],
shape=(6, 500)) - Indexes: (2)
* PandasIndex
PandasIndex(Index(['Wales', 'France', 'Ireland', 'Scotland', 'Italy', 'England'], dtype='object', name='team'))
* PandasMultiIndex
PandasIndex(MultiIndex([(0, 0),
(0, 1),
(0, 2),
(0, 3),
(0, 4),
(0, 5),
(0, 6),
(0, 7),
(0, 8),
(0, 9),
...
(0, 490),
(0, 491),
(0, 492),
(0, 493),
(0, 494),
(0, 495),
(0, 496),
(0, 497),
(0, 498),
(0, 499)],
name='sample', length=500)) - Attributes: (4)
created_at :
2024-03-06T20:46:09.475945
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- prior_predictive
<xarray.Dataset> Size: 500kB
Dimensions: (match: 60, sample: 500)
Coordinates:- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
home_team (match) <U8 2kB ...
away_team (match) <U8 2kB ... - sample (sample) object 4kB MultiIndex
- chain (sample) int64 4kB 0 0 0 0 0 0 0 0 0 0 ... 0 0 0 0 0 0 0 0 0 0
- draw (sample) int64 4kB 0 1 2 3 4 5 6 ... 494 495 496 497 498 499
Data variables:
away_points (match, sample) int64 240kB 135 51 9 27 4 4 ... 27 139 23 6 351
home_points (match, sample) int64 240kB 6 22 16 253 78 136 ... 30 801 5 0 1
Attributes:
created_at: 2024-03-06T20:46:09.479330
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* match: 60
* sample: 500 - Coordinates: (6)
* match
(match)
<U16
'Wales Italy' ... 'Ireland England'
array(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'], dtype='<U16')
* home_team
(match)
<U8
...
[60 values with dtype=<U8]
* away_team
(match)
<U8
...
[60 values with dtype=<U8]
* sample
(sample)
object
MultiIndex
array([(0, 0), (0, 1), (0, 2), ..., (0, 497), (0, 498), (0, 499)],
shape=(202,), dtype=object)
* chain
(sample)
int64
0 0 0 0 0 0 0 0 ... 0 0 0 0 0 0 0 0
array([0, 0, 0, ..., 0, 0, 0], shape=(202,))
* draw
(sample)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(202,)) - Data variables: (2)
* away_points
(match, sample)
int64
135 51 9 27 4 4 ... 27 139 23 6 351
array([[ 135, 51, 9, ..., 3, 1, 0],
[ 0, 25, 13, ..., 23, 305, 208],
[ 0, 91, 3, ..., 23, 3, 6609],
...,
[ 159, 69, 2, ..., 1, 2, 130],
[ 2, 23, 4, ..., 6, 27, 67],
[ 1, 34, 16, ..., 23, 6, 351]], shape=(60, 500))
* home_points
(match, sample)
int64
6 22 16 253 78 136 ... 30 801 5 0 1
array([[ 6, 22, 16, ..., 16, 0, 7],
[ 2, 26, 162, ..., 21, 0, 64],
[ 6, 10, 9, ..., 15, 1, 1],
...,
[ 1, 74, 21, ..., 49, 4, 403],
[ 0, 51, 17, ..., 21, 0, 1],
[ 7, 8, 358, ..., 5, 0, 1]], shape=(60, 500)) - Indexes: (2)
* PandasIndex
PandasIndex(Index(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'],
dtype='object', name='match'))
* PandasMultiIndex
PandasIndex(MultiIndex([(0, 0),
(0, 1),
(0, 2),
(0, 3),
(0, 4),
(0, 5),
(0, 6),
(0, 7),
(0, 8),
(0, 9),
...
(0, 490),
(0, 491),
(0, 492),
(0, 493),
(0, 494),
(0, 495),
(0, 496),
(0, 497),
(0, 498),
(0, 499)],
name='sample', length=500)) - Attributes: (4)
created_at :
2024-03-06T20:46:09.479330
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
- observed_data
<xarray.Dataset> Size: 9kB
Dimensions: (match: 60)
Coordinates:- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
home_team (match) <U8 2kB ...
away_team (match) <U8 2kB ...
Data variables:
home_points (match) int64 480B ...
away_points (match) int64 480B ...
Attributes:
created_at: 2024-03-06T20:46:09.480812
arviz_version: 0.17.0
inference_library: pymc
inference_library_version: 5.10.4+7.g34d2a5d9- Dimensions:
* match: 60 - Coordinates: (3)
* match
(match)
<U16
'Wales Italy' ... 'Ireland England'
array(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'], dtype='<U16')
* home_team
(match)
<U8
...
[60 values with dtype=<U8]
* away_team
(match)
<U8
...
[60 values with dtype=<U8] - Data variables: (2)
* home_points
(match)
int64
...
[60 values with dtype=int64]
* away_points
(match)
int64
...
[60 values with dtype=int64] - Indexes: (1)
* PandasIndex
PandasIndex(Index(['Wales Italy', 'France England', 'Ireland Scotland', 'Ireland Wales',
'Scotland England', 'France Italy', 'Wales France', 'Italy Scotland',
'England Ireland', 'Ireland Italy', 'Scotland France', 'England Wales',
'Italy England', 'Wales Scotland', 'France Ireland', 'Wales England',
'Italy Ireland', 'France Scotland', 'England Italy', 'Ireland France',
'Scotland Wales', 'Scotland Italy', 'France Wales', 'Ireland England',
'Wales Ireland', 'England Scotland', 'Italy France', 'Italy Wales',
'Scotland Ireland', 'England France', 'France Italy',
'Scotland England', 'Ireland Wales', 'France Ireland', 'Wales Scotland',
'Italy England', 'Wales France', 'Italy Scotland', 'England Ireland',
'Ireland Italy', 'England Wales', 'Scotland France', 'Wales Italy',
'Ireland Scotland', 'France England', 'Scotland Ireland',
'England France', 'Italy Wales', 'Italy Ireland', 'Wales England',
'France Scotland', 'Scotland Wales', 'Ireland France', 'England Italy',
'Wales Ireland', 'Italy France', 'England Scotland', 'Scotland Italy',
'France Wales', 'Ireland England'],
dtype='object', name='match')) - Attributes: (4)
created_at :
2024-03-06T20:46:09.480812
arviz_version :
0.17.0
inference_library :
pymc
inference_library_version :
5.10.4+7.g34d2a5d9
- Dimensions:
- match (match) <U16 4kB 'Wales Italy' ... 'Ireland England'
- unconstrained_posterior
<xarray.Dataset> Size: 80kB
Dimensions: (sample: 2000)
Coordinates:- sample (sample) object 16kB MultiIndex
- chain (sample) int64 16kB 0 0 0 0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3 3 3 3
- draw (sample) int64 16kB 0 1 2 3 4 5 6 7 ... 493 494 495 496 497 498 499
Data variables:
sd_att (sample) float64 16kB -1.189 -1.834 -1.627 ... -0.9111 -1.217
sd_def (sample) float64 16kB -0.5553 -0.7182 -1.126 ... -1.083 -1.028
Attributes:
sd_att: pymc.logprob.transforms.LogTransform
sd_def: pymc.logprob.transforms.LogTransform- Dimensions:
* sample: 2000 - Coordinates: (3)
* sample
(sample)
object
MultiIndex
array([(0, 0), (0, 1), (0, 2), ..., (3, 497), (3, 498), (3, 499)],
shape=(202,), dtype=object)
* chain
(sample)
int64
0 0 0 0 0 0 0 0 ... 3 3 3 3 3 3 3 3
array([0, 0, 0, ..., 3, 3, 3], shape=(202,))
* draw
(sample)
int64
0 1 2 3 4 5 ... 495 496 497 498 499
array([ 0, 1, 2, ..., 497, 498, 499], shape=(202,)) - Data variables: (2)
* sd_att
(sample)
float64
-1.189 -1.834 ... -0.9111 -1.217
array([-1.18856396, -1.83405005, -1.62695054, ..., -1.18462054,
-0.91113177, -1.21687368], shape=(2000,))
* sd_def
(sample)
float64
-0.5553 -0.7182 ... -1.083 -1.028
array([-0.55534141, -0.7182 , -1.12636337, ..., -0.62321195,
-1.083444 , -1.02832568], shape=(2000,)) - Indexes: (1)
* PandasMultiIndex
PandasIndex(MultiIndex([(0, 0),
(0, 1),
(0, 2),
(0, 3),
(0, 4),
(0, 5),
(0, 6),
(0, 7),
(0, 8),
(0, 9),
...
(3, 490),
(3, 491),
(3, 492),
(3, 493),
(3, 494),
(3, 495),
(3, 496),
(3, 497),
(3, 498),
(3, 499)],
name='sample', length=2000)) - Attributes: (2)
sd_att :
pymc.logprob.transforms.LogTransform
sd_def :
pymc.logprob.transforms.LogTransform
- Dimensions:
We can also take the example of custom InferenceData object and perform stacking. We first check the original object:
import numpy as np datadict = { "a": np.random.randn(100), "b": np.random.randn(1, 100, 10), "c": np.random.randn(1, 100, 3, 4), } coords = { "c1": np.arange(3), "c99": np.arange(4), "b1": np.arange(10), } dims = {"c": ["c1", "c99"], "b": ["b1"]} idata = az.from_dict( posterior=datadict, posterior_predictive=datadict, coords=coords, dims=dims ) idata
- posterior
<xarray.Dataset> Size: 19kB
Dimensions: (chain: 1, draw: 100, b1: 10, c1: 3, c99: 4)
Coordinates:- chain (chain) int64 8B 0
- draw (draw) int64 800B 0 1 2 3 4 5 6 7 8 ... 91 92 93 94 95 96 97 98 99
- b1 (b1) int64 80B 0 1 2 3 4 5 6 7 8 9
- c1 (c1) int64 24B 0 1 2
- c99 (c99) int64 32B 0 1 2 3
Data variables:
a (chain, draw) float64 800B -0.1643 1.18 -1.347 ... 0.4539 -0.8778
b (chain, draw, b1) float64 8kB 1.696 0.1047 1.211 ... 1.607 -0.0572
c (chain, draw, c1, c99) float64 10kB 1.02 -0.09153 ... 1.3 1.734
Attributes:
created_at: 2025-05-27T21:35:35.819181+00:00
arviz_version: 0.22.0dev- Dimensions:
* chain: 1
* draw: 100
* b1: 10
* c1: 3
* c99: 4 - Coordinates: (5)
* chain
(chain)
int64
0
* draw
(draw)
int64
0 1 2 3 4 5 6 ... 94 95 96 97 98 99
array([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
90, 91, 92, 93, 94, 95, 96, 97, 98, 99])
* b1
(b1)
int64
0 1 2 3 4 5 6 7 8 9
array([0, 1, 2, 3, 4, 5, 6, 7, 8, 9])
* c1
(c1)
int64
0 1 2
* c99
(c99)
int64
0 1 2 3 - Data variables: (3)
* a
(chain, draw)
float64
-0.1643 1.18 ... 0.4539 -0.8778
array([[-1.64337112e-01, 1.18022198e+00, -1.34733719e+00,
-3.72781810e-01, -8.18628165e-01, 3.39167473e-01,
1.64863089e-01, -4.86669357e-01, 5.35002327e-01,
-5.90108328e-01, 6.95425025e-01, 9.77257286e-02,
2.26259255e+00, -1.45365830e+00, 1.08807712e+00,
8.72649242e-01, -8.13468833e-01, 8.39674024e-02,
2.20972796e+00, -2.63045779e-01, 9.10468729e-01,
-1.89883943e+00, 7.88436714e-01, 3.25469519e-01,
1.79309990e+00, -4.67883817e-01, -6.06762539e-01,
1.05996562e+00, 4.23818110e-01, 2.39140091e+00,
-6.58259253e-01, -8.19440731e-01, -2.03974806e+00,
-5.50153468e-01, -2.36133015e-01, -2.94042405e-01,
-7.56098388e-01, 7.23520374e-01, -3.32568458e-01,
5.64862273e-01, 1.46675148e+00, 5.18017800e-01,
-5.47257197e-01, 5.33251310e-01, 2.33339532e-02,
-7.44779219e-01, 9.99232927e-01, 2.76748301e-01,
1.14762727e+00, -1.79526711e+00, -2.87826885e-01,
1.59194643e+00, -5.46252956e-01, -4.76843244e-01,
-1.09824481e+00, -1.09595516e+00, 4.79611936e-04,
1.06752104e+00, -1.67514298e+00, 1.04101934e+00,
2.36828530e-01, 2.73031895e+00, -5.37807760e-01,
-4.33645487e-02, 1.84944198e+00, -5.42036272e-01,
7.20131490e-01, 4.92702293e-01, -8.08618142e-01,
-1.15969569e+00, -1.32070816e+00, 3.38147026e-02,
-5.76603254e-02, -6.93937990e-01, 2.90070348e-01,
-1.82008708e-01, -4.76733990e-01, -5.34391354e-01,
-1.50889079e+00, -1.49271627e-01, -3.45896946e-01,
-5.75411044e-01, -1.13695758e+00, -3.48621257e-01,
2.40566361e+00, 2.67957130e-02, 8.96894511e-02,
-2.30096753e+00, -1.44202583e+00, -1.59118343e-01,
4.34856330e-01, 5.35078937e-01, -5.86859628e-01,
7.03717074e-01, 1.19557356e+00, 4.00185620e-01,
-3.39890378e-01, -1.02871333e-01, 4.53903550e-01,
-8.77757837e-01]])
* b
(chain, draw, b1)
float64
1.696 0.1047 ... 1.607 -0.0572
array([[[ 1.69622399e+00, 1.04657753e-01, 1.21057271e+00,
1.05419101e-01, 1.22957627e+00, -2.18771245e+00,
-1.56297701e-01, 4.40929172e-01, 3.66977376e-01,
-1.21647030e+00],
[-7.15657223e-01, -1.47688903e+00, 5.22428269e-02,
1.03170031e+00, -3.57293865e-01, -1.79904293e+00,
9.38578217e-01, -4.42798510e-01, -5.08143662e-01,
3.34803599e-02],
[-1.39319486e-01, 1.20914733e+00, 9.21036002e-01,
2.95863627e-01, -3.02004547e-01, 4.87745637e-01,
-6.32226004e-01, -4.65638379e-01, 7.53420553e-01,
9.67359099e-01],
[ 1.56340412e+00, -1.50111874e+00, 3.48906921e-02,
-1.11667262e+00, 2.85433459e-01, -1.06549585e+00,
-1.14267158e-01, 9.30395980e-01, 6.59490581e-01,
-1.23604807e+00],
[-9.39019716e-02, 1.97779994e+00, 1.11966716e-01,
7.49063752e-01, 1.15612290e+00, 1.26183133e+00,
2.15900082e-01, 9.79341494e-01, -3.63591725e-01,
-4.01937103e-01],
...
[-1.68381630e+00, 8.21936974e-01, 3.59054585e-02,
2.68666820e-01, 1.20226024e+00, -6.42531089e-01,
1.37912909e+00, -1.70637172e+00, -1.17390525e+00,
1.20923869e+00],
[-1.79643258e+00, 1.47154486e-02, -1.16183081e+00,
8.43020107e-01, -2.13821384e-01, 7.83402761e-01,
1.10558046e+00, -1.60943629e+00, 1.29225004e+00,
2.73645038e-01],
[ 1.12258686e-01, -3.64928878e-01, 1.04349729e+00,
1.11002098e+00, -8.33764798e-01, -7.42510407e-01,
5.03180502e-01, -6.73937507e-01, 5.79945121e-01,
1.53785798e+00],
[-5.29799229e-01, -1.52448401e+00, -6.86830114e-01,
6.96936049e-01, 3.09533503e-01, 1.48660760e-01,
-2.08300629e-02, -1.06856903e+00, -1.90334596e+00,
9.92786055e-01],
[ 1.94489963e+00, -5.24953096e-01, -5.87997600e-01,
1.29295581e+00, -1.45536431e+00, -1.83659253e+00,
-2.40957150e-01, -8.47449716e-01, 1.60735032e+00,
-5.71976673e-02]]])
* c
(chain, draw, c1, c99)
float64
1.02 -0.09153 -0.3396 ... 1.3 1.734
array([[[[ 1.02018057, -0.09152686, -0.33959092, 0.98862403],
[-1.03015755, -0.30363675, -0.1147289 , 0.82062441],
[ 0.20181273, 1.15506305, 0.27756728, -1.42368563]],
[[ 0.27015438, 0.63622663, -2.10143742, -1.44689103],
[ 0.53071246, -1.21709015, 1.08428844, -2.55120729],
[ 3.67377337, 0.41161292, 0.70490801, 0.09042747]],
[[ 0.95493779, -0.44125074, 0.6315446 , 0.40766217],
[-0.02912943, 0.16848022, -0.94438685, -0.71265235],
[ 0.07344157, 0.22894178, -0.9702002 , -1.36738857]],
...,
[[-0.1075326 , 1.11405442, 0.40301183, -0.61516205],
[ 0.22498038, 0.70014731, 0.81970756, -0.82652419],
[ 0.35406283, 0.49983112, -0.28102153, 0.5794615 ]],
[[ 1.40461536, 0.5993807 , 0.72138274, 0.38791961],
[-0.05885267, -0.61909746, 0.27673758, 1.02527594],
[-1.55100557, -0.13959598, -0.3725852 , 1.09185991]],
[[-0.56560533, 0.12719073, -1.1408518 , 0.53581176],
[ 0.3194776 , -1.76876948, -0.21382982, 0.03479091],
[-0.50675347, 0.2201536 , 1.30023644, 1.7344667 ]]]],
shape=(1, 100, 3, 4)) - Indexes: (5)
* PandasIndex
PandasIndex(Index([0], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
90, 91, 92, 93, 94, 95, 96, 97, 98, 99],
dtype='int64', name='draw'))
* PandasIndex
PandasIndex(Index([0, 1, 2, 3, 4, 5, 6, 7, 8, 9], dtype='int64', name='b1'))
* PandasIndex
PandasIndex(Index([0, 1, 2], dtype='int64', name='c1'))
* PandasIndex
PandasIndex(Index([0, 1, 2, 3], dtype='int64', name='c99')) - Attributes: (2)
created_at :
2025-05-27T21:35:35.819181+00:00
arviz_version :
0.22.0dev
- Dimensions:
- posterior_predictive
<xarray.Dataset> Size: 19kB
Dimensions: (chain: 1, draw: 100, b1: 10, c1: 3, c99: 4)
Coordinates:- chain (chain) int64 8B 0
- draw (draw) int64 800B 0 1 2 3 4 5 6 7 8 ... 91 92 93 94 95 96 97 98 99
- b1 (b1) int64 80B 0 1 2 3 4 5 6 7 8 9
- c1 (c1) int64 24B 0 1 2
- c99 (c99) int64 32B 0 1 2 3
Data variables:
a (chain, draw) float64 800B -0.1643 1.18 -1.347 ... 0.4539 -0.8778
b (chain, draw, b1) float64 8kB 1.696 0.1047 1.211 ... 1.607 -0.0572
c (chain, draw, c1, c99) float64 10kB 1.02 -0.09153 ... 1.3 1.734
Attributes:
created_at: 2025-05-27T21:35:35.821269+00:00
arviz_version: 0.22.0dev- Dimensions:
* chain: 1
* draw: 100
* b1: 10
* c1: 3
* c99: 4 - Coordinates: (5)
* chain
(chain)
int64
0
* draw
(draw)
int64
0 1 2 3 4 5 6 ... 94 95 96 97 98 99
array([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
90, 91, 92, 93, 94, 95, 96, 97, 98, 99])
* b1
(b1)
int64
0 1 2 3 4 5 6 7 8 9
array([0, 1, 2, 3, 4, 5, 6, 7, 8, 9])
* c1
(c1)
int64
0 1 2
* c99
(c99)
int64
0 1 2 3 - Data variables: (3)
* a
(chain, draw)
float64
-0.1643 1.18 ... 0.4539 -0.8778
array([[-1.64337112e-01, 1.18022198e+00, -1.34733719e+00,
-3.72781810e-01, -8.18628165e-01, 3.39167473e-01,
1.64863089e-01, -4.86669357e-01, 5.35002327e-01,
-5.90108328e-01, 6.95425025e-01, 9.77257286e-02,
2.26259255e+00, -1.45365830e+00, 1.08807712e+00,
8.72649242e-01, -8.13468833e-01, 8.39674024e-02,
2.20972796e+00, -2.63045779e-01, 9.10468729e-01,
-1.89883943e+00, 7.88436714e-01, 3.25469519e-01,
1.79309990e+00, -4.67883817e-01, -6.06762539e-01,
1.05996562e+00, 4.23818110e-01, 2.39140091e+00,
-6.58259253e-01, -8.19440731e-01, -2.03974806e+00,
-5.50153468e-01, -2.36133015e-01, -2.94042405e-01,
-7.56098388e-01, 7.23520374e-01, -3.32568458e-01,
5.64862273e-01, 1.46675148e+00, 5.18017800e-01,
-5.47257197e-01, 5.33251310e-01, 2.33339532e-02,
-7.44779219e-01, 9.99232927e-01, 2.76748301e-01,
1.14762727e+00, -1.79526711e+00, -2.87826885e-01,
1.59194643e+00, -5.46252956e-01, -4.76843244e-01,
-1.09824481e+00, -1.09595516e+00, 4.79611936e-04,
1.06752104e+00, -1.67514298e+00, 1.04101934e+00,
2.36828530e-01, 2.73031895e+00, -5.37807760e-01,
-4.33645487e-02, 1.84944198e+00, -5.42036272e-01,
7.20131490e-01, 4.92702293e-01, -8.08618142e-01,
-1.15969569e+00, -1.32070816e+00, 3.38147026e-02,
-5.76603254e-02, -6.93937990e-01, 2.90070348e-01,
-1.82008708e-01, -4.76733990e-01, -5.34391354e-01,
-1.50889079e+00, -1.49271627e-01, -3.45896946e-01,
-5.75411044e-01, -1.13695758e+00, -3.48621257e-01,
2.40566361e+00, 2.67957130e-02, 8.96894511e-02,
-2.30096753e+00, -1.44202583e+00, -1.59118343e-01,
4.34856330e-01, 5.35078937e-01, -5.86859628e-01,
7.03717074e-01, 1.19557356e+00, 4.00185620e-01,
-3.39890378e-01, -1.02871333e-01, 4.53903550e-01,
-8.77757837e-01]])
* b
(chain, draw, b1)
float64
1.696 0.1047 ... 1.607 -0.0572
array([[[ 1.69622399e+00, 1.04657753e-01, 1.21057271e+00,
1.05419101e-01, 1.22957627e+00, -2.18771245e+00,
-1.56297701e-01, 4.40929172e-01, 3.66977376e-01,
-1.21647030e+00],
[-7.15657223e-01, -1.47688903e+00, 5.22428269e-02,
1.03170031e+00, -3.57293865e-01, -1.79904293e+00,
9.38578217e-01, -4.42798510e-01, -5.08143662e-01,
3.34803599e-02],
[-1.39319486e-01, 1.20914733e+00, 9.21036002e-01,
2.95863627e-01, -3.02004547e-01, 4.87745637e-01,
-6.32226004e-01, -4.65638379e-01, 7.53420553e-01,
9.67359099e-01],
[ 1.56340412e+00, -1.50111874e+00, 3.48906921e-02,
-1.11667262e+00, 2.85433459e-01, -1.06549585e+00,
-1.14267158e-01, 9.30395980e-01, 6.59490581e-01,
-1.23604807e+00],
[-9.39019716e-02, 1.97779994e+00, 1.11966716e-01,
7.49063752e-01, 1.15612290e+00, 1.26183133e+00,
2.15900082e-01, 9.79341494e-01, -3.63591725e-01,
-4.01937103e-01],
...
[-1.68381630e+00, 8.21936974e-01, 3.59054585e-02,
2.68666820e-01, 1.20226024e+00, -6.42531089e-01,
1.37912909e+00, -1.70637172e+00, -1.17390525e+00,
1.20923869e+00],
[-1.79643258e+00, 1.47154486e-02, -1.16183081e+00,
8.43020107e-01, -2.13821384e-01, 7.83402761e-01,
1.10558046e+00, -1.60943629e+00, 1.29225004e+00,
2.73645038e-01],
[ 1.12258686e-01, -3.64928878e-01, 1.04349729e+00,
1.11002098e+00, -8.33764798e-01, -7.42510407e-01,
5.03180502e-01, -6.73937507e-01, 5.79945121e-01,
1.53785798e+00],
[-5.29799229e-01, -1.52448401e+00, -6.86830114e-01,
6.96936049e-01, 3.09533503e-01, 1.48660760e-01,
-2.08300629e-02, -1.06856903e+00, -1.90334596e+00,
9.92786055e-01],
[ 1.94489963e+00, -5.24953096e-01, -5.87997600e-01,
1.29295581e+00, -1.45536431e+00, -1.83659253e+00,
-2.40957150e-01, -8.47449716e-01, 1.60735032e+00,
-5.71976673e-02]]])
* c
(chain, draw, c1, c99)
float64
1.02 -0.09153 -0.3396 ... 1.3 1.734
array([[[[ 1.02018057, -0.09152686, -0.33959092, 0.98862403],
[-1.03015755, -0.30363675, -0.1147289 , 0.82062441],
[ 0.20181273, 1.15506305, 0.27756728, -1.42368563]],
[[ 0.27015438, 0.63622663, -2.10143742, -1.44689103],
[ 0.53071246, -1.21709015, 1.08428844, -2.55120729],
[ 3.67377337, 0.41161292, 0.70490801, 0.09042747]],
[[ 0.95493779, -0.44125074, 0.6315446 , 0.40766217],
[-0.02912943, 0.16848022, -0.94438685, -0.71265235],
[ 0.07344157, 0.22894178, -0.9702002 , -1.36738857]],
...,
[[-0.1075326 , 1.11405442, 0.40301183, -0.61516205],
[ 0.22498038, 0.70014731, 0.81970756, -0.82652419],
[ 0.35406283, 0.49983112, -0.28102153, 0.5794615 ]],
[[ 1.40461536, 0.5993807 , 0.72138274, 0.38791961],
[-0.05885267, -0.61909746, 0.27673758, 1.02527594],
[-1.55100557, -0.13959598, -0.3725852 , 1.09185991]],
[[-0.56560533, 0.12719073, -1.1408518 , 0.53581176],
[ 0.3194776 , -1.76876948, -0.21382982, 0.03479091],
[-0.50675347, 0.2201536 , 1.30023644, 1.7344667 ]]]],
shape=(1, 100, 3, 4)) - Indexes: (5)
* PandasIndex
PandasIndex(Index([0], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
90, 91, 92, 93, 94, 95, 96, 97, 98, 99],
dtype='int64', name='draw'))
* PandasIndex
PandasIndex(Index([0, 1, 2, 3, 4, 5, 6, 7, 8, 9], dtype='int64', name='b1'))
* PandasIndex
PandasIndex(Index([0, 1, 2], dtype='int64', name='c1'))
* PandasIndex
PandasIndex(Index([0, 1, 2, 3], dtype='int64', name='c99')) - Attributes: (2)
created_at :
2025-05-27T21:35:35.821269+00:00
arviz_version :
0.22.0dev
- Dimensions:
In order to stack two dimensions c1
and c99
to z
, we can use:
idata.stack(z=["c1", "c99"], inplace=True) idata
- posterior
<xarray.Dataset> Size: 20kB
Dimensions: (chain: 1, draw: 100, b1: 10, z: 12)
Coordinates:- chain (chain) int64 8B 0
- draw (draw) int64 800B 0 1 2 3 4 5 6 7 8 ... 91 92 93 94 95 96 97 98 99
- b1 (b1) int64 80B 0 1 2 3 4 5 6 7 8 9
- z (z) object 96B MultiIndex
- c1 (z) int64 96B 0 0 0 0 1 1 1 1 2 2 2 2
- c99 (z) int64 96B 0 1 2 3 0 1 2 3 0 1 2 3
Data variables:
a (chain, draw) float64 800B -0.1643 1.18 -1.347 ... 0.4539 -0.8778
b (chain, draw, b1) float64 8kB 1.696 0.1047 1.211 ... 1.607 -0.0572
c (chain, draw, z) float64 10kB 1.02 -0.09153 -0.3396 ... 1.3 1.734
Attributes:
created_at: 2025-05-27T21:35:35.819181+00:00
arviz_version: 0.22.0dev- Dimensions:
* chain: 1
* draw: 100
* b1: 10
* z: 12 - Coordinates: (6)
* chain
(chain)
int64
0
* draw
(draw)
int64
0 1 2 3 4 5 6 ... 94 95 96 97 98 99
array([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
90, 91, 92, 93, 94, 95, 96, 97, 98, 99])
* b1
(b1)
int64
0 1 2 3 4 5 6 7 8 9
array([0, 1, 2, 3, 4, 5, 6, 7, 8, 9])
* z
(z)
object
MultiIndex
array([(0, 0), (0, 1), (0, 2), (0, 3), (1, 0), (1, 1), (1, 2), (1, 3), (2, 0),
(2, 1), (2, 2), (2, 3)], dtype=object)
* c1
(z)
int64
0 0 0 0 1 1 1 1 2 2 2 2
array([0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2])
* c99
(z)
int64
0 1 2 3 0 1 2 3 0 1 2 3
array([0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 2, 3]) - Data variables: (3)
* a
(chain, draw)
float64
-0.1643 1.18 ... 0.4539 -0.8778
array([[-1.64337112e-01, 1.18022198e+00, -1.34733719e+00,
-3.72781810e-01, -8.18628165e-01, 3.39167473e-01,
1.64863089e-01, -4.86669357e-01, 5.35002327e-01,
-5.90108328e-01, 6.95425025e-01, 9.77257286e-02,
2.26259255e+00, -1.45365830e+00, 1.08807712e+00,
8.72649242e-01, -8.13468833e-01, 8.39674024e-02,
2.20972796e+00, -2.63045779e-01, 9.10468729e-01,
-1.89883943e+00, 7.88436714e-01, 3.25469519e-01,
1.79309990e+00, -4.67883817e-01, -6.06762539e-01,
1.05996562e+00, 4.23818110e-01, 2.39140091e+00,
-6.58259253e-01, -8.19440731e-01, -2.03974806e+00,
-5.50153468e-01, -2.36133015e-01, -2.94042405e-01,
-7.56098388e-01, 7.23520374e-01, -3.32568458e-01,
5.64862273e-01, 1.46675148e+00, 5.18017800e-01,
-5.47257197e-01, 5.33251310e-01, 2.33339532e-02,
-7.44779219e-01, 9.99232927e-01, 2.76748301e-01,
1.14762727e+00, -1.79526711e+00, -2.87826885e-01,
1.59194643e+00, -5.46252956e-01, -4.76843244e-01,
-1.09824481e+00, -1.09595516e+00, 4.79611936e-04,
1.06752104e+00, -1.67514298e+00, 1.04101934e+00,
2.36828530e-01, 2.73031895e+00, -5.37807760e-01,
-4.33645487e-02, 1.84944198e+00, -5.42036272e-01,
7.20131490e-01, 4.92702293e-01, -8.08618142e-01,
-1.15969569e+00, -1.32070816e+00, 3.38147026e-02,
-5.76603254e-02, -6.93937990e-01, 2.90070348e-01,
-1.82008708e-01, -4.76733990e-01, -5.34391354e-01,
-1.50889079e+00, -1.49271627e-01, -3.45896946e-01,
-5.75411044e-01, -1.13695758e+00, -3.48621257e-01,
2.40566361e+00, 2.67957130e-02, 8.96894511e-02,
-2.30096753e+00, -1.44202583e+00, -1.59118343e-01,
4.34856330e-01, 5.35078937e-01, -5.86859628e-01,
7.03717074e-01, 1.19557356e+00, 4.00185620e-01,
-3.39890378e-01, -1.02871333e-01, 4.53903550e-01,
-8.77757837e-01]])
* b
(chain, draw, b1)
float64
1.696 0.1047 ... 1.607 -0.0572
array([[[ 1.69622399e+00, 1.04657753e-01, 1.21057271e+00,
1.05419101e-01, 1.22957627e+00, -2.18771245e+00,
-1.56297701e-01, 4.40929172e-01, 3.66977376e-01,
-1.21647030e+00],
[-7.15657223e-01, -1.47688903e+00, 5.22428269e-02,
1.03170031e+00, -3.57293865e-01, -1.79904293e+00,
9.38578217e-01, -4.42798510e-01, -5.08143662e-01,
3.34803599e-02],
[-1.39319486e-01, 1.20914733e+00, 9.21036002e-01,
2.95863627e-01, -3.02004547e-01, 4.87745637e-01,
-6.32226004e-01, -4.65638379e-01, 7.53420553e-01,
9.67359099e-01],
[ 1.56340412e+00, -1.50111874e+00, 3.48906921e-02,
-1.11667262e+00, 2.85433459e-01, -1.06549585e+00,
-1.14267158e-01, 9.30395980e-01, 6.59490581e-01,
-1.23604807e+00],
[-9.39019716e-02, 1.97779994e+00, 1.11966716e-01,
7.49063752e-01, 1.15612290e+00, 1.26183133e+00,
2.15900082e-01, 9.79341494e-01, -3.63591725e-01,
-4.01937103e-01],
...
[-1.68381630e+00, 8.21936974e-01, 3.59054585e-02,
2.68666820e-01, 1.20226024e+00, -6.42531089e-01,
1.37912909e+00, -1.70637172e+00, -1.17390525e+00,
1.20923869e+00],
[-1.79643258e+00, 1.47154486e-02, -1.16183081e+00,
8.43020107e-01, -2.13821384e-01, 7.83402761e-01,
1.10558046e+00, -1.60943629e+00, 1.29225004e+00,
2.73645038e-01],
[ 1.12258686e-01, -3.64928878e-01, 1.04349729e+00,
1.11002098e+00, -8.33764798e-01, -7.42510407e-01,
5.03180502e-01, -6.73937507e-01, 5.79945121e-01,
1.53785798e+00],
[-5.29799229e-01, -1.52448401e+00, -6.86830114e-01,
6.96936049e-01, 3.09533503e-01, 1.48660760e-01,
-2.08300629e-02, -1.06856903e+00, -1.90334596e+00,
9.92786055e-01],
[ 1.94489963e+00, -5.24953096e-01, -5.87997600e-01,
1.29295581e+00, -1.45536431e+00, -1.83659253e+00,
-2.40957150e-01, -8.47449716e-01, 1.60735032e+00,
-5.71976673e-02]]])
* c
(chain, draw, z)
float64
1.02 -0.09153 -0.3396 ... 1.3 1.734
array([[[ 1.02018057, -0.09152686, -0.33959092, ..., 1.15506305,
0.27756728, -1.42368563],
[ 0.27015438, 0.63622663, -2.10143742, ..., 0.41161292,
0.70490801, 0.09042747],
[ 0.95493779, -0.44125074, 0.6315446 , ..., 0.22894178,
-0.9702002 , -1.36738857],
...,
[-0.1075326 , 1.11405442, 0.40301183, ..., 0.49983112,
-0.28102153, 0.5794615 ],
[ 1.40461536, 0.5993807 , 0.72138274, ..., -0.13959598,
-0.3725852 , 1.09185991],
[-0.56560533, 0.12719073, -1.1408518 , ..., 0.2201536 ,
1.30023644, 1.7344667 ]]], shape=(1, 100, 12)) - Indexes: (4)
* PandasIndex
PandasIndex(Index([0], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
90, 91, 92, 93, 94, 95, 96, 97, 98, 99],
dtype='int64', name='draw'))
* PandasIndex
PandasIndex(Index([0, 1, 2, 3, 4, 5, 6, 7, 8, 9], dtype='int64', name='b1'))
* PandasMultiIndex
PandasIndex(MultiIndex([(0, 0),
(0, 1),
(0, 2),
(0, 3),
(1, 0),
(1, 1),
(1, 2),
(1, 3),
(2, 0),
(2, 1),
(2, 2),
(2, 3)],
name='z')) - Attributes: (2)
created_at :
2025-05-27T21:35:35.819181+00:00
arviz_version :
0.22.0dev
- Dimensions:
- posterior_predictive
<xarray.Dataset> Size: 20kB
Dimensions: (chain: 1, draw: 100, b1: 10, z: 12)
Coordinates:- chain (chain) int64 8B 0
- draw (draw) int64 800B 0 1 2 3 4 5 6 7 8 ... 91 92 93 94 95 96 97 98 99
- b1 (b1) int64 80B 0 1 2 3 4 5 6 7 8 9
- z (z) object 96B MultiIndex
- c1 (z) int64 96B 0 0 0 0 1 1 1 1 2 2 2 2
- c99 (z) int64 96B 0 1 2 3 0 1 2 3 0 1 2 3
Data variables:
a (chain, draw) float64 800B -0.1643 1.18 -1.347 ... 0.4539 -0.8778
b (chain, draw, b1) float64 8kB 1.696 0.1047 1.211 ... 1.607 -0.0572
c (chain, draw, z) float64 10kB 1.02 -0.09153 -0.3396 ... 1.3 1.734
Attributes:
created_at: 2025-05-27T21:35:35.821269+00:00
arviz_version: 0.22.0dev- Dimensions:
* chain: 1
* draw: 100
* b1: 10
* z: 12 - Coordinates: (6)
* chain
(chain)
int64
0
* draw
(draw)
int64
0 1 2 3 4 5 6 ... 94 95 96 97 98 99
array([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
90, 91, 92, 93, 94, 95, 96, 97, 98, 99])
* b1
(b1)
int64
0 1 2 3 4 5 6 7 8 9
array([0, 1, 2, 3, 4, 5, 6, 7, 8, 9])
* z
(z)
object
MultiIndex
array([(0, 0), (0, 1), (0, 2), (0, 3), (1, 0), (1, 1), (1, 2), (1, 3), (2, 0),
(2, 1), (2, 2), (2, 3)], dtype=object)
* c1
(z)
int64
0 0 0 0 1 1 1 1 2 2 2 2
array([0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2])
* c99
(z)
int64
0 1 2 3 0 1 2 3 0 1 2 3
array([0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 2, 3]) - Data variables: (3)
* a
(chain, draw)
float64
-0.1643 1.18 ... 0.4539 -0.8778
array([[-1.64337112e-01, 1.18022198e+00, -1.34733719e+00,
-3.72781810e-01, -8.18628165e-01, 3.39167473e-01,
1.64863089e-01, -4.86669357e-01, 5.35002327e-01,
-5.90108328e-01, 6.95425025e-01, 9.77257286e-02,
2.26259255e+00, -1.45365830e+00, 1.08807712e+00,
8.72649242e-01, -8.13468833e-01, 8.39674024e-02,
2.20972796e+00, -2.63045779e-01, 9.10468729e-01,
-1.89883943e+00, 7.88436714e-01, 3.25469519e-01,
1.79309990e+00, -4.67883817e-01, -6.06762539e-01,
1.05996562e+00, 4.23818110e-01, 2.39140091e+00,
-6.58259253e-01, -8.19440731e-01, -2.03974806e+00,
-5.50153468e-01, -2.36133015e-01, -2.94042405e-01,
-7.56098388e-01, 7.23520374e-01, -3.32568458e-01,
5.64862273e-01, 1.46675148e+00, 5.18017800e-01,
-5.47257197e-01, 5.33251310e-01, 2.33339532e-02,
-7.44779219e-01, 9.99232927e-01, 2.76748301e-01,
1.14762727e+00, -1.79526711e+00, -2.87826885e-01,
1.59194643e+00, -5.46252956e-01, -4.76843244e-01,
-1.09824481e+00, -1.09595516e+00, 4.79611936e-04,
1.06752104e+00, -1.67514298e+00, 1.04101934e+00,
2.36828530e-01, 2.73031895e+00, -5.37807760e-01,
-4.33645487e-02, 1.84944198e+00, -5.42036272e-01,
7.20131490e-01, 4.92702293e-01, -8.08618142e-01,
-1.15969569e+00, -1.32070816e+00, 3.38147026e-02,
-5.76603254e-02, -6.93937990e-01, 2.90070348e-01,
-1.82008708e-01, -4.76733990e-01, -5.34391354e-01,
-1.50889079e+00, -1.49271627e-01, -3.45896946e-01,
-5.75411044e-01, -1.13695758e+00, -3.48621257e-01,
2.40566361e+00, 2.67957130e-02, 8.96894511e-02,
-2.30096753e+00, -1.44202583e+00, -1.59118343e-01,
4.34856330e-01, 5.35078937e-01, -5.86859628e-01,
7.03717074e-01, 1.19557356e+00, 4.00185620e-01,
-3.39890378e-01, -1.02871333e-01, 4.53903550e-01,
-8.77757837e-01]])
* b
(chain, draw, b1)
float64
1.696 0.1047 ... 1.607 -0.0572
array([[[ 1.69622399e+00, 1.04657753e-01, 1.21057271e+00,
1.05419101e-01, 1.22957627e+00, -2.18771245e+00,
-1.56297701e-01, 4.40929172e-01, 3.66977376e-01,
-1.21647030e+00],
[-7.15657223e-01, -1.47688903e+00, 5.22428269e-02,
1.03170031e+00, -3.57293865e-01, -1.79904293e+00,
9.38578217e-01, -4.42798510e-01, -5.08143662e-01,
3.34803599e-02],
[-1.39319486e-01, 1.20914733e+00, 9.21036002e-01,
2.95863627e-01, -3.02004547e-01, 4.87745637e-01,
-6.32226004e-01, -4.65638379e-01, 7.53420553e-01,
9.67359099e-01],
[ 1.56340412e+00, -1.50111874e+00, 3.48906921e-02,
-1.11667262e+00, 2.85433459e-01, -1.06549585e+00,
-1.14267158e-01, 9.30395980e-01, 6.59490581e-01,
-1.23604807e+00],
[-9.39019716e-02, 1.97779994e+00, 1.11966716e-01,
7.49063752e-01, 1.15612290e+00, 1.26183133e+00,
2.15900082e-01, 9.79341494e-01, -3.63591725e-01,
-4.01937103e-01],
...
[-1.68381630e+00, 8.21936974e-01, 3.59054585e-02,
2.68666820e-01, 1.20226024e+00, -6.42531089e-01,
1.37912909e+00, -1.70637172e+00, -1.17390525e+00,
1.20923869e+00],
[-1.79643258e+00, 1.47154486e-02, -1.16183081e+00,
8.43020107e-01, -2.13821384e-01, 7.83402761e-01,
1.10558046e+00, -1.60943629e+00, 1.29225004e+00,
2.73645038e-01],
[ 1.12258686e-01, -3.64928878e-01, 1.04349729e+00,
1.11002098e+00, -8.33764798e-01, -7.42510407e-01,
5.03180502e-01, -6.73937507e-01, 5.79945121e-01,
1.53785798e+00],
[-5.29799229e-01, -1.52448401e+00, -6.86830114e-01,
6.96936049e-01, 3.09533503e-01, 1.48660760e-01,
-2.08300629e-02, -1.06856903e+00, -1.90334596e+00,
9.92786055e-01],
[ 1.94489963e+00, -5.24953096e-01, -5.87997600e-01,
1.29295581e+00, -1.45536431e+00, -1.83659253e+00,
-2.40957150e-01, -8.47449716e-01, 1.60735032e+00,
-5.71976673e-02]]])
* c
(chain, draw, z)
float64
1.02 -0.09153 -0.3396 ... 1.3 1.734
array([[[ 1.02018057, -0.09152686, -0.33959092, ..., 1.15506305,
0.27756728, -1.42368563],
[ 0.27015438, 0.63622663, -2.10143742, ..., 0.41161292,
0.70490801, 0.09042747],
[ 0.95493779, -0.44125074, 0.6315446 , ..., 0.22894178,
-0.9702002 , -1.36738857],
...,
[-0.1075326 , 1.11405442, 0.40301183, ..., 0.49983112,
-0.28102153, 0.5794615 ],
[ 1.40461536, 0.5993807 , 0.72138274, ..., -0.13959598,
-0.3725852 , 1.09185991],
[-0.56560533, 0.12719073, -1.1408518 , ..., 0.2201536 ,
1.30023644, 1.7344667 ]]], shape=(1, 100, 12)) - Indexes: (4)
* PandasIndex
PandasIndex(Index([0], dtype='int64', name='chain'))
* PandasIndex
PandasIndex(Index([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53,
54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
90, 91, 92, 93, 94, 95, 96, 97, 98, 99],
dtype='int64', name='draw'))
* PandasIndex
PandasIndex(Index([0, 1, 2, 3, 4, 5, 6, 7, 8, 9], dtype='int64', name='b1'))
* PandasMultiIndex
PandasIndex(MultiIndex([(0, 0),
(0, 1),
(0, 2),
(0, 3),
(1, 0),
(1, 1),
(1, 2),
(1, 3),
(2, 0),
(2, 1),
(2, 2),
(2, 3)],
name='z')) - Attributes: (2)
created_at :
2025-05-27T21:35:35.821269+00:00
arviz_version :
0.22.0dev
- Dimensions: