index
int64 0
731k
| package
stringlengths 2
98
⌀ | name
stringlengths 1
76
| docstring
stringlengths 0
281k
⌀ | code
stringlengths 4
8.19k
| signature
stringlengths 2
42.8k
⌀ | embed_func_code
listlengths 768
768
|
---|---|---|---|---|---|---|
32,020 | pingouin.regression | mediation_analysis | Mediation analysis using a bias-correct non-parametric bootstrap method.
Parameters
----------
data : :py:class:`pandas.DataFrame`
Dataframe.
x : str
Column name in data containing the predictor variable.
The predictor variable must be continuous.
m : str or list of str
Column name(s) in data containing the mediator variable(s).
The mediator(s) can be continuous or binary (e.g. 0 or 1).
This function supports multiple parallel mediators.
y : str
Column name in data containing the outcome variable.
The outcome variable must be continuous.
covar : None, str, or list
Covariate(s). If not None, the specified covariate(s) will be included
in all regressions.
alpha : float
Significance threshold. Used to determine the confidence interval,
:math:`\text{CI} = [\alpha / 2 ; 1 - \alpha / 2]`.
n_boot : int
Number of bootstrap iterations for confidence intervals and p-values
estimation. The greater, the slower.
seed : int or None
Random state seed.
logreg_kwargs : dict or None
Dictionary with optional arguments passed to :py:func:`pingouin.logistic_regression`
return_dist : bool
If True, the function also returns the indirect bootstrapped beta
samples (size = n_boot). Can be plotted for instance using
:py:func:`seaborn.distplot()` or :py:func:`seaborn.kdeplot()`
functions.
Returns
-------
stats : :py:class:`pandas.DataFrame`
Mediation summary:
* ``'path'``: regression model
* ``'coef'``: regression estimates
* ``'se'``: standard error
* ``'CI[2.5%]'``: lower confidence interval
* ``'CI[97.5%]'``: upper confidence interval
* ``'pval'``: two-sided p-values
* ``'sig'``: statistical significance
See also
--------
linear_regression, logistic_regression
Notes
-----
Mediation analysis [1]_ is a *"statistical procedure to test
whether the effect of an independent variable X on a dependent variable
Y (i.e., X → Y) is at least partly explained by a chain of effects of the
independent variable on an intervening mediator variable M and of the
intervening variable on the dependent variable (i.e., X → M → Y)"* [2]_.
The **indirect effect** (also referred to as average causal mediation
effect or ACME) of X on Y through mediator M quantifies the estimated
difference in Y resulting from a one-unit change in X through a sequence of
causal steps in which X affects M, which in turn affects Y.
It is considered significant if the specified confidence interval does not
include 0. The path 'X --> Y' is the sum of both the indirect and direct
effect. It is sometimes referred to as total effect.
A linear regression is used if the mediator variable is continuous and a
logistic regression if the mediator variable is dichotomous (binary).
Multiple parallel mediators are also supported.
This function will only work well if the outcome variable is continuous.
It does not support binary or ordinal outcome variable. For more
advanced mediation models, please refer to the
`lavaan <http://lavaan.ugent.be/tutorial/mediation.html>`_ or `mediation
<https://cran.r-project.org/web/packages/mediation/mediation.pdf>`_ R
packages, or the `PROCESS macro
<https://www.processmacro.org/index.html>`_ for SPSS.
The two-sided p-value of the indirect effect is computed using the
bootstrap distribution, as in the mediation R package. However, the p-value
should be interpreted with caution since it is not constructed
conditioned on a true null hypothesis [3]_ and varies depending on the
number of bootstrap samples and the random seed.
Note that rows with missing values are automatically removed.
Results have been tested against the R mediation package and this tutorial
https://data.library.virginia.edu/introduction-to-mediation-analysis/
References
----------
.. [1] Baron, R. M. & Kenny, D. A. The moderator–mediator variable
distinction in social psychological research: Conceptual, strategic,
and statistical considerations. J. Pers. Soc. Psychol. 51, 1173–1182
(1986).
.. [2] Fiedler, K., Schott, M. & Meiser, T. What mediation analysis can
(not) do. J. Exp. Soc. Psychol. 47, 1231–1236 (2011).
.. [3] Hayes, A. F. & Rockwood, N. J. Regression-based statistical
mediation and moderation analysis in clinical research:
Observations, recommendations, and implementation. Behav. Res.
Ther. 98, 39–57 (2017).
Code originally adapted from https://github.com/rmill040/pymediation.
Examples
--------
1. Simple mediation analysis
>>> from pingouin import mediation_analysis, read_dataset
>>> df = read_dataset('mediation')
>>> mediation_analysis(data=df, x='X', m='M', y='Y', alpha=0.05,
... seed=42)
path coef se pval CI[2.5%] CI[97.5%] sig
0 M ~ X 0.561015 0.094480 4.391362e-08 0.373522 0.748509 Yes
1 Y ~ M 0.654173 0.085831 1.612674e-11 0.483844 0.824501 Yes
2 Total 0.396126 0.111160 5.671128e-04 0.175533 0.616719 Yes
3 Direct 0.039604 0.109648 7.187429e-01 -0.178018 0.257226 No
4 Indirect 0.356522 0.083313 0.000000e+00 0.219818 0.537654 Yes
2. Return the indirect bootstrapped beta coefficients
>>> stats, dist = mediation_analysis(data=df, x='X', m='M', y='Y',
... return_dist=True)
>>> print(dist.shape)
(500,)
3. Mediation analysis with a binary mediator variable
>>> mediation_analysis(data=df, x='X', m='Mbin', y='Y', seed=42).round(3)
path coef se pval CI[2.5%] CI[97.5%] sig
0 Mbin ~ X -0.021 0.116 0.857 -0.248 0.206 No
1 Y ~ Mbin -0.135 0.412 0.743 -0.952 0.682 No
2 Total 0.396 0.111 0.001 0.176 0.617 Yes
3 Direct 0.396 0.112 0.001 0.174 0.617 Yes
4 Indirect 0.002 0.050 0.960 -0.072 0.146 No
4. Mediation analysis with covariates
>>> mediation_analysis(data=df, x='X', m='M', y='Y',
... covar=['Mbin', 'Ybin'], seed=42).round(3)
path coef se pval CI[2.5%] CI[97.5%] sig
0 M ~ X 0.559 0.097 0.000 0.367 0.752 Yes
1 Y ~ M 0.666 0.086 0.000 0.495 0.837 Yes
2 Total 0.420 0.113 0.000 0.196 0.645 Yes
3 Direct 0.064 0.110 0.561 -0.155 0.284 No
4 Indirect 0.356 0.086 0.000 0.209 0.553 Yes
5. Mediation analysis with multiple parallel mediators
>>> mediation_analysis(data=df, x='X', m=['M', 'Mbin'], y='Y',
... seed=42).round(3)
path coef se pval CI[2.5%] CI[97.5%] sig
0 M ~ X 0.561 0.094 0.000 0.374 0.749 Yes
1 Mbin ~ X -0.005 0.029 0.859 -0.063 0.052 No
2 Y ~ M 0.654 0.086 0.000 0.482 0.825 Yes
3 Y ~ Mbin -0.064 0.328 0.846 -0.715 0.587 No
4 Total 0.396 0.111 0.001 0.176 0.617 Yes
5 Direct 0.040 0.110 0.721 -0.179 0.258 No
6 Indirect M 0.356 0.085 0.000 0.215 0.538 Yes
7 Indirect Mbin 0.000 0.010 0.952 -0.017 0.025 No
| @pf.register_dataframe_method
def mediation_analysis(
data=None,
x=None,
m=None,
y=None,
covar=None,
alpha=0.05,
n_boot=500,
seed=None,
return_dist=False,
logreg_kwargs=None,
):
"""Mediation analysis using a bias-correct non-parametric bootstrap method.
Parameters
----------
data : :py:class:`pandas.DataFrame`
Dataframe.
x : str
Column name in data containing the predictor variable.
The predictor variable must be continuous.
m : str or list of str
Column name(s) in data containing the mediator variable(s).
The mediator(s) can be continuous or binary (e.g. 0 or 1).
This function supports multiple parallel mediators.
y : str
Column name in data containing the outcome variable.
The outcome variable must be continuous.
covar : None, str, or list
Covariate(s). If not None, the specified covariate(s) will be included
in all regressions.
alpha : float
Significance threshold. Used to determine the confidence interval,
:math:`\\text{CI} = [\\alpha / 2 ; 1 - \\alpha / 2]`.
n_boot : int
Number of bootstrap iterations for confidence intervals and p-values
estimation. The greater, the slower.
seed : int or None
Random state seed.
logreg_kwargs : dict or None
Dictionary with optional arguments passed to :py:func:`pingouin.logistic_regression`
return_dist : bool
If True, the function also returns the indirect bootstrapped beta
samples (size = n_boot). Can be plotted for instance using
:py:func:`seaborn.distplot()` or :py:func:`seaborn.kdeplot()`
functions.
Returns
-------
stats : :py:class:`pandas.DataFrame`
Mediation summary:
* ``'path'``: regression model
* ``'coef'``: regression estimates
* ``'se'``: standard error
* ``'CI[2.5%]'``: lower confidence interval
* ``'CI[97.5%]'``: upper confidence interval
* ``'pval'``: two-sided p-values
* ``'sig'``: statistical significance
See also
--------
linear_regression, logistic_regression
Notes
-----
Mediation analysis [1]_ is a *"statistical procedure to test
whether the effect of an independent variable X on a dependent variable
Y (i.e., X → Y) is at least partly explained by a chain of effects of the
independent variable on an intervening mediator variable M and of the
intervening variable on the dependent variable (i.e., X → M → Y)"* [2]_.
The **indirect effect** (also referred to as average causal mediation
effect or ACME) of X on Y through mediator M quantifies the estimated
difference in Y resulting from a one-unit change in X through a sequence of
causal steps in which X affects M, which in turn affects Y.
It is considered significant if the specified confidence interval does not
include 0. The path 'X --> Y' is the sum of both the indirect and direct
effect. It is sometimes referred to as total effect.
A linear regression is used if the mediator variable is continuous and a
logistic regression if the mediator variable is dichotomous (binary).
Multiple parallel mediators are also supported.
This function will only work well if the outcome variable is continuous.
It does not support binary or ordinal outcome variable. For more
advanced mediation models, please refer to the
`lavaan <http://lavaan.ugent.be/tutorial/mediation.html>`_ or `mediation
<https://cran.r-project.org/web/packages/mediation/mediation.pdf>`_ R
packages, or the `PROCESS macro
<https://www.processmacro.org/index.html>`_ for SPSS.
The two-sided p-value of the indirect effect is computed using the
bootstrap distribution, as in the mediation R package. However, the p-value
should be interpreted with caution since it is not constructed
conditioned on a true null hypothesis [3]_ and varies depending on the
number of bootstrap samples and the random seed.
Note that rows with missing values are automatically removed.
Results have been tested against the R mediation package and this tutorial
https://data.library.virginia.edu/introduction-to-mediation-analysis/
References
----------
.. [1] Baron, R. M. & Kenny, D. A. The moderator–mediator variable
distinction in social psychological research: Conceptual, strategic,
and statistical considerations. J. Pers. Soc. Psychol. 51, 1173–1182
(1986).
.. [2] Fiedler, K., Schott, M. & Meiser, T. What mediation analysis can
(not) do. J. Exp. Soc. Psychol. 47, 1231–1236 (2011).
.. [3] Hayes, A. F. & Rockwood, N. J. Regression-based statistical
mediation and moderation analysis in clinical research:
Observations, recommendations, and implementation. Behav. Res.
Ther. 98, 39–57 (2017).
Code originally adapted from https://github.com/rmill040/pymediation.
Examples
--------
1. Simple mediation analysis
>>> from pingouin import mediation_analysis, read_dataset
>>> df = read_dataset('mediation')
>>> mediation_analysis(data=df, x='X', m='M', y='Y', alpha=0.05,
... seed=42)
path coef se pval CI[2.5%] CI[97.5%] sig
0 M ~ X 0.561015 0.094480 4.391362e-08 0.373522 0.748509 Yes
1 Y ~ M 0.654173 0.085831 1.612674e-11 0.483844 0.824501 Yes
2 Total 0.396126 0.111160 5.671128e-04 0.175533 0.616719 Yes
3 Direct 0.039604 0.109648 7.187429e-01 -0.178018 0.257226 No
4 Indirect 0.356522 0.083313 0.000000e+00 0.219818 0.537654 Yes
2. Return the indirect bootstrapped beta coefficients
>>> stats, dist = mediation_analysis(data=df, x='X', m='M', y='Y',
... return_dist=True)
>>> print(dist.shape)
(500,)
3. Mediation analysis with a binary mediator variable
>>> mediation_analysis(data=df, x='X', m='Mbin', y='Y', seed=42).round(3)
path coef se pval CI[2.5%] CI[97.5%] sig
0 Mbin ~ X -0.021 0.116 0.857 -0.248 0.206 No
1 Y ~ Mbin -0.135 0.412 0.743 -0.952 0.682 No
2 Total 0.396 0.111 0.001 0.176 0.617 Yes
3 Direct 0.396 0.112 0.001 0.174 0.617 Yes
4 Indirect 0.002 0.050 0.960 -0.072 0.146 No
4. Mediation analysis with covariates
>>> mediation_analysis(data=df, x='X', m='M', y='Y',
... covar=['Mbin', 'Ybin'], seed=42).round(3)
path coef se pval CI[2.5%] CI[97.5%] sig
0 M ~ X 0.559 0.097 0.000 0.367 0.752 Yes
1 Y ~ M 0.666 0.086 0.000 0.495 0.837 Yes
2 Total 0.420 0.113 0.000 0.196 0.645 Yes
3 Direct 0.064 0.110 0.561 -0.155 0.284 No
4 Indirect 0.356 0.086 0.000 0.209 0.553 Yes
5. Mediation analysis with multiple parallel mediators
>>> mediation_analysis(data=df, x='X', m=['M', 'Mbin'], y='Y',
... seed=42).round(3)
path coef se pval CI[2.5%] CI[97.5%] sig
0 M ~ X 0.561 0.094 0.000 0.374 0.749 Yes
1 Mbin ~ X -0.005 0.029 0.859 -0.063 0.052 No
2 Y ~ M 0.654 0.086 0.000 0.482 0.825 Yes
3 Y ~ Mbin -0.064 0.328 0.846 -0.715 0.587 No
4 Total 0.396 0.111 0.001 0.176 0.617 Yes
5 Direct 0.040 0.110 0.721 -0.179 0.258 No
6 Indirect M 0.356 0.085 0.000 0.215 0.538 Yes
7 Indirect Mbin 0.000 0.010 0.952 -0.017 0.025 No
"""
# Sanity check
assert isinstance(x, (str, int)), "y must be a string or int."
assert isinstance(y, (str, int)), "y must be a string or int."
assert isinstance(m, (list, str, int)), "Mediator(s) must be a list, string or int."
assert isinstance(covar, (type(None), str, list, int))
if isinstance(m, (str, int)) | (data=None, x=None, m=None, y=None, covar=None, alpha=0.05, n_boot=500, seed=None, return_dist=False, logreg_kwargs=None) | [
0.0857103019952774,
-0.0016073271399363875,
0.04196406155824661,
0.04351828619837761,
0.01853671669960022,
-0.04326960816979408,
-0.018920091912150383,
-0.003395980456843972,
-0.046295166015625,
0.0524706169962883,
-0.03151967376470566,
0.05321664735674858,
0.03974670171737671,
0.04782866686582565,
-0.028452668339014053,
0.023230474442243576,
0.006657261401414871,
0.029758216813206673,
0.04409852996468544,
0.0368662029504776,
-0.05661521479487419,
-0.011366561986505985,
-0.03964308649301529,
0.056159310042858124,
-0.04310382530093193,
0.031768348067998886,
-0.060884151607751846,
-0.05031542479991913,
-0.025157712399959564,
-0.0011397645575925708,
0.016847793012857437,
-0.05620075762271881,
0.013117654249072075,
-0.032659437507390976,
0.015065615996718407,
-0.0041601406410336494,
0.051144346594810486,
0.018775030970573425,
-0.15310147404670715,
-0.024225179105997086,
-0.005167796276509762,
-0.0562422014772892,
0.06407549232244492,
0.018878646194934845,
0.0028209174051880836,
0.041818998754024506,
-0.02225649356842041,
0.06668659299612045,
-0.006216897629201412,
0.0052714115008711815,
0.042440690100193024,
-0.013490668497979641,
0.009014502167701721,
0.028349054977297783,
0.017604181542992592,
0.059889450669288635,
-0.007807387504726648,
0.015386822633445263,
0.0853787288069725,
-0.04940361529588699,
0.05984800308942795,
0.03330184891819954,
0.056698109954595566,
-0.017873581498861313,
0.020909499377012253,
0.018775030970573425,
0.027043506503105164,
0.008537872694432735,
-0.0524706169962883,
0.004504660610109568,
-0.019821543246507645,
-0.050356872379779816,
0.0020451003219932318,
0.04633661359548569,
0.019769735634326935,
-0.050191089510917664,
-0.007424012292176485,
-0.01759382151067257,
0.028141824528574944,
0.02979966439306736,
0.03827536851167679,
0.028038209304213524,
-0.029095081612467766,
0.0008360432693734765,
0.009568842127919197,
-0.01565622165799141,
0.00942378118634224,
0.04136309400200844,
-0.006522561889141798,
-0.05209760367870331,
-0.04022333025932312,
-0.006569188553839922,
0.06022101640701294,
0.06158873438835144,
-0.03247293084859848,
0.035581380128860474,
-0.035581380128860474,
0.03392354026436806,
0.012485602870583534,
-0.010548003017902374,
-0.07447843998670578,
0.06469718366861343,
0.021862758323550224,
0.038358259946107864,
-0.023271920159459114,
-0.03711488097906113,
-0.04094863310456276,
0.01335596852004528,
-0.05102000758051872,
-0.02754085697233677,
-0.07393963634967804,
-0.014350672252476215,
-0.08330643177032471,
-0.06424127519130707,
0.04306237772107124,
-0.026691215112805367,
-0.033384740352630615,
-0.0004840761539526284,
-0.021033838391304016,
0.028473392128944397,
0.0029400745406746864,
-0.01469260174781084,
-0.06283211708068848,
-0.05814871937036514,
0.013853320851922035,
-0.012868979014456272,
0.06341236084699631,
-0.029965447261929512,
0.03433799743652344,
0.0063049704767763615,
-0.05926775932312012,
-0.029965447261929512,
-0.004628998693078756,
0.05707112327218056,
-0.02320975251495838,
0.01728297583758831,
0.01786321960389614,
-0.05702967569231987,
0.01354247611016035,
-0.005558942910283804,
-0.0077141341753304005,
0.006066656205803156,
0.004841409157961607,
-0.0018378704553470016,
0.0021603719796985388,
-0.0038596573285758495,
0.0524706169962883,
-0.012475241906940937,
0.01681670919060707,
-0.007035456132143736,
-0.034234385937452316,
-0.06643791496753693,
0.03837898373603821,
-0.050191089510917664,
0.03868982940912247,
0.014361034147441387,
0.03713560476899147,
0.03723921999335289,
0.0009416009997949004,
-0.01634008064866066,
-0.005880149081349373,
-0.06871744245290756,
-0.006900756619870663,
0.053506769239902496,
0.0026357057504355907,
0.030027616769075394,
0.01738659106194973,
0.029861832037568092,
-0.026732660830020905,
-0.013749705627560616,
0.005009783431887627,
0.011532345786690712,
-0.007594977039843798,
-0.03247293084859848,
-0.0452590174973011,
0.07696519792079926,
-0.012620302848517895,
0.00607701763510704,
0.01571838930249214,
-0.010118001140654087,
0.011781021021306515,
0.04563203081488609,
-0.018339848145842552,
-0.015044893138110638,
-0.043393947184085846,
0.004507251083850861,
0.0315403938293457,
-0.04530046135187149,
0.030711475759744644,
0.023271920159459114,
0.008221847005188465,
-0.0809440091252327,
0.0452590174973011,
-0.011915720999240875,
-0.004628998693078756,
0.0128586171194911,
0.020090941339731216,
-0.006584730930626392,
0.07795990258455276,
-0.04654384031891823,
0.050937116146087646,
-0.07078974694013596,
0.01296223234385252,
0.011718852445483208,
-0.0050615910440683365,
-0.004942433908581734,
-0.07634350657463074,
0.06921479851007462,
-0.06581622362136841,
-0.03524981066584587,
-0.016267549246549606,
-0.03866910561919212,
0.057319797575473785,
0.012796448543667793,
0.06478007882833481,
-0.0231475830078125,
0.06507019698619843,
-0.001126165152527392,
0.039871037006378174,
-0.01665092445909977,
0.043642621487379074,
-0.014910193160176277,
-0.0473313145339489,
0.08077822625637054,
0.02052612416446209,
0.026629045605659485,
-0.0027432062197476625,
0.001284177997149527,
0.06656225025653839,
-0.0562422014772892,
0.04845035821199417,
0.005667738616466522,
-0.01052209921181202,
-0.04018188267946243,
0.008045702241361141,
-0.015904897823929787,
-0.00738256610929966,
-0.004004718270152807,
-0.007009552326053381,
0.00793172512203455,
0.011853551492094994,
-0.02801748551428318,
0.02723001316189766,
0.039352964609861374,
0.01807045005261898,
-0.06175451725721359,
0.039352964609861374,
0.02843194641172886,
0.007890279404819012,
-0.029778940603137016,
-0.01039258111268282,
0.006020029541105032,
0.004201586823910475,
-0.014371395111083984,
0.04067923501133919,
-0.03147822618484497,
0.010827763937413692,
0.038834888488054276,
0.04633661359548569,
-0.0538383349776268,
0.04264792054891586,
-0.07422976195812225,
0.008641487918794155,
0.0069991908967494965,
-0.04099008068442345,
0.021282514557242393,
-0.033654142171144485,
0.0022121795918792486,
-0.023541320115327835,
-0.010796679183840752,
-0.024121563881635666,
0.01416416559368372,
-0.018826838582754135,
-0.053962673991918564,
-0.03332257270812988,
-0.002617573132738471,
0.0006485648918896914,
-0.05379689112305641,
-0.02486759051680565,
0.00916474312543869,
-0.0528021864593029,
-0.06017957255244255,
-0.0060718366876244545,
0.008232208900153637,
0.0060303909704089165,
0.021489743143320084,
0.006750514730811119,
-0.00011705252836691216,
0.04608793556690216,
0.01277572475373745,
-0.031768348067998886,
-0.02839050069451332,
-0.020132387056946754,
0.002852001925930381,
-0.028556283563375473,
0.005074542947113514,
-0.014506095089018345,
-0.01750056818127632,
-0.030255569145083427,
-0.026566876098513603,
-0.004841409157961607,
0.027623750269412994,
0.06017957255244255,
0.05980655550956726,
-0.0672253891825676,
0.0306907519698143,
0.07907894253730774,
-0.06772273778915405,
0.028887851163744926,
-0.047787223011255264,
0.030255569145083427,
0.09093249589204788,
-0.0027173024136573076,
0.008998959325253963,
0.03037990815937519,
-0.036368850618600845,
-0.011335477232933044,
0.06664514541625977,
0.033591970801353455,
0.0830163061618805,
0.045424800366163254,
-0.011283669620752335,
0.0406377874314785,
0.0286391768604517,
0.06258343905210495,
-0.01717936061322689,
0.020878415554761887,
0.020080579444766045,
0.004963156767189503,
0.008817633613944054,
-0.058355946093797684,
-0.030628584325313568,
0.03330184891819954,
0.01884756237268448,
0.022111432626843452,
-0.033861368894577026,
-0.07352517545223236,
-0.06337091326713562,
0.056490879505872726,
0.019137684255838394,
0.03131244331598282,
-0.047621436417102814,
-0.014993085525929928,
0.021779865026474,
0.06341236084699631,
-0.020557207986712456,
0.06842732429504395,
0.022318663075566292,
-0.01474440935999155,
0.02870134450495243,
0.04994241148233414,
0.0994703620672226,
-0.013832597993314266,
0.005219603888690472,
0.015024169348180294,
-0.01013354305177927,
-0.037218496203422546,
-0.030545691028237343,
-0.0459635965526104,
0.03630668297410011,
0.005683280993252993,
0.0695878118276596,
-0.028203994035720825,
0.0018197378376498818,
-0.006983648519963026,
-0.006859310436993837,
-0.07518301904201508,
0.04318671673536301,
0.02414228580892086,
-0.021904204040765762,
0.04268936440348625,
-0.022090710699558258,
-0.04094863310456276,
0.04803589731454849,
0.01416416559368372,
0.07427120953798294,
-0.0005831579910591245,
-0.0018547078361734748,
-0.002903809305280447,
0.03141605854034424,
-0.03796452283859253,
0.005678100045770407,
-0.03980886936187744,
0.0008567662443965673,
0.022111432626843452,
0.025178436189889908,
0.03779873996973038,
-0.005906052887439728,
-0.07124564796686172,
-0.03340546414256096,
0.0005501306732185185,
-0.038627658039331436,
-0.03460739925503731,
0.010796679183840752,
-0.031975578516721725,
-0.029260866343975067,
0.04043056070804596,
0.022961076349020004,
-0.04927927628159523,
-0.03879344090819359,
0.009760529734194279,
-0.04043056070804596,
-0.04227490723133087,
0.02476397715508938,
-0.030359184369444847,
-0.07311072200536728,
-0.03352980315685272,
0.03572643920779228,
-0.007745218463242054,
0.0027380255050957203,
0.012402711436152458,
-0.0368662029504776,
-0.006066656205803156,
0.035747162997722626,
-0.00616509048268199,
-0.006589911878108978,
0.00913884025067091,
-0.04886481538414955,
0.002929713111370802,
-0.011066078208386898,
0.06867599487304688,
-0.03912501037120819,
0.04932072386145592,
-0.002375373151153326,
-0.02215288020670414,
-0.0020347388926893473,
-0.04791155830025673,
-0.020609015598893166,
-0.05367255210876465,
-0.012008974328637123,
0.009102574549615383,
0.0062842476181685925,
-0.02729218080639839,
-0.02586229518055916,
0.011667044833302498,
-0.020722992718219757,
-0.027457965537905693,
0.004271526820957661,
0.03193413093686104,
-0.009439323097467422,
0.004079839214682579,
0.028452668339014053,
0.00003701401874423027,
-0.06672804057598114,
-0.03827536851167679,
-0.024121563881635666,
0.005297314841300249,
-0.007429192773997784,
-0.001415639417245984,
-0.010314869694411755,
0.029198696836829185,
-0.0017135324887931347,
0.058521732687950134,
0.003621343057602644,
0.0028856766875833273,
-0.0074810003861784935,
0.06295645236968994,
-0.027105674147605896,
0.0036239332985132933,
0.01481693983078003,
-0.01481693983078003,
-0.005222194362431765,
-0.09988482296466827,
-0.01348030660301447,
0.0023274512495845556,
0.12491820007562637,
0.055330391973257065,
-0.021282514557242393,
-0.033073898404836655,
0.03435872122645378,
0.039083562791347504,
0.017573097720742226,
-0.0373842790722847,
-0.023541320115327835,
0.009335707873106003,
-0.0034037516452372074,
-0.04273081198334694,
-0.02963387966156006,
0.03462811931967735,
0.018184425309300423,
0.03392354026436806,
-0.041300926357507706,
0.01791502721607685,
0.0020140158012509346,
-0.039974652230739594,
-0.04803589731454849,
0.041300926357507706,
-0.061505842953920364,
0.039456579834222794,
-0.05450147017836571,
0.01275500189512968,
0.054335687309503555,
0.07899604737758636,
-0.01597742736339569,
-0.039663806557655334,
0.04633661359548569,
0.012495964765548706,
-0.018609248101711273,
0.10485834628343582,
-0.08496426790952682,
0.026732660830020905,
0.004165321588516235,
-0.05164169892668724,
-0.05251206457614899,
-0.031188104301691055,
0.01471332460641861,
-0.021033838391304016,
0.012889701873064041,
-0.059930894523859024,
0.013283438049256802,
-0.012029697187244892,
-0.016360802575945854,
-0.0373842790722847,
0.011894998140633106,
-0.03226570039987564,
-0.01351139135658741,
0.013438860885798931,
0.029924001544713974,
0.01596706546843052,
-0.036576081067323685,
0.033861368894577026,
-0.02414228580892086,
-0.013169461861252785,
-0.004968337714672089,
0.01220584288239479,
0.028141824528574944,
-0.05437713488936424,
-0.023064691573381424,
-0.042337074875831604,
0.003828573040664196,
-0.023271920159459114,
-0.009988482110202312,
-0.0012582741910591722,
0.05363110452890396,
0.009257997386157513,
-0.028763514012098312,
0.03162328526377678,
-0.025385666638612747,
0.01702393777668476,
0.012040059082210064,
-0.03769512474536896,
-0.04331105574965477,
-0.035892222076654434,
0.027830978855490685,
0.04229562729597092,
-0.002875315258279443,
-0.020930223166942596,
0.023499874398112297,
0.0334261879324913,
0.01943816803395748,
0.0009914656402543187,
-0.016837431117892265,
-0.02853556163609028,
0.0219456497579813,
0.07033383846282959,
-0.011242223903536797,
0.0726962611079216,
0.0036006199661642313,
-0.002976339776068926,
-0.005978583358228207,
-0.005087494850158691,
-0.0476628839969635,
0.00796280987560749,
-0.042337074875831604,
0.020028771832585335,
-0.005683280993252993,
-0.0045305644161999226,
0.006056294776499271,
-0.08086112141609192,
-0.039249349385499954,
0.0012880634749308228,
0.039352964609861374,
0.007537988480180502,
0.022857461124658585,
-0.016878876835107803,
0.02640109322965145,
0.06647936254739761,
-0.011107523925602436,
-0.016982492059469223,
-0.02818327024579048,
0.02503337524831295,
0.004372551571577787,
0.02068154700100422,
0.00744991609826684,
-0.013159100897610188,
-0.029468094930052757,
-0.06428272277116776,
-0.009511853568255901,
-0.0055019548162817955,
0.010775956325232983,
-0.030939428135752678,
0.009232093580067158,
-0.009304624050855637,
-0.017096469178795815,
0.0001589032617630437,
0.054335687309503555,
-0.007475819438695908,
-0.005714365281164646,
0.07248903065919876,
-0.0006644309614785016,
-0.006434489507228136,
-0.02770664170384407,
0.03620306774973869,
-0.05118579417467117,
0.015169231221079826,
0.0009681523079052567,
0.004056525882333517,
-0.03897995129227638,
-0.023437704890966415,
-0.029447373002767563,
-0.06084270775318146,
0.011501261033117771,
-0.00007722552982158959,
0.016827071085572243,
0.004647131077945232,
-0.05541328340768814,
-0.019313829019665718,
0.019935518503189087,
0.04803589731454849,
0.011977889575064182,
0.020339617505669594,
-0.0036550178192555904,
-0.005636653862893581,
-0.0019337142584845424,
0.019179129973053932,
0.021064922213554382,
-0.05263640359044075,
-0.04268936440348625,
0.0198008194565773,
-0.003994356840848923,
-0.017894303426146507,
0.0497351810336113,
0.06428272277116776,
-0.004349238239228725,
0.005356893874704838,
-0.021220345050096512,
0.01933455280959606,
-0.03340546414256096,
-0.007237505167722702,
0.02445313148200512,
0.025095544755458832,
-0.014184888452291489,
-0.006102921441197395,
-0.003745680907741189,
-0.0019065153319388628,
0.03703198954463005,
-0.035892222076654434,
0.004996831528842449,
0.004336286336183548,
0.030462799593806267,
0.0012809400213882327,
-0.01732442155480385,
-0.050564102828502655,
-0.018308764323592186,
0.06013812497258186,
-0.04546624794602394,
-0.028825683519244194,
0.04641950502991676,
0.010454749688506126,
0.031975578516721725,
0.002226426498964429,
-0.00838245078921318,
-0.029177973046898842,
-0.01995624229311943,
0.05048121139407158,
-0.02000804990530014,
-0.023292643949389458,
-0.006216897629201412,
0.017842497676610947,
-0.010247520171105862,
0.05707112327218056,
0.0022782341111451387,
0.013438860885798931,
-0.015231399796903133,
-0.03141605854034424,
-0.030566414818167686,
0.023416981101036072,
-0.0015904896426945925,
-0.03042135387659073,
0.03980886936187744,
0.04952795431017876,
0.04121803119778633,
0.050149641931056976,
0.01738659106194973,
0.024536022916436195,
0.04948650673031807,
0.025282051414251328,
-0.06664514541625977,
-0.02441168576478958,
0.007641603704541922,
0.010273423977196217,
-0.05939209833741188,
0.018153341487050056,
-0.0036083911545574665,
-0.019075514748692513,
0.020930223166942596,
-0.043642621487379074,
-0.001274464069865644,
0.034690290689468384,
-0.03929079324007034,
0.005305086262524128,
0.02969604916870594,
-0.012040059082210064,
0.0040073087438941,
-0.028887851163744926,
-0.014920555055141449,
-0.03786090761423111,
0.0552060529589653,
0.06026246398687363,
-0.07779411226511002,
-0.0011268127709627151,
0.053962673991918564,
0.018982261419296265,
0.014329949393868446,
0.07725531607866287,
0.01172921434044838,
-0.03672114387154579,
0.059889450669288635,
0.03922862559556961,
-0.00014506095612887293,
0.023189028725028038,
-0.0198008194565773,
0.030670030042529106,
0.035747162997722626,
-0.06395115703344345,
0.005351712927222252,
0.030027616769075394,
-0.01591525785624981,
0.050771333277225494,
-0.07103841751813889,
0.00024867590400390327,
0.028825683519244194,
-0.018308764323592186,
0.07427120953798294,
0.006134005729109049,
-0.05964077264070511,
-0.015666581690311432,
-0.028307607397437096,
-0.01575983688235283,
0.010755233466625214,
-0.053133752197027206,
-0.035747162997722626,
0.000865184934809804,
0.0009590859990566969,
0.013190184719860554,
0.02664976939558983,
0.03970525413751602,
0.007123528979718685,
0.009838241152465343,
-0.02770664170384407,
0.059143420308828354,
-0.07315216213464737,
-0.022111432626843452,
0.03672114387154579,
-0.02267095446586609,
0.038254644721746445,
0.04105224832892418,
-0.008356546983122826,
-0.022753845900297165,
-0.0737324059009552,
-0.04208839684724808,
-0.0022782341111451387,
0.029820386320352554,
-0.0033234499860554934,
-0.02623530849814415,
0.07779411226511002,
-0.01832948625087738,
0.053755443543195724
]
|
32,021 | pingouin.parametric | mixed_anova | Mixed-design (split-plot) ANOVA.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a
Pandas method, in which case this argument is no longer needed.
dv : string
Name of column containing the dependent variable.
within : string
Name of column containing the within-subject factor
(repeated measurements).
subject : string
Name of column containing the between-subject identifier.
between : string
Name of column containing the between factor.
correction : string or boolean
If True, return Greenhouse-Geisser corrected p-value.
If `'auto'` (default), compute Mauchly's test of sphericity to
determine whether the p-values needs to be corrected.
effsize : str
Effect size. Must be one of 'np2' (partial eta-squared), 'n2'
(eta-squared) or 'ng2'(generalized eta-squared).
Returns
-------
aov : :py:class:`pandas.DataFrame`
ANOVA summary:
* ``'Source'``: Names of the factor considered
* ``'ddof1'``: Degrees of freedom (numerator)
* ``'ddof2'``: Degrees of freedom (denominator)
* ``'F'``: F-values
* ``'p-unc'``: Uncorrected p-values
* ``'np2'``: Partial eta-squared effect sizes
* ``'eps'``: Greenhouse-Geisser epsilon factor (= index of sphericity)
* ``'p-GG-corr'``: Greenhouse-Geisser corrected p-values
* ``'W-spher'``: Sphericity test statistic
* ``'p-spher'``: p-value of the sphericity test
* ``'sphericity'``: sphericity of the data (boolean)
See Also
--------
anova, rm_anova, pairwise_tests
Notes
-----
Data are expected to be in long-format (even the repeated measures).
If your data is in wide-format, you can use the :py:func:`pandas.melt()`
function to convert from wide to long format.
Missing values are automatically removed using a strict listwise approach (= complete-case
analysis). In other words, any subject with one or more missing value(s) is completely removed
from the dataframe prior to running the test. This could drastically decrease the power of the
ANOVA if many missing values are present. In that case, we strongly recommend using linear
mixed effect modelling, which can handle missing values in repeated measures.
.. warning :: If the between-subject groups are unbalanced (= unequal sample sizes),
a type II ANOVA will be computed. Note however that SPSS, JAMOVI and JASP by default
return a type III ANOVA, which may lead to slightly different results.
Examples
--------
For more examples, please refer to the `Jupyter notebooks
<https://github.com/raphaelvallat/pingouin/blob/master/notebooks/01_ANOVA.ipynb>`_
Compute a two-way mixed model ANOVA.
>>> from pingouin import mixed_anova, read_dataset
>>> df = read_dataset('mixed_anova')
>>> aov = mixed_anova(dv='Scores', between='Group',
... within='Time', subject='Subject', data=df)
>>> aov.round(3)
Source SS DF1 DF2 MS F p-unc np2 eps
0 Group 5.460 1 58 5.460 5.052 0.028 0.080 NaN
1 Time 7.628 2 116 3.814 4.027 0.020 0.065 0.999
2 Interaction 5.167 2 116 2.584 2.728 0.070 0.045 NaN
Same but reporting a generalized eta-squared effect size. Notice how we
can also apply this function directly as a method of the dataframe, in
which case we do not need to specify ``data=df`` anymore.
>>> df.mixed_anova(dv='Scores', between='Group', within='Time',
... subject='Subject', effsize="ng2").round(3)
Source SS DF1 DF2 MS F p-unc ng2 eps
0 Group 5.460 1 58 5.460 5.052 0.028 0.031 NaN
1 Time 7.628 2 116 3.814 4.027 0.020 0.042 0.999
2 Interaction 5.167 2 116 2.584 2.728 0.070 0.029 NaN
| @pf.register_dataframe_method
def mixed_anova(
data=None, dv=None, within=None, subject=None, between=None, correction="auto", effsize="np2"
):
"""Mixed-design (split-plot) ANOVA.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a
Pandas method, in which case this argument is no longer needed.
dv : string
Name of column containing the dependent variable.
within : string
Name of column containing the within-subject factor
(repeated measurements).
subject : string
Name of column containing the between-subject identifier.
between : string
Name of column containing the between factor.
correction : string or boolean
If True, return Greenhouse-Geisser corrected p-value.
If `'auto'` (default), compute Mauchly's test of sphericity to
determine whether the p-values needs to be corrected.
effsize : str
Effect size. Must be one of 'np2' (partial eta-squared), 'n2'
(eta-squared) or 'ng2'(generalized eta-squared).
Returns
-------
aov : :py:class:`pandas.DataFrame`
ANOVA summary:
* ``'Source'``: Names of the factor considered
* ``'ddof1'``: Degrees of freedom (numerator)
* ``'ddof2'``: Degrees of freedom (denominator)
* ``'F'``: F-values
* ``'p-unc'``: Uncorrected p-values
* ``'np2'``: Partial eta-squared effect sizes
* ``'eps'``: Greenhouse-Geisser epsilon factor (= index of sphericity)
* ``'p-GG-corr'``: Greenhouse-Geisser corrected p-values
* ``'W-spher'``: Sphericity test statistic
* ``'p-spher'``: p-value of the sphericity test
* ``'sphericity'``: sphericity of the data (boolean)
See Also
--------
anova, rm_anova, pairwise_tests
Notes
-----
Data are expected to be in long-format (even the repeated measures).
If your data is in wide-format, you can use the :py:func:`pandas.melt()`
function to convert from wide to long format.
Missing values are automatically removed using a strict listwise approach (= complete-case
analysis). In other words, any subject with one or more missing value(s) is completely removed
from the dataframe prior to running the test. This could drastically decrease the power of the
ANOVA if many missing values are present. In that case, we strongly recommend using linear
mixed effect modelling, which can handle missing values in repeated measures.
.. warning :: If the between-subject groups are unbalanced (= unequal sample sizes),
a type II ANOVA will be computed. Note however that SPSS, JAMOVI and JASP by default
return a type III ANOVA, which may lead to slightly different results.
Examples
--------
For more examples, please refer to the `Jupyter notebooks
<https://github.com/raphaelvallat/pingouin/blob/master/notebooks/01_ANOVA.ipynb>`_
Compute a two-way mixed model ANOVA.
>>> from pingouin import mixed_anova, read_dataset
>>> df = read_dataset('mixed_anova')
>>> aov = mixed_anova(dv='Scores', between='Group',
... within='Time', subject='Subject', data=df)
>>> aov.round(3)
Source SS DF1 DF2 MS F p-unc np2 eps
0 Group 5.460 1 58 5.460 5.052 0.028 0.080 NaN
1 Time 7.628 2 116 3.814 4.027 0.020 0.065 0.999
2 Interaction 5.167 2 116 2.584 2.728 0.070 0.045 NaN
Same but reporting a generalized eta-squared effect size. Notice how we
can also apply this function directly as a method of the dataframe, in
which case we do not need to specify ``data=df`` anymore.
>>> df.mixed_anova(dv='Scores', between='Group', within='Time',
... subject='Subject', effsize="ng2").round(3)
Source SS DF1 DF2 MS F p-unc ng2 eps
0 Group 5.460 1 58 5.460 5.052 0.028 0.031 NaN
1 Time 7.628 2 116 3.814 4.027 0.020 0.042 0.999
2 Interaction 5.167 2 116 2.584 2.728 0.070 0.029 NaN
"""
assert effsize in ["n2", "np2", "ng2"], "effsize must be n2, np2 or ng2."
# Check that only a single within and between factor are provided
one_is_list = isinstance(within, list) or isinstance(between, list)
both_are_str = isinstance(within, (str, int)) and isinstance(between, (str, int))
if one_is_list or not both_are_str:
raise ValueError(
"within and between factors must both be strings referring to a column in the data. "
"Specifying multiple within and between factors is currently not supported. "
"For more information, see: https://github.com/raphaelvallat/pingouin/issues/136"
)
# Check data
data = _check_dataframe(
dv=dv, within=within, between=between, data=data, subject=subject, effects="interaction"
)
# Pivot and melt the table. This has several effects:
# 1) Force missing values to be explicit (a NaN cell is created)
# 2) Automatic collapsing to the mean if multiple within factors are present
# 3) If using dropna, remove rows with missing values (listwise deletion).
# The latter is the same behavior as JASP (= strict complete-case analysis).
data_piv = data.pivot_table(index=[subject, between], columns=within, values=dv, observed=True)
data_piv = data_piv.dropna()
data = data_piv.melt(ignore_index=False, value_name=dv).reset_index()
# Check that subject IDs do not overlap between groups: the subject ID
# should have a unique range / set of values for each between-subject
# group e.g. group1= 1 --> 20 and group2 = 21 --> 40.
if not (data.groupby([subject, within], observed=True)[between].nunique() == 1).all():
raise ValueError(
"Subject IDs cannot overlap between groups: each "
"group in `%s` must have a unique set of "
"subject IDs, e.g. group1 = [1, 2, 3, ..., 10] "
"and group2 = [11, 12, 13, ..., 20]" % between
)
# SUMS OF SQUARES
grandmean = data[dv].mean(numeric_only=True)
ss_total = ((data[dv] - grandmean) ** 2).sum()
# Extract main effects of within and between factors
aov_with = rm_anova(
dv=dv, within=within, subject=subject, data=data, correction=correction, detailed=True
)
aov_betw = anova(dv=dv, between=between, data=data, detailed=True)
ss_betw = aov_betw.at[0, "SS"]
ss_with = aov_with.at[0, "SS"]
# Extract residuals and interactions
grp = data.groupby([between, within], observed=True, group_keys=False)[dv]
# ssresall = residuals within + residuals between
ss_resall = grp.apply(lambda x: (x - x.mean()) ** 2).sum()
# Interaction
ss_inter = ss_total - (ss_resall + ss_with + ss_betw)
ss_reswith = aov_with.at[1, "SS"] - ss_inter
ss_resbetw = ss_total - (ss_with + ss_betw + ss_reswith + ss_inter)
# DEGREES OF FREEDOM
n_obs = data.groupby(within, observed=True)[dv].count().max()
df_with = aov_with.at[0, "DF"]
df_betw = aov_betw.at[0, "DF"]
df_resbetw = n_obs - data.groupby(between, observed=True)[dv].count().count()
df_reswith = df_with * df_resbetw
df_inter = aov_with.at[0, "DF"] * aov_betw.at[0, "DF"]
# MEAN SQUARES
ms_betw = aov_betw.at[0, "MS"]
ms_with = aov_with.at[0, "MS"]
ms_resbetw = ss_resbetw / df_resbetw
ms_reswith = ss_reswith / df_reswith
ms_inter = ss_inter / df_inter
# F VALUES
f_betw = ms_betw / ms_resbetw
f_with = ms_with / ms_reswith
f_inter = ms_inter / ms_reswith
# P-values
p_betw = f(df_betw, df_resbetw).sf(f_betw)
p_with = f(df_with, df_reswith).sf(f_with)
p_inter = f(df_inter, df_reswith).sf(f_inter)
# Effects sizes (see Bakeman 2005)
if effsize == "n2":
# Standard eta-squared
ef_betw = ss_betw / ss_total
ef_with = ss_with / ss_total
ef_inter = ss_inter / ss_total
elif effsize == "ng2":
# Generalized eta-square
ef_betw = ss_betw / | (data=None, dv=None, within=None, subject=None, between=None, correction='auto', effsize='np2') | [
0.03584129735827446,
-0.01439758576452732,
0.021220585331320763,
0.003041578223928809,
0.013000104576349258,
-0.040891021490097046,
-0.02311129681766033,
-0.09892762452363968,
0.007028511725366116,
0.013129282742738724,
-0.03884764760732651,
0.012459901161491871,
-0.006159489043056965,
0.030204396694898605,
-0.0655289813876152,
0.043545063585042953,
0.013047078624367714,
0.00999962817877531,
0.07168259471654892,
0.018402134999632835,
-0.01714557595551014,
0.0004220336559228599,
-0.053409643471241,
0.02093874104321003,
0.0135755380615592,
0.01344635896384716,
-0.03936436399817467,
-0.06454252451658249,
0.03194244205951691,
0.012295491062104702,
0.008878120221197605,
-0.045799825340509415,
-0.024238675832748413,
0.013516820035874844,
-0.001854012138210237,
-0.05791916325688362,
-0.002194575034081936,
-0.032435670495033264,
-0.0396696962416172,
0.06768979132175446,
-0.004568238742649555,
-0.025366056710481644,
0.07097798585891724,
0.0002480823895893991,
-0.04180701822042465,
-0.00482366094365716,
0.002952033653855324,
0.07830595970153809,
0.010721856728196144,
-0.03429115191102028,
0.031660597771406174,
-0.06961573660373688,
0.019529515877366066,
0.031002959236502647,
0.002243017079308629,
0.10634954273700714,
-0.03180151805281639,
0.049839604645967484,
0.07534658163785934,
-0.08295640349388123,
0.034690432250499725,
0.023733703419566154,
-0.01284743845462799,
-0.03177803382277489,
-0.024191701784729958,
-0.026845743879675865,
0.026728307828307152,
0.0034614098258316517,
-0.023134782910346985,
-0.028842145577073097,
-0.035982221364974976,
0.018167264759540558,
0.022852938622236252,
0.031684085726737976,
0.009500527754426003,
0.010939111933112144,
-0.00403097178786993,
-0.047772739082574844,
0.011943184770643711,
0.0010312300873920321,
0.06228776276111603,
0.007486509624868631,
-0.012037133798003197,
0.002394215203821659,
-0.004306945018470287,
-0.02428564988076687,
-0.0024632085114717484,
0.028654249384999275,
0.07783621549606323,
-0.030979471281170845,
0.03213033825159073,
0.006629230920225382,
0.0305801909416914,
-0.01715731993317604,
-0.011678955517709255,
0.0062299505807459354,
0.0011831620940938592,
-0.026352515444159508,
-0.009459425695240498,
-0.01654665544629097,
-0.014479790814220905,
0.05669783428311348,
0.023651499301195145,
0.060455769300460815,
0.011667211540043354,
0.006153617519885302,
-0.032600078731775284,
0.008848761208355427,
0.016593629494309425,
-0.0033909485209733248,
-0.05068514123558998,
0.031496185809373856,
-0.09451204538345337,
-0.01774449646472931,
-0.01965869404375553,
-0.036240577697753906,
-0.04004548862576485,
0.043826907873153687,
-0.08774776756763458,
0.0081911226734519,
0.03663985803723335,
0.0219604279845953,
-0.04638700187206268,
-0.023052578791975975,
0.021760787814855576,
-0.022453658282756805,
-0.0035612299107015133,
-0.02954675815999508,
-0.012225029990077019,
-0.036498937755823135,
-0.02989906445145607,
-0.007351459003984928,
-0.014984763227403164,
0.01111526507884264,
-0.030204396694898605,
0.018766185268759727,
0.05914049223065376,
-0.04328670725226402,
0.042441170662641525,
-0.04044476896524429,
0.02954675815999508,
0.057966139167547226,
-0.032623566687107086,
-0.059845104813575745,
0.005073211155831814,
-0.0035377428866922855,
0.08286245167255402,
-0.007151818834245205,
-0.009212810546159744,
0.01759183034300804,
-0.018801415339112282,
-0.015360556542873383,
-0.011767031624913216,
-0.03041578084230423,
0.07201141864061356,
-0.019787872210144997,
0.03685124218463898,
-0.039599232375621796,
0.00036955467658117414,
-0.04713859036564827,
-0.03147270157933235,
-0.056932706385850906,
-0.010481113567948341,
0.04143122583627701,
0.017216036096215248,
-0.018331672996282578,
-0.011796390637755394,
-0.009570988826453686,
-0.0069110761396586895,
-0.045189160853624344,
-0.05068514123558998,
0.0202458705753088,
-0.06740795075893402,
0.00671730749309063,
-0.020739100873470306,
0.05618111789226532,
-0.029523272067308426,
-0.03454950824379921,
0.031214341521263123,
-0.05810705944895744,
-0.015630658715963364,
-0.00917170848697424,
-0.022770732641220093,
0.023510577157139778,
-0.06101945787668228,
0.009142349474132061,
0.02430913783609867,
-0.006130130495876074,
0.004486034158617258,
-0.018590031191706657,
-0.03647544980049133,
-0.06416673213243484,
-0.015489735640585423,
0.012154568918049335,
-0.017016395926475525,
-0.012929642572999,
0.02017541043460369,
-0.014973019249737263,
0.046152129769325256,
-0.0629454031586647,
-0.022418426349759102,
-0.020973971113562584,
-0.0026129386387765408,
-0.0001937684864969924,
-0.028912607580423355,
0.0009504931513220072,
-0.015560196712613106,
-0.01938859187066555,
-0.00930675957351923,
-0.02301734872162342,
-0.007750739809125662,
-0.027550356462597847,
0.02187822386622429,
0.0430753231048584,
0.05665086209774017,
-0.03732098639011383,
0.040632665157318115,
-0.025201646611094475,
0.011966671794652939,
0.04514218494296074,
0.0006774557405151427,
-0.06454252451658249,
-0.08478839695453644,
0.06595174968242645,
0.028466353192925453,
0.04798412322998047,
0.05439610034227371,
0.07971518486738205,
0.041830506175756454,
-0.013552051037549973,
-0.022453658282756805,
0.00805607158690691,
0.022629810497164726,
-0.034432072192430496,
-0.014961276203393936,
0.06839440762996674,
-0.022770732641220093,
-0.0146559439599514,
-0.03868323564529419,
0.002607066882774234,
-0.00987044908106327,
-0.04187748208642006,
0.022371452301740646,
0.03283495083451271,
-0.014421072788536549,
-0.0482424832880497,
0.03584129735827446,
0.04833643138408661,
-0.013927844353020191,
-0.02618810534477234,
0.03560642898082733,
-0.024097753688693047,
-0.008038456551730633,
0.03609965741634369,
-0.03332817927002907,
-0.047537870705127716,
0.0344555601477623,
0.004609341267496347,
0.046152129769325256,
-0.04199491813778877,
0.013152769766747952,
-0.0038195878732949495,
0.002254760591313243,
0.013681230135262012,
-0.03337515518069267,
0.026657847687602043,
-0.06872322410345078,
-0.002479356015101075,
0.013023591600358486,
0.008009097538888454,
-0.06092550978064537,
0.003443794557824731,
0.006588128861039877,
0.025577440857887268,
-0.03574734926223755,
0.06369698792695999,
-0.009565116837620735,
0.00770963728427887,
-0.004174830392003059,
-0.011655468493700027,
-0.008901607245206833,
0.02085653506219387,
0.0008279199246317148,
-0.014233176596462727,
-0.0016396924620494246,
-0.04147820174694061,
-0.03161362186074257,
-0.05937536433339119,
0.016558397561311722,
-0.01305882167071104,
-0.06318026781082153,
-0.044343624264001846,
0.044155728071928024,
-0.0025380735751241446,
-0.006952178664505482,
0.05439610034227371,
-0.00853168498724699,
-0.0003145068185403943,
0.002124113729223609,
0.011866851709783077,
0.006764282006770372,
0.02076258696615696,
0.07966820895671844,
0.03504273667931557,
-0.052188314497470856,
0.0016367565840482712,
0.02387462742626667,
-0.05176554620265961,
0.03732098639011383,
-0.07572237402200699,
0.01740393415093422,
0.07764831930398941,
-0.026235079392790794,
0.01782670058310032,
0.04420270398259163,
0.021443713456392288,
-0.013692973181605339,
-0.03328120708465576,
0.06144222617149353,
0.05336266756057739,
-0.022371452301740646,
-0.04495428875088692,
0.046058181673288345,
-0.02119709923863411,
0.07915148884057999,
0.0003623984521254897,
0.04474290460348129,
-0.007891662418842316,
0.018132032826542854,
-0.006388488225638866,
-0.05885864794254303,
-0.04678628221154213,
0.026469949632883072,
-0.014926045201718807,
-0.05068514123558998,
-0.04420270398259163,
-0.014127484522759914,
-0.02534257061779499,
0.06064366549253464,
0.029147477820515633,
0.07703765481710434,
0.028419379144906998,
-0.011896210722625256,
-0.021396739408373833,
0.018049828708171844,
-0.04810155928134918,
0.016417475417256355,
0.0073162284679710865,
-0.0008367275586351752,
-0.010598549619317055,
-0.041407737880945206,
0.026916204020380974,
0.036404989659786224,
0.01911849156022072,
0.046504437923431396,
-0.006141874007880688,
0.00853168498724699,
-0.013176257722079754,
0.008455351926386356,
-0.01722778007388115,
-0.008672608062624931,
0.011338392272591591,
0.006341514177620411,
0.006500052288174629,
0.011796390637755394,
-0.03438510000705719,
-0.011197470128536224,
-0.028583787381649017,
0.0021387930028140545,
-0.02437959983944893,
-0.018766185268759727,
-0.05373845994472504,
0.012483388185501099,
-0.03264705464243889,
0.03696867823600769,
0.005507722496986389,
-0.028043584898114204,
-0.010598549619317055,
0.03955226019024849,
0.014832097105681896,
0.05214133858680725,
-0.0004165288701187819,
-0.05566440150141716,
0.01575983688235283,
0.029194451868534088,
-0.03015742264688015,
0.0019274093210697174,
0.025107698515057564,
-0.013375897891819477,
-0.013739947229623795,
0.05495978891849518,
-0.0063238986767828465,
0.061818018555641174,
-0.006776025518774986,
-0.005205326247960329,
0.017274754121899605,
-0.05627506598830223,
0.0070931012742221355,
-0.06134827807545662,
0.011356008239090443,
-0.0028419378213584423,
-0.01654665544629097,
0.03151967376470566,
-0.014080510474741459,
-0.03917646408081055,
-0.05059118941426277,
0.011643724516034126,
0.0005937829846516252,
-0.02293514274060726,
0.046504437923431396,
-0.02111489325761795,
0.03936436399817467,
-0.028842145577073097,
-0.008396634832024574,
-0.021913453936576843,
0.021760787814855576,
0.010680753737688065,
-0.02231273427605629,
0.014244919642806053,
0.014503277838230133,
0.09061319380998611,
-0.05444307252764702,
0.025741850957274437,
0.046574898064136505,
0.022418426349759102,
-0.012788720428943634,
-0.0964849665760994,
-0.010698369704186916,
-0.02463795617222786,
-0.038049086928367615,
0.025906259194016457,
-0.02076258696615696,
-0.016934191808104515,
-0.03870672360062599,
0.0009438873967155814,
-0.01612388715147972,
-0.06303934752941132,
0.032271262258291245,
0.024097753688693047,
0.04598772153258324,
0.011438212357461452,
0.03544201701879501,
0.02059817686676979,
0.008467095904052258,
-0.027949636802077293,
-0.011256188154220581,
0.016863729804754257,
-0.008091302588582039,
-0.0870431512594223,
-0.03894159570336342,
0.09314979612827301,
0.050544217228889465,
0.04603469744324684,
0.01972915604710579,
-0.055805325508117676,
0.017274754121899605,
0.03919995203614235,
-0.034948788583278656,
-0.05909351631999016,
0.021842993795871735,
-0.03565340116620064,
-0.014244919642806053,
-0.06858230382204056,
0.03910600394010544,
-0.015489735640585423,
0.027785226702690125,
0.01284743845462799,
-0.023228731006383896,
-0.023510577157139778,
0.020621664822101593,
-0.03412673994898796,
-0.033563051372766495,
-0.0024602727498859167,
-0.017814956605434418,
0.042605578899383545,
0.026352515444159508,
-0.02281770668923855,
-0.0293118879199028,
-0.010798189789056778,
0.06670333445072174,
0.03177803382277489,
-0.02921793982386589,
0.011943184770643711,
0.030955983325839043,
0.03461996838450432,
0.013528564013540745,
0.0062182070687413216,
0.011643724516034126,
-0.026681333780288696,
-0.015207890421152115,
-0.01244815718382597,
0.009383092634379864,
0.00037872930988669395,
0.08337917178869247,
-0.048383403569459915,
0.032717514783144,
0.022958630695939064,
-0.02957024611532688,
0.045353569090366364,
-0.07821200788021088,
0.048031099140644073,
-0.03422068804502487,
-0.05961023271083832,
-0.011555648408830166,
0.0370626263320446,
-0.023228731006383896,
-0.010927368886768818,
0.016558397561311722,
-0.015630658715963364,
-0.007891662418842316,
-0.03671032190322876,
-0.0361936055123806,
0.05298687517642975,
-0.0019450245890766382,
0.043545063585042953,
0.00672317948192358,
-0.0017585958121344447,
0.015489735640585423,
0.03673380985856056,
-0.009576860815286636,
0.02809055894613266,
-0.09094201028347015,
-0.0060361819341778755,
0.021678583696484566,
0.019329875707626343,
0.04375644773244858,
-0.020621664822101593,
0.037180062383413315,
0.006617487408220768,
-0.03198941797018051,
-0.008120661601424217,
-0.013587281107902527,
0.057167574763298035,
0.06332119554281235,
0.009259785525500774,
-0.009600347839295864,
-0.007697893772274256,
-0.07276300340890884,
0.0071870493702590466,
0.012166312895715237,
-0.012189799919724464,
0.017368702217936516,
-0.015231377445161343,
-0.03828395530581474,
0.007856431417167187,
0.007692021783441305,
0.0009446213953197002,
-0.0084083778783679,
0.018143776804208755,
-0.01914197765290737,
0.01601819507777691,
-0.02190171182155609,
0.05134277790784836,
0.057778239250183105,
0.008801787160336971,
0.002259164350107312,
0.03654590994119644,
-0.0020639279391616583,
0.0005879112286493182,
-0.02957024611532688,
0.013281948864459991,
-0.04551798105239868,
0.05636901408433914,
-0.08201691508293152,
-0.006335642654448748,
0.027808714658021927,
0.04152517393231392,
0.05373845994472504,
-0.06515318900346756,
-0.031918954104185104,
-0.022336222231388092,
0.04342762753367424,
0.005921682342886925,
-0.009805859997868538,
-0.02282945066690445,
0.0056574526242911816,
0.007416048552840948,
-0.015994708985090256,
-0.045541465282440186,
0.026728307828307152,
-0.02567138895392418,
-0.046316541731357574,
-0.019095003604888916,
0.00521119823679328,
-0.002432381734251976,
0.03032183274626732,
-0.0422062985599041,
0.045118700712919235,
0.016076913103461266,
0.03224777430295944,
-0.06764281541109085,
0.005128993187099695,
-0.03032183274626732,
-0.03135526552796364,
-0.009259785525500774,
0.09300887584686279,
0.007915149442851543,
-0.002767072757706046,
0.06426067650318146,
-0.015712862834334373,
-0.016781525686383247,
0.0070696137845516205,
-0.009764757938683033,
-0.005111377686262131,
0.03429115191102028,
-0.020903509110212326,
0.06797163933515549,
0.015325326472520828,
0.01257733628153801,
-0.026469949632883072,
0.011068291030824184,
0.04843037948012352,
0.013176257722079754,
-0.05763731896877289,
0.034009307622909546,
-0.028207994997501373,
-0.07285695523023605,
-0.013070565648376942,
0.03285843878984451,
-0.0185313131660223,
-0.01577158086001873,
0.023134782910346985,
-0.04030384495854378,
0.05228226259350777,
0.02550697885453701,
0.008091302588582039,
0.031660597771406174,
-0.04255860671401024,
-0.06754887104034424,
-0.105128213763237,
0.009952654130756855,
0.05782521516084671,
0.018496083095669746,
-0.015900759026408195,
0.024919802322983742,
0.0023266898933798075,
0.04587028548121452,
0.025859285145998,
-0.04525962099432945,
0.037861187011003494,
0.042793478816747665,
-0.07346761971712112,
0.018472595140337944,
0.04375644773244858,
0.009664937853813171,
0.03229474648833275,
-0.03931738808751106,
-0.046833258122205734,
-0.0019362169550731778,
0.05336266756057739,
0.04514218494296074,
0.0058130547404289246,
-0.06355606764554977,
-0.029617220163345337,
0.011226829141378403,
0.03917646408081055,
0.06675031036138535,
-0.0016837307484820485,
0.02799661085009575,
0.02809055894613266,
-0.004999814089387655,
-0.0011831620940938592,
-0.01125031616538763,
-0.0012411458883434534,
0.12241470813751221,
0.014879071153700352,
0.04215932637453079,
0.01896582543849945,
0.03483135253190994,
0.07684975862503052,
0.00031615825719200075,
0.040891021490097046,
-0.06679728627204895,
0.042793478816747665,
0.017533112317323685,
-0.03654590994119644,
0.007909277454018593,
-0.017767982557415962,
-0.03342212736606598,
-0.016570141538977623,
0.007275125943124294,
0.03927041217684746,
0.01687547378242016,
-0.06646846234798431,
0.02110314927995205,
-0.05495978891849518,
0.03694519028067589,
-0.03389187157154083,
-0.02428564988076687,
-0.09080109000205994,
-0.059234440326690674,
-0.00416015088558197,
-0.026235079392790794,
0.015231377445161343,
-0.01575983688235283,
-0.01577158086001873,
-0.01826121285557747,
-0.004304009024053812,
0.004022164270281792,
0.009242169559001923,
-0.004776686895638704,
-0.02567138895392418,
0.032717514783144,
0.03927041217684746,
-0.00259532337076962,
0.10418873280286789,
-0.020880023017525673,
0.010058346204459667,
0.019423823803663254,
-0.1025916039943695,
-0.021478943526744843,
0.04154866188764572,
0.018155520781874657,
0.03415022790431976,
0.020445510745048523,
-0.0036346272099763155,
-0.011837493628263474,
0.04927591234445572,
-0.004530072212219238,
0.03661637380719185,
0.01477337907999754,
0.046316541731357574,
0.03375094756484032,
-0.03969318047165871,
-0.03631104156374931,
0.025201646611094475,
0.004471354652196169,
0.0035348068922758102,
0.06092550978064537,
-0.032975874841213226,
0.06073761358857155,
0.015524966642260551,
0.019764386117458344,
0.015501479618251324,
-0.01284743845462799,
-0.004750263877213001,
-0.012553849257528782,
-0.026751795783638954,
-0.007022639736533165,
0.02282945066690445,
0.010997829958796501,
-0.03927041217684746,
-0.023851139470934868,
-0.08647946268320084,
-0.02077433094382286,
0.08431865274906158,
0.010428267531096935,
0.043122295290231705,
0.009929167106747627,
-0.03384489566087723,
0.03567688912153244,
-0.04885314777493477,
0.005440196953713894,
0.03135526552796364,
0.03602919727563858,
0.04781971499323845,
0.05801311135292053,
-0.054771892726421356,
0.0052258772775530815,
-0.048994068056344986,
-0.03067413903772831,
-0.013540307059884071,
0.06336817145347595,
0.08041979372501373,
-0.003341038478538394,
0.022430170327425003,
-0.019705668091773987,
0.04643397778272629
]
|
32,022 | pingouin.multicomp | multicomp | P-values correction for multiple comparisons.
Parameters
----------
pvals : array_like
Uncorrected p-values.
alpha : float
Significance level.
method : string
Method used for testing and adjustment of p-values. Can be either the
full name or initial letters. Available methods are:
* ``'bonf'``: one-step Bonferroni correction
* ``'sidak'``: one-step Sidak correction
* ``'holm'``: step-down method using Bonferroni adjustments
* ``'fdr_bh'``: Benjamini/Hochberg FDR correction
* ``'fdr_by'``: Benjamini/Yekutieli FDR correction
* ``'none'``: pass-through option (no correction applied)
Returns
-------
reject : array, boolean
True for hypothesis that can be rejected for given alpha.
pvals_corrected : array
P-values corrected for multiple testing.
Notes
-----
This function is similar to the `p.adjust
<https://stat.ethz.ch/R-manual/R-devel/library/stats/html/p.adjust.html>`_
R function.
The correction methods include the Bonferroni correction (``'bonf'``)
in which the p-values are multiplied by the number of comparisons.
Less conservative methods are also included such as Sidak (1967)
(``'sidak'``), Holm (1979) (``'holm'``), Benjamini & Hochberg (1995)
(``'fdr_bh'``), and Benjamini & Yekutieli (2001) (``'fdr_by'``),
respectively.
The first three methods are designed to give strong control of the
family-wise error rate. Note that the Holm's method is usually preferred.
The ``'fdr_bh'`` and ``'fdr_by'`` methods control the false discovery rate,
i.e. the expected proportion of false discoveries amongst the rejected
hypotheses. The false discovery rate is a less stringent condition than
the family-wise error rate, so these methods are more powerful than the
others.
The **Bonferroni** [1]_ adjusted p-values are defined as:
.. math::
\widetilde {p}_{{(i)}}= n \cdot p_{{(i)}}
where :math:`n` is the number of *finite* p-values (i.e. excluding NaN).
The **Sidak** [2]_ adjusted p-values are defined as:
.. math::
\widetilde {p}_{{(i)}}= 1 - (1 - p_{{(i)}})^{n}
The **Holm** [3]_ adjusted p-values are the running maximum of the sorted
p-values divided by the corresponding increasing alpha level:
.. math::
\widetilde {p}_{{(i)}}=\max _{{j\leq i}}\left\{(n-j+1)p_{{(j)}}
\right\}_{{1}}
The **Benjamini–Hochberg** procedure (BH step-up procedure, [4]_)
controls the false discovery rate (FDR) at level :math:`\alpha`.
It works as follows:
1. For a given :math:`\alpha`, find the largest :math:`k` such that
:math:`P_{(k)}\leq \frac {k}{n}\alpha.`
2. Reject the null hypothesis for all
:math:`H_{(i)}` for :math:`i = 1, \ldots, k`.
The BH procedure is valid when the :math:`n` tests are independent, and
also in various scenarios of dependence, but is not universally valid.
The **Benjamini–Yekutieli** procedure (BY, [5]_) controls the FDR under
arbitrary dependence assumptions. This refinement modifies the threshold
and finds the largest :math:`k` such that:
.. math::
P_{(k)} \leq \frac{k}{n \cdot c(n)} \alpha
References
----------
.. [1] Bonferroni, C. E. (1935). Il calcolo delle assicurazioni su gruppi
di teste. Studi in onore del professore salvatore ortu carboni, 13-60.
.. [2] Šidák, Z. K. (1967). "Rectangular Confidence Regions for the Means
of Multivariate Normal Distributions". Journal of the American
Statistical Association. 62 (318): 626–633.
.. [3] Holm, S. (1979). A simple sequentially rejective multiple test
procedure. Scandinavian Journal of Statistics, 6, 65–70.
.. [4] Benjamini, Y., and Hochberg, Y. (1995). Controlling the false
discovery rate: a practical and powerful approach to multiple testing.
Journal of the Royal Statistical Society Series B, 57, 289–300.
.. [5] Benjamini, Y., and Yekutieli, D. (2001). The control of the false
discovery rate in multiple testing under dependency. Annals of
Statistics, 29, 1165–1188.
Examples
--------
FDR correction of an array of p-values
>>> import pingouin as pg
>>> pvals = [.50, .003, .32, .054, .0003]
>>> reject, pvals_corr = pg.multicomp(pvals, method='fdr_bh')
>>> print(reject, pvals_corr)
[False True False False True] [0.5 0.0075 0.4 0.09 0.0015]
Holm correction with missing values
>>> import numpy as np
>>> pvals[2] = np.nan
>>> reject, pvals_corr = pg.multicomp(pvals, method='holm')
>>> print(reject, pvals_corr)
[False True False False True] [0.5 0.009 nan 0.108 0.0012]
| def multicomp(pvals, alpha=0.05, method="holm"):
"""P-values correction for multiple comparisons.
Parameters
----------
pvals : array_like
Uncorrected p-values.
alpha : float
Significance level.
method : string
Method used for testing and adjustment of p-values. Can be either the
full name or initial letters. Available methods are:
* ``'bonf'``: one-step Bonferroni correction
* ``'sidak'``: one-step Sidak correction
* ``'holm'``: step-down method using Bonferroni adjustments
* ``'fdr_bh'``: Benjamini/Hochberg FDR correction
* ``'fdr_by'``: Benjamini/Yekutieli FDR correction
* ``'none'``: pass-through option (no correction applied)
Returns
-------
reject : array, boolean
True for hypothesis that can be rejected for given alpha.
pvals_corrected : array
P-values corrected for multiple testing.
Notes
-----
This function is similar to the `p.adjust
<https://stat.ethz.ch/R-manual/R-devel/library/stats/html/p.adjust.html>`_
R function.
The correction methods include the Bonferroni correction (``'bonf'``)
in which the p-values are multiplied by the number of comparisons.
Less conservative methods are also included such as Sidak (1967)
(``'sidak'``), Holm (1979) (``'holm'``), Benjamini & Hochberg (1995)
(``'fdr_bh'``), and Benjamini & Yekutieli (2001) (``'fdr_by'``),
respectively.
The first three methods are designed to give strong control of the
family-wise error rate. Note that the Holm's method is usually preferred.
The ``'fdr_bh'`` and ``'fdr_by'`` methods control the false discovery rate,
i.e. the expected proportion of false discoveries amongst the rejected
hypotheses. The false discovery rate is a less stringent condition than
the family-wise error rate, so these methods are more powerful than the
others.
The **Bonferroni** [1]_ adjusted p-values are defined as:
.. math::
\\widetilde {p}_{{(i)}}= n \\cdot p_{{(i)}}
where :math:`n` is the number of *finite* p-values (i.e. excluding NaN).
The **Sidak** [2]_ adjusted p-values are defined as:
.. math::
\\widetilde {p}_{{(i)}}= 1 - (1 - p_{{(i)}})^{n}
The **Holm** [3]_ adjusted p-values are the running maximum of the sorted
p-values divided by the corresponding increasing alpha level:
.. math::
\\widetilde {p}_{{(i)}}=\\max _{{j\\leq i}}\\left\\{(n-j+1)p_{{(j)}}
\\right\\}_{{1}}
The **Benjamini–Hochberg** procedure (BH step-up procedure, [4]_)
controls the false discovery rate (FDR) at level :math:`\\alpha`.
It works as follows:
1. For a given :math:`\\alpha`, find the largest :math:`k` such that
:math:`P_{(k)}\\leq \\frac {k}{n}\\alpha.`
2. Reject the null hypothesis for all
:math:`H_{(i)}` for :math:`i = 1, \\ldots, k`.
The BH procedure is valid when the :math:`n` tests are independent, and
also in various scenarios of dependence, but is not universally valid.
The **Benjamini–Yekutieli** procedure (BY, [5]_) controls the FDR under
arbitrary dependence assumptions. This refinement modifies the threshold
and finds the largest :math:`k` such that:
.. math::
P_{(k)} \\leq \\frac{k}{n \\cdot c(n)} \\alpha
References
----------
.. [1] Bonferroni, C. E. (1935). Il calcolo delle assicurazioni su gruppi
di teste. Studi in onore del professore salvatore ortu carboni, 13-60.
.. [2] Šidák, Z. K. (1967). "Rectangular Confidence Regions for the Means
of Multivariate Normal Distributions". Journal of the American
Statistical Association. 62 (318): 626–633.
.. [3] Holm, S. (1979). A simple sequentially rejective multiple test
procedure. Scandinavian Journal of Statistics, 6, 65–70.
.. [4] Benjamini, Y., and Hochberg, Y. (1995). Controlling the false
discovery rate: a practical and powerful approach to multiple testing.
Journal of the Royal Statistical Society Series B, 57, 289–300.
.. [5] Benjamini, Y., and Yekutieli, D. (2001). The control of the false
discovery rate in multiple testing under dependency. Annals of
Statistics, 29, 1165–1188.
Examples
--------
FDR correction of an array of p-values
>>> import pingouin as pg
>>> pvals = [.50, .003, .32, .054, .0003]
>>> reject, pvals_corr = pg.multicomp(pvals, method='fdr_bh')
>>> print(reject, pvals_corr)
[False True False False True] [0.5 0.0075 0.4 0.09 0.0015]
Holm correction with missing values
>>> import numpy as np
>>> pvals[2] = np.nan
>>> reject, pvals_corr = pg.multicomp(pvals, method='holm')
>>> print(reject, pvals_corr)
[False True False False True] [0.5 0.009 nan 0.108 0.0012]
"""
# Safety check
assert isinstance(pvals, (list, np.ndarray, Series)), "pvals must be list or array"
assert isinstance(alpha, float), "alpha must be a float."
assert isinstance(method, str), "method must be a string."
assert 0 < alpha < 1, "alpha must be between 0 and 1."
pvals = np.asarray(pvals)
if method.lower() in ["b", "bonf", "bonferroni"]:
reject, pvals_corrected = bonf(pvals, alpha=alpha)
elif method.lower() in ["h", "holm"]:
reject, pvals_corrected = holm(pvals, alpha=alpha)
elif method.lower() in ["s", "sidak"]:
reject, pvals_corrected = sidak(pvals, alpha=alpha)
elif method.lower() in ["fdr", "fdr_bh", "bh"]:
reject, pvals_corrected = fdr(pvals, alpha=alpha, method="fdr_bh")
elif method.lower() in ["fdr_by", "by"]:
reject, pvals_corrected = fdr(pvals, alpha=alpha, method="fdr_by")
elif method.lower() == "none":
pvals_corrected = pvals
with np.errstate(invalid="ignore"):
reject = np.less(pvals_corrected, alpha)
else:
raise ValueError("Multiple comparison method not recognized")
return reject, pvals_corrected
| (pvals, alpha=0.05, method='holm') | [
0.03242960944771767,
0.0028958774637430906,
-0.031100353226065636,
0.011646808125078678,
-0.010143483057618141,
-0.048528365790843964,
0.006234840024262667,
-0.08448155224323273,
0.008007179945707321,
-0.001337167457677424,
-0.016436345875263214,
0.00532229570671916,
0.03131134435534477,
0.013071009889245033,
-0.06574538350105286,
0.04287375509738922,
0.006403634324669838,
0.029306912794709206,
-0.011815601959824562,
0.007215957157313824,
-0.004061613231897354,
0.01929529942572117,
-0.04755779728293419,
0.08389077335596085,
0.04456169903278351,
0.005818129051476717,
0.04074272885918617,
0.0003272038302384317,
-0.02639521099627018,
0.034265246242284775,
0.013587942346930504,
0.03175443038344383,
-0.023778898641467094,
0.013830584473907948,
0.0072212317027151585,
-0.005754831247031689,
0.042071983218193054,
0.00425414415076375,
-0.10102339833974838,
0.02190106175839901,
0.015803366899490356,
-0.056630492210388184,
0.02941240929067135,
-0.020519059151411057,
-0.0027745566330850124,
0.04006754979491234,
0.028547339141368866,
0.08173865079879761,
0.003399623092263937,
0.02996099181473255,
0.0048897601664066315,
-0.026142019778490067,
0.02175336703658104,
0.010111834853887558,
-0.010897782631218433,
0.1168900653719902,
0.03447623923420906,
0.025087054818868637,
-0.0035130316391587257,
-0.08608510345220566,
-0.013271452859044075,
-0.013471896760165691,
0.04329574108123779,
-0.04456169903278351,
0.01649964414536953,
-0.02310372143983841,
0.0022180627565830946,
-0.03899148851633072,
-0.029939891770482063,
0.01101382914930582,
0.014495211653411388,
0.0008657302241772413,
-0.04274716228246689,
-0.006630451884120703,
0.0516088604927063,
0.02609982155263424,
0.03213421627879143,
-0.013640690594911575,
-0.0213630311191082,
-0.027977658435702324,
0.0028800528962165117,
0.033294677734375,
0.05924680456519127,
-0.012142641469836235,
-0.01431586779654026,
-0.010765912011265755,
0.03852730244398117,
0.03780992701649666,
0.09790070354938507,
0.013545744121074677,
-0.03042517602443695,
-0.004599645268172026,
0.0516088604927063,
-0.004240957088768482,
0.011066577397286892,
0.027766665443778038,
-0.00024066376499831676,
0.0028404919430613518,
-0.014864449389278889,
-0.0229349285364151,
-0.004813275299966335,
0.020223669707775116,
0.01897881180047989,
-0.02578333206474781,
0.05008971318602562,
0.000994963338598609,
-0.029011523351073265,
0.034708332270383835,
0.003607978578656912,
-0.045194678008556366,
-0.022112054750323296,
0.019991576671600342,
-0.008518838323652744,
-0.006451107561588287,
-0.02396879345178604,
0.024348579347133636,
-0.0641840398311615,
0.02067730389535427,
-0.010022162459790707,
0.0012646386167034507,
-0.01875726878643036,
0.01454795990139246,
-0.06912127137184143,
0.01273342128843069,
0.031015954911708832,
-0.029159218072891235,
0.03536240756511688,
0.015824466943740845,
-0.020571807399392128,
0.011562410742044449,
-0.012279786169528961,
0.05760106071829796,
0.005733732134103775,
0.008872251026332378,
-0.04692481830716133,
-0.03479272872209549,
-0.02428528293967247,
-0.02190106175839901,
0.05110247805714607,
-0.07135779410600662,
0.04338013753294945,
0.013450796715915203,
0.015497428365051746,
0.039518970996141434,
0.04498368501663208,
-0.02158457227051258,
0.028673933818936348,
0.0005047345766797662,
-0.014421364292502403,
0.06671595573425293,
-0.027618970721960068,
-0.005744281690567732,
0.04608084633946419,
-0.03924467787146568,
0.09165531396865845,
-0.04608084633946419,
0.006008022464811802,
0.007717065047472715,
-0.058402832597494125,
-0.06144113093614578,
0.023610105738043785,
-0.04156560078263283,
0.04333794116973877,
0.07372091710567474,
0.021331381052732468,
-0.02055070735514164,
-0.010554919950664043,
-0.025298047810792923,
0.010734263807535172,
0.02909591980278492,
0.018852215260267258,
-0.03145904093980789,
-0.038168612867593765,
-0.04945673421025276,
-0.07979751378297806,
0.005670433863997459,
0.011056027375161648,
-0.06515460461378098,
0.00739002600312233,
-0.018113739788532257,
-0.015033244155347347,
-0.020656203851103783,
0.006820345297455788,
-0.012406381778419018,
0.022534040734171867,
0.04426630958914757,
0.004662943072617054,
-0.020635105669498444,
-0.017048226669430733,
-0.0005050642648711801,
-0.07275035232305527,
-0.04844396933913231,
0.020244767889380455,
0.032345209270715714,
0.003673913888633251,
-0.03525691106915474,
0.027766665443778038,
0.008381692692637444,
0.08574751019477844,
-0.02458067238330841,
-0.03196542337536812,
-0.002382901031523943,
-0.008719281293451786,
0.004829099867492914,
-0.0032862143125385046,
0.016320301219820976,
-0.036522869020700455,
-0.04319024458527565,
0.05131347104907036,
-0.012016044929623604,
0.02443297766149044,
0.021774467080831528,
0.005971098784357309,
0.002916976809501648,
-0.019970476627349854,
-0.0020664117764681578,
0.0937652438879013,
-0.013703988865017891,
0.018556825816631317,
0.02685939520597458,
-0.00483701191842556,
-0.057643257081508636,
0.031015954911708832,
0.044477302581071854,
0.03354787081480026,
0.053760990500450134,
-0.0030936833936721087,
0.06869928538799286,
0.050764892250299454,
0.016689537093043327,
0.003096320666372776,
0.030214183032512665,
0.01069206465035677,
-0.044308509677648544,
-0.024833863601088524,
-0.03947677090764046,
-0.06355106085538864,
0.0008354000165127218,
-0.08743545413017273,
0.07983971387147903,
0.031269147992134094,
-0.01101382914930582,
-0.017544059082865715,
0.028083154931664467,
0.003085771109908819,
-0.030108686536550522,
0.028420742601156235,
0.027661168947815895,
0.03894928842782974,
0.01176285371184349,
-0.02791436016559601,
-0.055702123790979385,
-0.007975531741976738,
0.013640690594911575,
0.02671170048415661,
-0.04658723250031471,
-0.020044324919581413,
0.011256471276283264,
0.07882694900035858,
-0.007231781259179115,
0.03506701812148094,
-0.011150974780321121,
0.0015916776610538363,
0.04202978312969208,
-0.04209308326244354,
0.00981116946786642,
-0.008835327811539173,
-0.010016887448728085,
0.03886489197611809,
0.012047694064676762,
0.005417242646217346,
-0.04848616570234299,
-0.04523687809705734,
-0.008059928193688393,
-0.013809485360980034,
0.06988084316253662,
0.03135354444384575,
-0.017617907375097275,
0.025762232020497322,
-0.05236843600869179,
0.05025850608944893,
-0.034856025129556656,
0.028230849653482437,
0.014991044998168945,
-0.014991044998168945,
0.08173865079879761,
-0.05519574135541916,
-0.043105848133563995,
0.06312907487154007,
0.022998224943876266,
0.01964343897998333,
-0.06511240452528,
-0.001378047396428883,
-0.004080075304955244,
0.08097907155752182,
0.020793350413441658,
0.024327481165528297,
-0.07481808215379715,
0.05426737293601036,
-0.07030282914638519,
-0.009499954991042614,
-0.03299928829073906,
0.04713581129908562,
-0.03312588483095169,
-0.028716132044792175,
-0.04456169903278351,
0.004834374878555536,
-0.02835744433104992,
-0.028526239097118378,
-0.007337277755141258,
0.03702925145626068,
0.05865602567791939,
-0.03928687795996666,
0.008708731271326542,
0.06857269257307053,
-0.07519786804914474,
0.015339183621108532,
-0.037725530564785004,
0.0366283655166626,
-0.035003721714019775,
-0.02685939520597458,
-0.02308262325823307,
0.01755460910499096,
0.04156560078263283,
-0.03833740949630737,
-0.01851462572813034,
-0.010491621680557728,
0.01161515899002552,
-0.019981026649475098,
-0.008086302317678928,
-0.05447836592793465,
0.034391842782497406,
0.0008815546752884984,
0.01491719763725996,
0.030636169016361237,
0.06452162563800812,
0.02190106175839901,
-0.034560635685920715,
0.06777092069387436,
-0.04422410950064659,
0.02249184250831604,
-0.02175336703658104,
-0.060639359056949615,
0.007996630854904652,
-0.023019324988126755,
0.019432445988059044,
-0.009368084371089935,
0.05304361507296562,
0.04608084633946419,
-0.02671170048415661,
-0.0008578179986216128,
-0.03491932526230812,
-0.007680141367018223,
0.0791645348072052,
0.03582659363746643,
-0.026796096935868263,
-0.03167003393173218,
-0.012406381778419018,
0.04831737279891968,
0.02187996357679367,
0.020360814407467842,
-0.01836693100631237,
0.0036923757288604975,
0.032345209270715714,
-0.029201416298747063,
-0.0036027035675942898,
-0.02119423635303974,
0.00043319480028003454,
-0.0443929061293602,
-0.04304255172610283,
0.009099068120121956,
-0.059289004653692245,
0.038295209407806396,
-0.02077225036919117,
-0.012796718627214432,
0.036396272480487823,
-0.017860548570752144,
0.028821628540754318,
-0.010776462033390999,
0.026353012770414352,
0.011952747590839863,
-0.0671379417181015,
-0.026057623326778412,
0.016288651153445244,
-0.015054343268275261,
-0.003605341073125601,
0.01538138184696436,
-0.035003721714019775,
0.0039139180444180965,
0.0246017724275589,
-0.01138306688517332,
-0.021109839901328087,
-0.014706204645335674,
0.0037029252853244543,
-0.009637100622057915,
0.0540141798555851,
0.01824033632874489,
0.004647118505090475,
-0.030319679528474808,
-0.020054874941706657,
0.021468527615070343,
-0.03991985693573952,
0.013872782699763775,
-0.02101489156484604,
0.0036897382233291864,
-0.04751560091972351,
0.05097588151693344,
0.006904742680490017,
-0.009241488762199879,
0.04937233775854111,
0.015550176613032818,
0.03705035150051117,
-0.003167530754581094,
-0.061694324016571045,
-0.02880053035914898,
0.04527907446026802,
-0.10161417722702026,
-0.019316399469971657,
0.05367659404873848,
-0.031121451407670975,
0.08540992438793182,
-0.06857269257307053,
-0.013598492369055748,
-0.02119423635303974,
-0.02187996357679367,
-0.012775619514286518,
0.00799135584384203,
0.043844323605298996,
-0.049245741218328476,
0.0058550527319312096,
0.006535504944622517,
-0.006329786963760853,
-0.01883111521601677,
-0.03930797800421715,
-0.014748402871191502,
0.00462338188663125,
-0.04405531659722328,
0.05907801166176796,
0.025530140846967697,
-0.054520562291145325,
-0.021795565262436867,
0.051946450024843216,
-0.015898315235972404,
-0.026437409222126007,
0.0012976062716916203,
-0.027112586423754692,
0.03076276369392872,
-0.06426843255758286,
-0.08650708943605423,
-0.025973225012421608,
-0.009700397960841656,
-0.00031550030689686537,
0.02413758635520935,
0.02968670055270195,
0.02202765829861164,
-0.0038136965595185757,
-0.016341399401426315,
0.017586257308721542,
-0.01543413009494543,
-0.008265647105872631,
0.03257730230689049,
0.013693438842892647,
-0.015718970447778702,
-0.0015072805108502507,
-0.011435815133154392,
0.03867499902844429,
0.029496805742383003,
-0.001135405502282083,
-0.0023433398455381393,
0.03468723222613335,
-0.035763297230005264,
-0.0246017724275589,
-0.028378544375300407,
0.04409751668572426,
-0.05384538695216179,
0.02204875834286213,
0.008065203204751015,
0.03213421627879143,
-0.01124592125415802,
-0.014706204645335674,
0.008001905865967274,
-0.014115424826741219,
-0.010423049330711365,
-0.00005728127507609315,
0.037704430520534515,
-0.10186737030744553,
-0.024348579347133636,
-0.0031807178165763617,
-0.014948846772313118,
-0.024095388129353523,
-0.011826151981949806,
-0.07540886104106903,
0.04363333061337471,
0.07346772402524948,
-0.03557340055704117,
-0.014505761675536633,
0.024643970653414726,
-0.03956116735935211,
0.09764751046895981,
-0.07038722932338715,
0.051819853484630585,
-0.0006415502866730094,
-0.04183989018201828,
-0.05802304670214653,
0.07802516967058182,
-0.05890921503305435,
0.006899467669427395,
0.009684573858976364,
-0.03654396906495094,
0.028146451339125633,
-0.026416311040520668,
-0.05565992742776871,
0.05249503254890442,
-0.01984388194978237,
-0.012712322175502777,
0.010802836157381535,
0.018989359959959984,
-0.04226187616586685,
-0.02474946714937687,
-0.004053701180964708,
0.03491932526230812,
-0.011235371232032776,
-0.016858331859111786,
0.07135779410600662,
-0.035489004105329514,
0.026353012770414352,
-0.008529387414455414,
-0.03918138146400452,
-0.010528545826673508,
-0.022238651290535927,
-0.030235281214118004,
-0.012902215123176575,
0.045954253524541855,
0.0358898900449276,
-0.023589005693793297,
0.004866023547947407,
-0.04996311664581299,
-0.017100974917411804,
-0.011773403733968735,
-0.012258687056601048,
0.007284529507160187,
0.09182410687208176,
0.022407446056604385,
-0.05198865011334419,
0.014115424826741219,
-0.026142019778490067,
-0.045490067452192307,
-0.021331381052732468,
-0.009399733506143093,
0.018999909982085228,
0.059584394097328186,
-0.04065833240747452,
0.02354680746793747,
-0.013471896760165691,
0.010528545826673508,
-0.01790274679660797,
0.057516664266586304,
0.02106763981282711,
0.036501768976449966,
-0.01491719763725996,
-0.07760318368673325,
-0.04076382890343666,
-0.010950530879199505,
-0.040573932230472565,
0.0026374112349003553,
0.029011523351073265,
0.0477265939116478,
0.025002658367156982,
-0.04409751668572426,
-0.025762232020497322,
0.01588776521384716,
0.040426239371299744,
-0.02401099167764187,
-0.01679503358900547,
-0.005380318965762854,
-0.026964891701936722,
0.020877746865153313,
-0.06810850650072098,
-0.023905495181679726,
0.007738164626061916,
-0.009974689222872257,
-0.00034846796188503504,
-0.019073758274316788,
-0.07642162591218948,
0.006187366787344217,
0.062158506363630295,
-0.03344237431883812,
0.02415868639945984,
0.0029802746139466763,
0.040426239371299744,
-0.0540141798555851,
-0.009695123881101608,
-0.009125442244112492,
-0.08443935960531235,
-0.006567153614014387,
0.09148652106523514,
0.012522428296506405,
0.019158154726028442,
0.0031965423841029406,
0.033379074186086655,
-0.016362499445676804,
-0.0210887398570776,
-0.04141790419816971,
-0.05895141512155533,
0.03510921820998192,
-0.04008864983916283,
-0.0388437919318676,
-0.0031226947903633118,
0.030551770702004433,
-0.008107402361929417,
0.013893881812691689,
0.032746098935604095,
0.023589005693793297,
-0.04599644988775253,
0.023019324988126755,
0.031142551451921463,
-0.015339183621108532,
0.021004343405365944,
0.022428544238209724,
-0.006751772481948137,
-0.03555230423808098,
0.03266169875860214,
0.0213630311191082,
0.03280939534306526,
-0.004056338220834732,
0.0019015735015273094,
-0.02951790578663349,
-0.08313120156526566,
-0.05409858003258705,
-0.002088829642161727,
0.0005166029441170394,
0.032619502395391464,
0.04038403928279877,
0.025234749540686607,
-0.04979432374238968,
0.009288961999118328,
0.06764432042837143,
-0.014073225669562817,
0.014790602028369904,
-0.005886701866984367,
-0.04688262194395065,
-0.03327357769012451,
0.012606825679540634,
-0.0012138684978708625,
0.004470412153750658,
0.011963296681642532,
-0.046545032411813736,
-0.009900841861963272,
0.04578545689582825,
-0.016119856387376785,
0.015075442381203175,
0.031269147992134094,
-0.07270815223455429,
-0.023905495181679726,
-0.02106763981282711,
-0.023441310971975327,
0.07034502923488617,
0.06435283273458481,
-0.027513474225997925,
-0.0004325354238972068,
-0.001579809351824224,
0.02413758635520935,
-0.0043939268216490746,
0.00247652898542583,
0.017522959038615227,
0.028378544375300407,
0.03251400589942932,
0.011235371232032776,
0.0038136965595185757,
0.03434964269399643,
0.03264060243964195,
0.013239803723990917,
-0.008830052800476551,
0.0194218959659338,
0.029201416298747063,
-0.0035077568609267473,
-0.05502694845199585,
0.016088208183646202,
-0.05228403955698013,
0.008513563312590122,
0.08051488548517227,
0.02040301263332367,
0.0017156359972432256,
-0.010423049330711365,
0.06726453453302383,
0.046798225492239,
0.028589537367224693,
0.05637730285525322,
-0.05574432387948036,
-0.049709927290678024,
0.005649334751069546,
-0.015180938877165318,
0.020318616181612015,
-0.028146451339125633,
0.0050875660963356495,
0.028273047879338264,
-0.04553226754069328,
-0.0038110590539872646,
0.006018572486937046,
-0.023209217935800552,
-0.015307534486055374,
-0.02907482162117958,
-0.009130717255175114,
0.006044946610927582,
-0.010433598421514034,
0.08777304738759995,
-0.011646808125078678,
0.0016444259090349078,
-0.015824466943740845,
-0.09140212088823318,
-0.0540141798555851,
0.06815070658922195,
-0.020561257377266884,
-0.06452162563800812,
-0.007189583033323288,
0.042367372661828995,
0.022723935544490814,
-0.039202481508255005,
0.0014413452008739114,
0.039666663855314255,
-0.01579281874001026,
0.05034290626645088,
0.028737232089042664,
-0.040890421718358994,
-0.019021010026335716,
-0.0041855713352561,
0.07000744342803955,
-0.02546684257686138,
0.014674555510282516,
-0.006757047493010759,
0.008260372094810009,
0.03183882683515549,
-0.04646063596010208,
0.023124821484088898,
0.01981223188340664,
-0.06384644657373428,
0.04515247792005539,
0.008075753226876259,
0.017132623121142387,
0.06371985375881195,
-0.008044104091823101,
-0.03000319004058838,
0.019875530153512955,
-0.018915513530373573,
-0.044772692024707794,
0.04945673421025276,
-0.03989875689148903,
0.01755460910499096,
-0.03268279880285263,
-0.05608190968632698,
-0.025129253044724464,
-0.00868235807865858,
-0.0049820696003735065,
0.042662762105464935,
0.002959175268188119,
-0.007284529507160187,
0.0221964530646801,
-0.020793350413441658,
-0.03371666371822357,
-0.030826061964035034,
-0.06755992770195007,
0.07034502923488617,
0.0693744644522667,
0.0756620541214943,
-0.03207091987133026,
0.017153723165392876,
-0.023736700415611267,
0.03327357769012451
]
|
32,024 | pingouin.multivariate | multivariate_normality | Henze-Zirkler multivariate normality test.
Parameters
----------
X : np.array
Data matrix of shape (n_samples, n_features).
alpha : float
Significance level.
Returns
-------
hz : float
The Henze-Zirkler test statistic.
pval : float
P-value.
normal : boolean
True if X comes from a multivariate normal distribution.
See Also
--------
normality : Test the univariate normality of one or more variables.
homoscedasticity : Test equality of variance.
sphericity : Mauchly's test for sphericity.
Notes
-----
The Henze-Zirkler test [1]_ has a good overall power against alternatives
to normality and works for any dimension and sample size.
Adapted to Python from a Matlab code [2]_ by Antonio Trujillo-Ortiz and
tested against the
`MVN <https://cran.r-project.org/web/packages/MVN/MVN.pdf>`_ R package.
Rows with missing values are automatically removed.
References
----------
.. [1] Henze, N., & Zirkler, B. (1990). A class of invariant consistent
tests for multivariate normality. Communications in Statistics-Theory
and Methods, 19(10), 3595-3617.
.. [2] Trujillo-Ortiz, A., R. Hernandez-Walls, K. Barba-Rojo and L.
Cupul-Magana. (2007). HZmvntest: Henze-Zirkler's Multivariate
Normality Test. A MATLAB file.
Examples
--------
>>> import pingouin as pg
>>> data = pg.read_dataset('multivariate')
>>> X = data[['Fever', 'Pressure', 'Aches']]
>>> pg.multivariate_normality(X, alpha=.05)
HZResults(hz=0.540086101851555, pval=0.7173686509622386, normal=True)
| def multivariate_normality(X, alpha=0.05):
"""Henze-Zirkler multivariate normality test.
Parameters
----------
X : np.array
Data matrix of shape (n_samples, n_features).
alpha : float
Significance level.
Returns
-------
hz : float
The Henze-Zirkler test statistic.
pval : float
P-value.
normal : boolean
True if X comes from a multivariate normal distribution.
See Also
--------
normality : Test the univariate normality of one or more variables.
homoscedasticity : Test equality of variance.
sphericity : Mauchly's test for sphericity.
Notes
-----
The Henze-Zirkler test [1]_ has a good overall power against alternatives
to normality and works for any dimension and sample size.
Adapted to Python from a Matlab code [2]_ by Antonio Trujillo-Ortiz and
tested against the
`MVN <https://cran.r-project.org/web/packages/MVN/MVN.pdf>`_ R package.
Rows with missing values are automatically removed.
References
----------
.. [1] Henze, N., & Zirkler, B. (1990). A class of invariant consistent
tests for multivariate normality. Communications in Statistics-Theory
and Methods, 19(10), 3595-3617.
.. [2] Trujillo-Ortiz, A., R. Hernandez-Walls, K. Barba-Rojo and L.
Cupul-Magana. (2007). HZmvntest: Henze-Zirkler's Multivariate
Normality Test. A MATLAB file.
Examples
--------
>>> import pingouin as pg
>>> data = pg.read_dataset('multivariate')
>>> X = data[['Fever', 'Pressure', 'Aches']]
>>> pg.multivariate_normality(X, alpha=.05)
HZResults(hz=0.540086101851555, pval=0.7173686509622386, normal=True)
"""
from scipy.stats import lognorm
# Check input and remove missing values
X = np.asarray(X)
assert X.ndim == 2, "X must be of shape (n_samples, n_features)."
X = X[~np.isnan(X).any(axis=1)]
n, p = X.shape
assert n >= 3, "X must have at least 3 rows."
assert p >= 2, "X must have at least two columns."
# Covariance matrix
S = np.cov(X, rowvar=False, bias=True)
S_inv = np.linalg.pinv(S, hermitian=True).astype(X.dtype) # Preserving original dtype
difT = X - X.mean(0)
# Squared-Mahalanobis distances
Dj = np.diag(np.linalg.multi_dot([difT, S_inv, difT.T]))
Y = np.linalg.multi_dot([X, S_inv, X.T])
Djk = -2 * Y.T + np.repeat(np.diag(Y.T), n).reshape(n, -1) + np.tile(np.diag(Y.T), (n, 1))
# Smoothing parameter
b = 1 / (np.sqrt(2)) * ((2 * p + 1) / 4) ** (1 / (p + 4)) * (n ** (1 / (p + 4)))
# Is matrix full-rank (columns are linearly independent)?
if np.linalg.matrix_rank(S) == p:
hz = n * (
1 / (n**2) * np.sum(np.sum(np.exp(-(b**2) / 2 * Djk)))
- 2
* ((1 + (b**2)) ** (-p / 2))
* (1 / n)
* (np.sum(np.exp(-((b**2) / (2 * (1 + (b**2)))) * Dj)))
+ ((1 + (2 * (b**2))) ** (-p / 2))
)
else:
hz = n * 4
wb = (1 + b**2) * (1 + 3 * b**2)
a = 1 + 2 * b**2
# Mean and variance
mu = 1 - a ** (-p / 2) * (1 + p * b**2 / a + (p * (p + 2) * (b**4)) / (2 * a**2))
si2 = (
2 * (1 + 4 * b**2) ** (-p / 2)
+ 2
* a ** (-p)
* (1 + (2 * p * b**4) / a**2 + (3 * p * (p + 2) * b**8) / (4 * a**4))
- 4
* wb ** (-p / 2)
* (1 + (3 * p * b**4) / (2 * wb) + (p * (p + 2) * b**8) / (2 * wb**2))
)
# Lognormal mean and variance
pmu = np.log(np.sqrt(mu**4 / (si2 + mu**2)))
psi = np.sqrt(np.log1p(si2 / mu**2))
# P-value
pval = lognorm.sf(hz, psi, scale=np.exp(pmu))
normal = True if pval > alpha else False
HZResults = namedtuple("HZResults", ["hz", "pval", "normal"])
return HZResults(hz=hz, pval=pval, normal=normal)
| (X, alpha=0.05) | [
-0.02168504148721695,
-0.004605413880199194,
0.05502047762274742,
-0.003436122555285692,
0.06535276025533676,
-0.04383780062198639,
-0.07181575894355774,
-0.0222590584307909,
0.013521261513233185,
0.05897480994462967,
-0.01204370241612196,
0.030146460980176926,
0.00845078844577074,
0.021918900310993195,
-0.06437481194734573,
0.032803941518068314,
-0.019272049888968468,
0.04073386266827583,
-0.036226775497198105,
-0.013457481749355793,
-0.049322839826345444,
0.006287598982453346,
0.005479725077748299,
0.07300630956888199,
0.004400787875056267,
-0.03533386439085007,
0.0017765258671715856,
-0.043433863669633865,
-0.0040473430417478085,
0.01585984416306019,
-0.03446220979094505,
-0.005370768252760172,
-0.011565355584025383,
-0.018612993881106377,
0.03210236504673958,
-0.017783859744668007,
0.03916063532233238,
-0.031060634180903435,
-0.0776834711432457,
0.013744490221142769,
0.036503154784440994,
-0.04124410077929497,
0.017369292676448822,
0.026617325842380524,
-0.003943701274693012,
-0.0016130907461047173,
0.022854333743453026,
0.09311812371015549,
0.007828937843441963,
-0.015360238030552864,
-0.040011029690504074,
-0.06314174085855484,
0.03435590863227844,
0.0007281497237272561,
-0.05344725027680397,
0.0531921312212944,
0.038267720490694046,
-0.003834744682535529,
0.028041735291481018,
-0.019038191065192223,
0.01836850680410862,
-0.004916339181363583,
0.019165750592947006,
-0.0013294046511873603,
-0.034568507224321365,
-0.06781890243291855,
-0.009152363054454327,
0.014828741550445557,
0.02417244389653206,
0.016380710527300835,
-0.0018814962822943926,
0.024236222729086876,
0.04936536028981209,
0.026213388890028,
0.027531499043107033,
0.09371339529752731,
-0.04532599076628685,
-0.03590787947177887,
-0.029593704268336296,
0.0345047302544117,
0.011097638867795467,
0.04762205481529236,
-0.015647245571017265,
-0.006500197574496269,
-0.027021262794733047,
-0.03675827383995056,
0.024874018505215645,
0.02103661745786667,
0.06322678178548813,
0.029848823323845863,
-0.04226457327604294,
0.010098426602780819,
0.07900158315896988,
0.027999216690659523,
-0.005112992599606514,
0.00041988195152953267,
-0.015392127446830273,
0.014201576821506023,
0.06093071773648262,
-0.029338587075471878,
0.008684646338224411,
0.028084255754947662,
0.059570085257291794,
0.10459844022989273,
-0.0010144932894036174,
0.035674020648002625,
-0.0073931110091507435,
0.008387008681893349,
0.014339765533804893,
-0.014318505302071571,
-0.032081104815006256,
0.0147755928337574,
-0.0413716584444046,
-0.056253548711538315,
0.01129960734397173,
-0.10077166557312012,
-0.028126774355769157,
0.04354016110301018,
-0.03497244417667389,
0.014042127877473831,
-0.019505908712744713,
0.017964569851756096,
-0.04881260544061661,
-0.0036301184445619583,
-0.004254626575857401,
-0.06947717070579529,
0.0378425233066082,
-0.044900793582201004,
-0.002544537652283907,
-0.0023957188241183758,
0.004759547766298056,
0.055998433381319046,
0.045836225152015686,
-0.003425492439419031,
-0.025065356865525246,
-0.0520441010594368,
0.037693705409765244,
-0.030529137700796127,
0.08733544498682022,
-0.08401890844106674,
0.009492521174252033,
-0.02298189327120781,
-0.04354016110301018,
-0.007685434073209763,
0.024066144600510597,
0.003909153863787651,
0.11811970174312592,
-0.036864571273326874,
0.01781575009226799,
-0.031804729253053665,
0.017751971259713173,
-0.04120158031582832,
0.046388983726501465,
-0.0492803193628788,
-0.002423622412607074,
-0.07185827940702438,
0.014063387177884579,
-0.040011029690504074,
-0.022918112576007843,
0.01596614345908165,
-0.002523277886211872,
-0.03171968832612038,
-0.003901181509718299,
0.012341340072453022,
-0.03348425775766373,
-0.0010855807922780514,
-0.0034228351432830095,
0.0016928152181208134,
0.014541734009981155,
-0.04200945422053337,
-0.006144095212221146,
0.016221262514591217,
-0.08095748722553253,
0.029487404972314835,
-0.0015998033341020346,
0.003268701257184148,
-0.008100001141428947,
-0.005527559667825699,
0.005059842951595783,
0.011661024764180183,
0.0022920770570635796,
-0.037608664482831955,
-0.0441354401409626,
-0.022280316799879074,
-0.036396853625774384,
0.02657480724155903,
0.07474961876869202,
-0.017868900671601295,
-0.02215275913476944,
0.024044884368777275,
-0.04983307793736458,
-0.08287087827920914,
-0.0013779037399217486,
0.016869686543941498,
0.03320787847042084,
0.032463785260915756,
0.006957284174859524,
-0.02342834882438183,
0.03148582950234413,
-0.03684331104159355,
-0.013595671392977238,
0.023832285776734352,
-0.026468507945537567,
0.0030401579570025206,
0.0013260828563943505,
-0.038735438138246536,
-0.0033218509051948786,
-0.0018854824593290687,
-0.0407976433634758,
-0.005142224952578545,
-0.010093111544847488,
-0.06258898228406906,
-0.05157638341188431,
0.05676378682255745,
0.005841142497956753,
-0.0591023713350296,
0.05149134621024132,
-0.01567913591861725,
0.027765357866883278,
-0.01319173350930214,
-0.02833937294781208,
-0.046474020928144455,
-0.02714882232248783,
0.06811654567718506,
-0.011809843592345715,
0.05803937837481499,
0.05370236933231354,
0.03637559339404106,
0.005208662245422602,
-0.03947953134775162,
0.026532286778092384,
0.03739606589078903,
0.03433464840054512,
-0.03722598776221275,
-0.07708819955587387,
-0.021812601014971733,
-0.034207090735435486,
0.01726299338042736,
-0.036524415016174316,
0.004600098822265863,
0.00044778548181056976,
-0.08601733297109604,
0.01975039578974247,
0.015647245571017265,
-0.04996063560247421,
-0.03303780034184456,
0.01661456935107708,
0.04881260544061661,
0.018049608916044235,
0.023704728111624718,
-0.05629606917500496,
-0.030040161684155464,
0.04354016110301018,
0.011618505232036114,
0.008413583971560001,
-0.04855748638510704,
0.055998433381319046,
0.0650126039981842,
0.05944252759218216,
-0.05850709229707718,
-0.031996067613363266,
-0.03737480938434601,
-0.012649607844650745,
0.0528094545006752,
-0.03831024095416069,
-0.01218189112842083,
-0.015583466738462448,
0.05102362856268883,
0.03673701360821724,
0.023215750232338905,
0.0013898623874410987,
-0.0055009848438203335,
-0.05752914026379585,
-0.06139843165874481,
0.029487404972314835,
0.03499370440840721,
0.009450000710785389,
-0.04681417718529701,
0.036864571273326874,
0.0685417428612709,
0.009869882836937904,
-0.029593704268336296,
-0.0010423967614769936,
0.0034600398503243923,
-0.007956497371196747,
0.040032289922237396,
-0.04183937609195709,
-0.062248826026916504,
0.041499216109514236,
-0.0191126000136137,
-0.021302364766597748,
-0.0465165413916111,
-0.06237638741731644,
0.005171457305550575,
0.015806695446372032,
0.007818307727575302,
-0.05234174057841301,
-0.04349764436483383,
0.054510243237018585,
-0.042711030691862106,
0.030954334884881973,
0.01223504077643156,
0.06794646382331848,
-0.04113779962062836,
-0.03497244417667389,
0.005421260371804237,
-0.009258662350475788,
-0.020738979801535606,
0.00349458702839911,
-0.018017718568444252,
0.009258662350475788,
0.03767244517803192,
-0.03286772221326828,
-0.003964961040765047,
0.001997096696868539,
-0.04237087070941925,
0.03643937408924103,
-0.008105316199362278,
0.04779213294386864,
0.06888189911842346,
-0.031166933476924896,
-0.0066011818125844,
0.03996850922703743,
0.022046459838747978,
0.028637010604143143,
-0.05417008697986603,
0.010518308728933334,
-0.015381498262286186,
-0.000016245927326963283,
-0.059867724776268005,
-0.04030866548418999,
-0.03458976745605469,
0.02731890045106411,
0.04354016110301018,
-0.036694493144750595,
0.012022442184388638,
0.011767324060201645,
-0.010316340252757072,
0.020983466878533363,
-0.06752126663923264,
-0.0032049217261373997,
0.00946594588458538,
-0.04054252430796623,
0.022662995383143425,
-0.01616811193525791,
-0.06360945850610733,
0.009157678112387657,
-0.025405514985322952,
0.003848031861707568,
0.004608071409165859,
-0.00020927659352310002,
-0.01024193037301302,
0.06794646382331848,
0.07228347659111023,
0.06165355071425438,
0.012883465737104416,
-0.011374017223715782,
-0.0661606416106224,
-0.013138583861291409,
0.003800197271630168,
0.017603151500225067,
0.04067008197307587,
-0.053319692611694336,
0.002761122304946184,
0.007425000891089439,
-0.06241890415549278,
0.008142520673573017,
0.03950079157948494,
0.06237638741731644,
-0.03320787847042084,
0.008860040456056595,
-0.07993701845407486,
-0.048600006848573685,
-0.002021013991907239,
0.007876772433519363,
-0.011788584291934967,
0.012468899600207806,
0.008801575750112534,
-0.01939960941672325,
-0.0191126000136137,
0.06671339273452759,
-0.011331497691571712,
-0.054510243237018585,
-0.0033431106712669134,
0.005835827440023422,
-0.007371851243078709,
0.006882874760776758,
-0.013287403620779514,
0.011884253472089767,
-0.03035905957221985,
-0.0033750003203749657,
0.016635829582810402,
0.06467244774103165,
-0.040478743612766266,
-0.013468111865222454,
0.059570085257291794,
0.04311496764421463,
-0.0033351383171975613,
-0.06343937665224075,
0.006516142748296261,
-0.013127954676747322,
-0.05455276370048523,
-0.0066277566365897655,
0.011459056288003922,
-0.045453548431396484,
-0.10119686275720596,
0.023683467879891396,
-0.029317326843738556,
0.0012483515311032534,
0.04779213294386864,
-0.024300003424286842,
0.033739373087882996,
-0.056806307286024094,
-0.04949291795492172,
-0.007940552197396755,
0.03195354714989662,
-0.003877264214679599,
-0.03996850922703743,
0.009694489650428295,
0.031974807381629944,
0.019867325201630592,
-0.04400787875056267,
0.03376063331961632,
0.019718505442142487,
0.03943701088428497,
0.004953544121235609,
-0.0891212671995163,
-0.025533074513077736,
-0.05667874589562416,
-0.006420473102480173,
-0.0017499510431662202,
-0.008333859033882618,
-0.02723386138677597,
0.003295276081189513,
-0.0030082680750638247,
0.003441437380388379,
-0.03127323091030121,
0.04220079258084297,
-0.008206300437450409,
-0.04596378654241562,
0.011565355584025383,
0.0780661478638649,
-0.010443898849189281,
-0.0191126000136137,
-0.007892717607319355,
0.036524415016174316,
0.04247717186808586,
-0.057274021208286285,
-0.02050512097775936,
-0.007366536185145378,
0.029125988483428955,
0.05059843137860298,
0.044433075934648514,
-0.0019545769318938255,
-0.013340553268790245,
0.0034706697333604097,
-0.006478937808424234,
-0.011777954176068306,
0.009359646588563919,
0.024491341784596443,
-0.006611811928451061,
0.05472284182906151,
-0.02123858593404293,
0.00003863727761199698,
0.015466537326574326,
-0.03446220979094505,
0.04949291795492172,
-0.007377166301012039,
0.0370771698653698,
0.013999608345329762,
0.024129923433065414,
0.053574807941913605,
-0.02232283726334572,
0.024788979440927505,
-0.004740945529192686,
0.0005567421903833747,
-0.06173859164118767,
0.005426575429737568,
0.00461338646709919,
0.008115946315228939,
0.01476496271789074,
-0.0014523131540045142,
0.044262997806072235,
-0.01227756030857563,
0.0583370141685009,
-0.04392284154891968,
0.05638111010193825,
0.004073917865753174,
0.05646614730358124,
-0.04468819499015808,
0.01845354586839676,
-0.003871949389576912,
0.03939449414610863,
0.08440158516168594,
-0.024214964359998703,
-0.03986220806837082,
0.055062998086214066,
-0.028934650123119354,
0.034207090735435486,
-0.04485827311873436,
-0.0026654531247913837,
0.02113228663802147,
-0.03930945321917534,
-0.04071260243654251,
0.04604882374405861,
0.01577480509877205,
0.031974807381629944,
0.028084255754947662,
-0.021366143599152565,
0.02279055491089821,
-0.03886299580335617,
-0.05850709229707718,
0.011097638867795467,
-0.04825984686613083,
0.00914173386991024,
0.028913389891386032,
-0.042711030691862106,
0.04579370468854904,
-0.01930394023656845,
0.0033351383171975613,
0.0407976433634758,
0.03533386439085007,
-0.016550788655877113,
-0.0037656500935554504,
0.0013001724146306515,
0.09439371526241302,
-0.03322913870215416,
0.006532087456434965,
0.02593701146543026,
0.03750236704945564,
-0.06458740681409836,
-0.06926457583904266,
-0.028870869427919388,
0.06828662008047104,
-0.006691536400467157,
-0.039266932755708694,
-0.0603354386985302,
-0.031124413013458252,
0.008291339501738548,
-0.03171968832612038,
0.0007148623117245734,
0.0035238193813711405,
0.038076382130384445,
-0.04643150046467781,
0.044348038733005524,
0.0207814984023571,
-0.02242913655936718,
0.06964725255966187,
-0.03933071345090866,
0.010948820039629936,
0.06543780118227005,
-0.04405039921402931,
-0.0032421264331787825,
-0.006340748630464077,
0.03773622587323189,
0.0345047302544117,
-0.034929923713207245,
0.009885828010737896,
-0.034568507224321365,
0.012809056788682938,
-0.0047250003553926945,
-0.032442525029182434,
0.022726774215698242,
-0.009109843522310257,
-0.06722363084554672,
-0.00011668000661302358,
0.018995672464370728,
0.021812601014971733,
-0.07560000568628311,
0.016837798058986664,
-0.016200002282857895,
0.064629927277565,
-0.0012543308548629284,
0.014350395649671555,
-0.029572444036602974,
0.030252760276198387,
0.02823307365179062,
-0.050258275121450424,
0.0014749018009752035,
-0.00858366210013628,
0.0032049217261373997,
-0.04991811513900757,
0.005601969081908464,
-0.004841929767280817,
0.017603151500225067,
0.00351850432343781,
-0.06203622743487358,
0.02124921604990959,
0.010906300507485867,
0.05225669965147972,
-0.08031969517469406,
-0.01125708781182766,
-0.002846161834895611,
-0.06080315634608269,
0.006101575680077076,
0.015498426742851734,
0.035036224871873856,
-0.025766931474208832,
0.06131339445710182,
0.003582283854484558,
-0.030486617237329483,
0.01650827005505562,
-0.040393706411123276,
-0.05132126435637474,
0.05144882574677467,
-0.017029136419296265,
0.022769294679164886,
-0.015998033806681633,
0.02141929417848587,
-0.046388983726501465,
-0.004974803887307644,
0.008206300437450409,
-0.007983071729540825,
0.042966146022081375,
0.05391496792435646,
0.010034646838903427,
0.02519291639328003,
-0.04919528216123581,
0.0725385919213295,
-0.007680119015276432,
-0.0029205712489783764,
0.03248504176735878,
0.036226775497198105,
0.02317323163151741,
0.020164962857961655,
-0.06841418147087097,
0.024151183664798737,
-0.07628032565116882,
-0.01509448979049921,
-0.04541102796792984,
-0.015615356154739857,
0.02077086828649044,
0.002197736408561468,
-0.0072230324149131775,
-0.002633563242852688,
-0.009992127306759357,
0.0036327759735286236,
-0.005649803671985865,
0.003582283854484558,
0.037608664482831955,
-0.041180320084095,
0.011916142888367176,
0.029402365908026695,
-0.024129923433065414,
0.025554334744811058,
0.019250789657235146,
0.0051183076575398445,
0.023045672103762627,
0.05744410306215286,
-0.008477362804114819,
0.009907088242471218,
-0.028403153643012047,
-0.05178898200392723,
0.04549606889486313,
-0.017762601375579834,
-0.014297246001660824,
0.006792520638555288,
0.03877795860171318,
0.010066536255180836,
-0.03637559339404106,
-0.003941043745726347,
-0.01681653782725334,
-0.04800473153591156,
0.015742914751172066,
0.051193706691265106,
0.0009786172304302454,
0.012107482179999352,
-0.01385078951716423,
-0.05748661980032921,
0.00646299310028553,
-0.005009350832551718,
0.014701182954013348,
-0.03314409777522087,
-0.033462997525930405,
-0.009949607774615288,
-0.01319173350930214,
-0.017581891268491745,
0.009768898598849773,
-0.04949291795492172,
0.03010394051671028,
0.07755591720342636,
0.03580157831311226,
-0.0017379923956468701,
0.024703940376639366,
0.05540315806865692,
0.0370771698653698,
0.010560828261077404,
-0.03916063532233238,
-0.05374488979578018,
-0.030507877469062805,
-0.03756614774465561,
-0.013659450225532055,
0.004770177882164717,
0.02427874319255352,
0.0583370141685009,
0.010938189923763275,
-0.01690157689154148,
0.05799685791134834,
0.031145673245191574,
-0.040202368050813675,
0.0005251846159808338,
-0.0009832677897065878,
-0.016869686543941498,
0.05047087371349335,
-0.021206695586442947,
0.04090394079685211,
-0.010778741911053658,
0.0008337845792993903,
0.06203622743487358,
-0.02991260215640068,
-0.05051339045166969,
0.010167520493268967,
0.0591023713350296,
-0.002274803351610899,
0.04949291795492172,
0.019516536965966225,
-0.002241584938019514,
-0.000344143743859604,
0.024129923433065414,
0.02833937294781208,
0.043965358287096024,
-0.007754528429359198,
0.03312283754348755,
0.0007175197824835777,
-0.06769134849309921,
-0.02925354614853859,
0.056891344487667084,
-0.02187637984752655,
0.0583370141685009,
0.006287598982453346,
-0.004738288000226021,
0.028828350827097893,
-0.025830712169408798,
0.03312283754348755,
-0.008009647019207478,
-0.021398033946752548,
-0.006197244860231876,
-0.001223769853822887,
0.025873230770230293,
0.03242126479744911,
-0.007600394543260336,
0.01559409685432911,
0.010502363555133343,
-0.04745197296142578,
0.06190866976976395,
0.029657483100891113,
0.009210827760398388,
0.042137011885643005,
0.021557483822107315,
-0.05212914198637009,
0.00457086693495512,
-0.050258275121450424,
-0.0437527596950531,
0.044900793582201004,
0.05863465368747711,
0.042774807661771774,
0.03446220979094505,
-0.04791969060897827,
0.005272441543638706,
-0.06399213522672653,
-0.027191342785954475,
-0.0138933090493083,
0.02751023881137371,
0.07819370925426483,
-0.04062756523489952,
0.03703464940190315,
0.025958271697163582,
0.03971339017152786
]
|
32,025 | pingouin.multivariate | multivariate_ttest | Hotelling T-squared test (= multivariate T-test)
Parameters
----------
X : np.array
First data matrix of shape (n_samples, n_features).
Y : np.array or None
Second data matrix of shape (n_samples, n_features). If ``Y`` is a 1D
array of shape (n_features), a one-sample test is performed where the
null hypothesis is defined in ``Y``. If ``Y`` is None, a one-sample
is performed against np.zeros(n_features).
paired : boolean
Specify whether the two observations are related (i.e. repeated
measures) or independent. If ``paired`` is True, ``X`` and ``Y`` must
have exactly the same shape.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'T2'``: T-squared value
* ``'F'``: F-value
* ``'df1'``: first degree of freedom
* ``'df2'``: second degree of freedom
* ``'p-val'``: p-value
See Also
--------
multivariate_normality : Multivariate normality test.
ttest : Univariate T-test.
Notes
-----
The Hotelling 's T-squared test [1]_ is the multivariate counterpart of
the T-test.
Rows with missing values are automatically removed using the
:py:func:`remove_na` function.
Tested against the `Hotelling
<https://cran.r-project.org/web/packages/Hotelling/Hotelling.pdf>`_ R
package.
References
----------
.. [1] Hotelling, H. The Generalization of Student's Ratio. Ann. Math.
Statist. 2 (1931), no. 3, 360--378.
See also http://www.real-statistics.com/multivariate-statistics/
Examples
--------
Two-sample independent Hotelling T-squared test
>>> import pingouin as pg
>>> data = pg.read_dataset('multivariate')
>>> dvs = ['Fever', 'Pressure', 'Aches']
>>> X = data[data['Condition'] == 'Drug'][dvs]
>>> Y = data[data['Condition'] == 'Placebo'][dvs]
>>> pg.multivariate_ttest(X, Y)
T2 F df1 df2 pval
hotelling 4.228679 1.326644 3 32 0.282898
Two-sample paired Hotelling T-squared test
>>> pg.multivariate_ttest(X, Y, paired=True)
T2 F df1 df2 pval
hotelling 4.468456 1.314252 3 15 0.306542
One-sample Hotelling T-squared test with a specified null hypothesis
>>> null_hypothesis_means = [37.5, 70, 5]
>>> pg.multivariate_ttest(X, Y=null_hypothesis_means)
T2 F df1 df2 pval
hotelling 253.230991 74.479703 3 15 3.081281e-09
| def multivariate_ttest(X, Y=None, paired=False):
"""Hotelling T-squared test (= multivariate T-test)
Parameters
----------
X : np.array
First data matrix of shape (n_samples, n_features).
Y : np.array or None
Second data matrix of shape (n_samples, n_features). If ``Y`` is a 1D
array of shape (n_features), a one-sample test is performed where the
null hypothesis is defined in ``Y``. If ``Y`` is None, a one-sample
is performed against np.zeros(n_features).
paired : boolean
Specify whether the two observations are related (i.e. repeated
measures) or independent. If ``paired`` is True, ``X`` and ``Y`` must
have exactly the same shape.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'T2'``: T-squared value
* ``'F'``: F-value
* ``'df1'``: first degree of freedom
* ``'df2'``: second degree of freedom
* ``'p-val'``: p-value
See Also
--------
multivariate_normality : Multivariate normality test.
ttest : Univariate T-test.
Notes
-----
The Hotelling 's T-squared test [1]_ is the multivariate counterpart of
the T-test.
Rows with missing values are automatically removed using the
:py:func:`remove_na` function.
Tested against the `Hotelling
<https://cran.r-project.org/web/packages/Hotelling/Hotelling.pdf>`_ R
package.
References
----------
.. [1] Hotelling, H. The Generalization of Student's Ratio. Ann. Math.
Statist. 2 (1931), no. 3, 360--378.
See also http://www.real-statistics.com/multivariate-statistics/
Examples
--------
Two-sample independent Hotelling T-squared test
>>> import pingouin as pg
>>> data = pg.read_dataset('multivariate')
>>> dvs = ['Fever', 'Pressure', 'Aches']
>>> X = data[data['Condition'] == 'Drug'][dvs]
>>> Y = data[data['Condition'] == 'Placebo'][dvs]
>>> pg.multivariate_ttest(X, Y)
T2 F df1 df2 pval
hotelling 4.228679 1.326644 3 32 0.282898
Two-sample paired Hotelling T-squared test
>>> pg.multivariate_ttest(X, Y, paired=True)
T2 F df1 df2 pval
hotelling 4.468456 1.314252 3 15 0.306542
One-sample Hotelling T-squared test with a specified null hypothesis
>>> null_hypothesis_means = [37.5, 70, 5]
>>> pg.multivariate_ttest(X, Y=null_hypothesis_means)
T2 F df1 df2 pval
hotelling 253.230991 74.479703 3 15 3.081281e-09
"""
from scipy.stats import f
x = np.asarray(X)
assert x.ndim == 2, "x must be of shape (n_samples, n_features)"
if Y is None:
y = np.zeros(x.shape[1])
# Remove rows with missing values in x
x = x[~np.isnan(x).any(axis=1)]
else:
nx, kx = x.shape
y = np.asarray(Y)
assert y.ndim in [1, 2], "Y must be 1D or 2D."
if y.ndim == 1:
# One sample with specified null
assert y.size == kx
else:
# Two-sample
err = "X and Y must have the same number of features (= columns)."
assert y.shape[1] == kx, err
if paired:
err = "X and Y must have the same number of rows if paired."
assert y.shape[0] == nx, err
# Remove rows with missing values in both x and y
x, y = remove_na(x, y, paired=paired, axis="rows")
# Shape of arrays
nx, k = x.shape
ny = y.shape[0]
assert nx >= 5, "At least five samples are required."
if y.ndim == 1 or paired is True:
n = nx
if y.ndim == 1:
# One sample test
cov = np.cov(x, rowvar=False)
diff = x.mean(0) - y
else:
# Paired two sample
cov = np.cov(x - y, rowvar=False)
diff = x.mean(0) - y.mean(0)
inv_cov = np.linalg.pinv(cov, hermitian=True)
t2 = (diff @ inv_cov) @ diff * n
else:
n = nx + ny - 1
x_cov = np.cov(x, rowvar=False)
y_cov = np.cov(y, rowvar=False)
pooled_cov = ((nx - 1) * x_cov + (ny - 1) * y_cov) / (n - 1)
inv_cov = np.linalg.pinv((1 / nx + 1 / ny) * pooled_cov, hermitian=True)
diff = x.mean(0) - y.mean(0)
t2 = (diff @ inv_cov) @ diff
# F-value, degrees of freedom and p-value
fval = t2 * (n - k) / (k * (n - 1))
df1 = k
df2 = n - k
pval = f.sf(fval, df1, df2)
# Create output dictionnary
stats = {"T2": t2, "F": fval, "df1": df1, "df2": df2, "pval": pval}
stats = pd.DataFrame(stats, index=["hotelling"])
return _postprocess_dataframe(stats)
| (X, Y=None, paired=False) | [
0.034675806760787964,
-0.02313918061554432,
0.04557517543435097,
-0.033005744218826294,
0.031071985140442848,
-0.04120224341750145,
-0.039246510714292526,
0.016019431874155998,
0.047816578298807144,
-0.004793194122612476,
-0.017096184194087982,
0.0017758166650310159,
0.013920865021646023,
0.012723253108561039,
-0.020183606073260307,
0.04799237474799156,
-0.0004281599831301719,
-0.013338539749383926,
0.024040136486291885,
0.00901505071669817,
-0.02055717259645462,
-0.05713377892971039,
-0.010663140565156937,
0.028874533250927925,
-0.012986946851015091,
-0.031071985140442848,
-0.02937994711101055,
-0.05269492417573929,
0.04025733843445778,
-0.000506100885104388,
-0.032829947769641876,
-0.05366180092096329,
-0.04649810492992401,
0.021271344274282455,
-0.011789334937930107,
-0.020480262115597725,
-0.022490931674838066,
-0.02496306598186493,
-0.005260153207927942,
0.04285033419728279,
0.01723901927471161,
-0.053837597370147705,
-0.0035296587739139795,
0.006174842827022076,
-0.00679562333971262,
0.02401816099882126,
-0.015656853094697,
0.0256662517786026,
-0.01906290464103222,
-0.017129145562648773,
0.0038922387175261974,
-0.07128537446260452,
-0.018447617068886757,
0.02630351297557354,
-0.03788409009575844,
0.04865160956978798,
0.0038098341319710016,
-0.03003918193280697,
0.005630973260849714,
-0.04089460149407387,
0.03223663568496704,
0.044256702065467834,
0.019513383507728577,
0.07444971054792404,
-0.0389828160405159,
-0.044652245938777924,
-0.023029306903481483,
0.008081133477389812,
0.013415450230240822,
0.019469434395432472,
-0.03645574674010277,
0.04232294484972954,
0.012668316252529621,
0.0019818278960883617,
0.017173094674944878,
0.043377723544836044,
-0.016414973884820938,
-0.039664026349782944,
-0.022205263376235962,
-0.019513383507728577,
-0.055419765412807465,
0.023754466325044632,
-0.02155701443552971,
-0.002143890131264925,
-0.034104470163583755,
0.031115934252738953,
0.03841147944331169,
0.05823250487446785,
0.03254427760839462,
0.011190528981387615,
-0.016041407361626625,
-0.003631290979683399,
0.02773185633122921,
-0.027995551005005836,
0.03436816483736038,
-0.04522358253598213,
-0.03186306729912758,
0.031071985140442848,
-0.025864021852612495,
-0.02891848236322403,
0.029511794447898865,
-0.006504460703581572,
0.05045352131128311,
0.11110322177410126,
0.03170924633741379,
-0.0024460398126393557,
-0.026479309424757957,
0.05774906650185585,
-0.004856371320784092,
-0.018689338117837906,
-0.03707103058695793,
-0.01465701125562191,
0.02836911752820015,
-0.018799209967255592,
0.0025600327644497156,
-0.06205607205629349,
-0.03375287726521492,
0.07036244869232178,
-0.07093378156423569,
-0.031885042786598206,
0.037752240896224976,
0.021117523312568665,
-0.010119271464645863,
-0.025973893702030182,
-0.027138544246554375,
-0.03359905630350113,
0.03676338866353035,
0.021117523312568665,
-0.009207327850162983,
-0.011316883377730846,
0.020293477922677994,
0.013239654712378979,
0.023908289149403572,
0.06302294880151749,
-0.05150830000638962,
-0.03146752715110779,
0.04706944152712822,
-0.01223981287330389,
0.08266818523406982,
-0.10829048603773117,
0.05792485922574997,
0.003026991616934538,
-0.05493632331490517,
-0.0005905654979869723,
0.021084561944007874,
0.022699689492583275,
0.018689338117837906,
-0.006196817383170128,
0.050189826637506485,
0.01916179060935974,
-0.028259245678782463,
-0.03816976025700569,
0.01849156618118286,
-0.08420640230178833,
0.011124606244266033,
-0.002348527777940035,
0.048124220222234726,
-0.006207804661244154,
0.025094913318753242,
-0.028347143903374672,
-0.01821688562631607,
-0.06086944788694382,
-0.03627995029091835,
0.0765153169631958,
0.019777076318860054,
-0.002348527777940035,
0.0020010557491332293,
0.015349209308624268,
0.014382329769432545,
-0.022490931674838066,
-0.015085514634847641,
-0.006905496120452881,
0.006746180821210146,
-0.0171511210501194,
0.007344986777752638,
-0.0031890536192804575,
-0.002722094999626279,
-0.07392232120037079,
0.020359402522444725,
-0.005196976475417614,
-0.005680415779352188,
-0.05396944656968117,
-0.07321913540363312,
-0.023314977064728737,
-0.03630192205309868,
0.05396944656968117,
0.060473907738924026,
-0.018085038289427757,
-0.034653834998607635,
0.027446188032627106,
-0.003894985420629382,
-0.03988377004861832,
-0.022435994818806648,
0.06785734742879868,
0.06530830264091492,
0.025314658880233765,
0.013008921407163143,
0.02313918061554432,
0.017931217327713966,
0.03493950143456459,
-0.029138226062059402,
0.014503189362585545,
0.026523258537054062,
-0.011294908821582794,
0.021238382905721664,
-0.01231672428548336,
-0.018832171335816383,
-0.028544913977384567,
-0.06640703231096268,
-0.022853510454297066,
0.025951920077204704,
-0.0464102067053318,
-0.02116147242486477,
0.055419765412807465,
0.03353313356637955,
0.04285033419728279,
0.03219268471002579,
-0.05418919026851654,
-0.043289825320243835,
-0.031335677951574326,
0.022435994818806648,
-0.05845224857330322,
-0.0362359993159771,
0.060649704188108444,
0.03146752715110779,
0.012415609322488308,
0.05814460664987564,
0.04049905762076378,
0.025050964206457138,
-0.02480924502015114,
0.04803632199764252,
0.007822932675480843,
0.0340605229139328,
-0.01465701125562191,
-0.06693442165851593,
-0.030764341354370117,
-0.01632707566022873,
-0.04478409141302109,
-0.03421434387564659,
0.015063540078699589,
0.001621995004825294,
-0.053925495594739914,
0.031028036028146744,
-0.01587659865617752,
-0.030061157420277596,
-0.019755102694034576,
0.02867676131427288,
0.0190079677850008,
0.02757803536951542,
0.00982261449098587,
0.014591087587177753,
-0.0175136998295784,
0.023578669875860214,
0.0011536628007888794,
-0.021480103954672813,
-0.11857456713914871,
0.07708664983510971,
0.0025655264034867287,
0.05889173969626427,
-0.01973312720656395,
-0.02062309719622135,
0.005455177277326584,
-0.04684969782829285,
0.09501786530017853,
-0.08042678236961365,
-0.0014585594180971384,
-0.032126761972904205,
0.00584522495046258,
-0.03241243213415146,
-0.015645865350961685,
-0.029533768072724342,
-0.001900796894915402,
-0.07888856530189514,
-0.01811799965798855,
-0.0027152278926223516,
0.06108919158577919,
0.025864021852612495,
-0.030698418617248535,
0.040037594735622406,
-0.06851658225059509,
-0.00009742614201968536,
-0.05370575189590454,
0.014711948111653328,
-0.03293982148170471,
-0.02298535779118538,
0.020106695592403412,
-0.0735267773270607,
-0.03713695704936981,
0.110575832426548,
-0.020601121708750725,
-0.04983823373913765,
-0.04610256478190422,
0.013162743300199509,
0.03278600051999092,
0.0088172797113657,
0.03485160320997238,
-0.08666754513978958,
-0.008850242011249065,
0.04379523918032646,
-0.025688225403428078,
-0.01148169208317995,
0.02274363860487938,
-0.0063231708481907845,
0.03375287726521492,
-0.027621984481811523,
0.010344509966671467,
0.056210849434137344,
-0.03351115807890892,
-0.023314977064728737,
-0.0019351320806890726,
0.03447803854942322,
0.023424848914146423,
-0.025973893702030182,
-0.006229779217392206,
-0.028632812201976776,
-0.017173094674944878,
-0.017590612173080444,
-0.005477151367813349,
0.04706944152712822,
0.0014750403352081776,
-0.011932170018553734,
-0.059287283569574356,
0.04636625945568085,
0.029577717185020447,
0.08776627480983734,
0.026830900460481644,
0.014184558764100075,
-0.03713695704936981,
-0.009943475015461445,
0.03239045664668083,
0.000026030375011032447,
-0.021611949428915977,
0.04482804238796234,
0.06495670974254608,
0.02007373236119747,
0.02360064536333084,
-0.028391093015670776,
-0.00040412534144707024,
0.0394662544131279,
-0.012745227664709091,
-0.0037356701213866472,
-0.010844430886209011,
-0.03832358121871948,
-0.05212358385324478,
0.010723570361733437,
-0.013514336198568344,
-0.03832358121871948,
0.013997775502502918,
0.0706261396408081,
0.007916324771940708,
0.014041724614799023,
0.018898095935583115,
0.055419765412807465,
0.060561805963516235,
0.016920387744903564,
0.033621031790971756,
-0.027138544246554375,
0.008328346535563469,
0.04190542921423912,
0.01347038708627224,
-0.03882899507880211,
0.03428026661276817,
-0.011910195462405682,
-0.0029116251971572638,
0.023710517212748528,
-0.016766566783189774,
0.0010204422287642956,
0.055024221539497375,
-0.05550766363739967,
-0.012899049557745457,
0.009806133806705475,
-0.0464102067053318,
-0.01149267889559269,
0.030632494017481804,
0.04667390137910843,
-0.05643059313297272,
0.0011392420856282115,
0.005210710223764181,
0.03265415132045746,
0.004361944273114204,
0.0401914156973362,
0.013338539749383926,
-0.05142040178179741,
0.013514336198568344,
-0.02654523216187954,
-0.013690131716430187,
-0.029753513634204865,
-0.005419468507170677,
0.02773185633122921,
-0.04684969782829285,
0.014920705929398537,
-0.024743320420384407,
0.030544595792889595,
-0.008482168428599834,
0.016612743958830833,
0.017557648941874504,
-0.008081133477389812,
0.006306690163910389,
-0.020996663719415665,
0.03797198832035065,
-0.01961226761341095,
-0.02344682440161705,
-0.00009528018563287333,
-0.01181130949407816,
-0.01605239324271679,
-0.02676497772336006,
0.015986470505595207,
-0.05498027428984642,
-0.030918164178729057,
0.025929944589734077,
-0.03645574674010277,
0.031115934252738953,
-0.025402557104825974,
-0.03935638442635536,
-0.049794286489486694,
0.07001085579395294,
-0.09756691008806229,
0.06148473545908928,
0.06631913036108017,
0.05959492549300194,
0.07488919794559479,
-0.05313441529870033,
-0.03366497904062271,
-0.03636784851551056,
0.0034417607821524143,
-0.0175136998295784,
-0.06363824009895325,
0.002985789207741618,
-0.009223808534443378,
-0.012162902392446995,
-0.014272456988692284,
-0.01904093101620674,
-0.05458473414182663,
0.01827182248234749,
-0.001983201364055276,
-0.0120859919115901,
-0.04364141821861267,
0.028632812201976776,
0.026677079498767853,
0.02234809659421444,
-0.03540096804499626,
0.024501601234078407,
0.04010351747274399,
-0.0022743637673556805,
-0.04619046300649643,
-0.004095503129065037,
-0.014492202550172806,
-0.03792803734540939,
-0.057485371828079224,
-0.01675557903945446,
0.05221148207783699,
0.03287389501929283,
0.023666568100452423,
0.043289825320243835,
-0.02155701443552971,
-0.017403827980160713,
-0.005872692912817001,
-0.029138226062059402,
-0.05159619823098183,
0.03827963024377823,
-0.059375181794166565,
0.0066637760028243065,
-0.038697145879268646,
-0.005125558935105801,
-0.02916020154953003,
-0.03074236772954464,
-0.012371660210192204,
-0.014799846336245537,
0.009069987572729588,
-0.004452588967978954,
-0.03162134811282158,
0.006707725115120411,
-0.02074395678937435,
0.03397262468934059,
0.00805915892124176,
0.04348759353160858,
-0.054540783166885376,
0.04720129072666168,
0.011833284050226212,
-0.010745544917881489,
0.01465701125562191,
-0.0022592563182115555,
0.046322308480739594,
-0.01785430498421192,
0.05616689845919609,
-0.009042519144713879,
0.0473770871758461,
-0.025490455329418182,
0.0190079677850008,
-0.000624900683760643,
0.015667838975787163,
-0.015107489190995693,
0.02432580478489399,
0.03217071294784546,
-0.09088665246963501,
0.008663458749651909,
-0.005955097731202841,
-0.004694309085607529,
0.02757803536951542,
0.012064017355442047,
0.0347856804728508,
0.04909110069274902,
-0.02551242895424366,
-0.05484842509031296,
0.05484842509031296,
-0.04601466655731201,
0.032764025032520294,
0.002638316946104169,
-0.05757327005267143,
0.030214978381991386,
-0.025622302666306496,
-0.06842868775129318,
0.051771990954875946,
-0.022853510454297066,
0.050585366785526276,
0.005933123175054789,
0.02246895618736744,
0.0010403566993772984,
0.008383283391594887,
0.00026386603713035583,
0.015162426047027111,
0.036653514951467514,
0.04232294484972954,
0.042828358709812164,
0.016502872109413147,
0.018348732963204384,
0.023666568100452423,
0.07528474181890488,
0.0021878392435610294,
-0.016491884365677834,
-0.03217071294784546,
-0.033621031790971756,
-0.016096342355012894,
0.004235590808093548,
-0.031819120049476624,
-0.036895234137773514,
-0.06768155097961426,
-0.028500964865088463,
0.06974715739488602,
-0.05317836254835129,
0.010163220576941967,
0.011536628007888794,
0.024655422195792198,
-0.011261946521699429,
-0.012986946851015091,
-0.02883058413863182,
-0.02037038840353489,
0.0059935529716312885,
-0.03856530040502548,
0.023271027952432632,
0.012975960038602352,
-0.04238886758685112,
0.06544014811515808,
0.02685287594795227,
-0.03447803854942322,
0.020106695592403412,
0.005175001919269562,
0.0473770871758461,
-0.01540414523333311,
0.023271027952432632,
-0.04320192709565163,
0.008883203379809856,
0.04177358001470566,
-0.03159937262535095,
0.039905745536088943,
0.0022070668637752533,
0.016096342355012894,
0.03955415263772011,
-0.063594289124012,
-0.03388472646474838,
-0.018480580300092697,
0.00952046550810337,
-0.012250800617039204,
0.0061528682708740234,
0.007317518349736929,
0.025402557104825974,
-0.0012628487311303616,
-0.020139656960964203,
-0.020656058564782143,
-0.03606020286679268,
-0.03860924765467644,
0.03050064668059349,
0.046146512031555176,
-0.03436816483736038,
-0.03610415384173393,
-0.002180972136557102,
-0.03962007910013199,
0.01433838065713644,
-0.009663299657404423,
-0.011745385825634003,
-0.0483439676463604,
-0.004367437679320574,
-0.012668316252529621,
-0.029248099774122238,
0.013854941353201866,
-0.006839572452008724,
-0.018403667956590652,
0.0025298178661614656,
0.06596753746271133,
-0.027687907218933105,
-0.00685055973008275,
0.030478673055768013,
-0.0078284265473485,
-0.056694287806749344,
-0.00003485023262328468,
-0.034587908536195755,
-0.045355428010225296,
-0.02076593041419983,
0.005098090972751379,
-0.04856371134519577,
0.02274363860487938,
0.018755260854959488,
0.015349209308624268,
-0.0006424116436392069,
0.052167534828186035,
0.04500383883714676,
-0.017733445391058922,
0.022523893043398857,
0.008454700000584126,
-0.026523258537054062,
-0.012481532990932465,
0.05247517675161362,
0.0038565299473702908,
0.06987900286912918,
0.026413384824991226,
-0.011547615751624107,
0.01584363542497158,
-0.07335098087787628,
-0.020293477922677994,
-0.023468798026442528,
-0.025710200890898705,
0.004746498540043831,
0.057089827954769135,
0.01706322282552719,
0.026413384824991226,
-0.07185671478509903,
0.04142199084162712,
0.015942521393299103,
0.0025641529355198145,
0.033467210829257965,
-0.07607582211494446,
0.020062746480107307,
0.08956818282604218,
0.04878345504403114,
-0.000992287416011095,
-0.03414842113852501,
0.0039032259956002235,
-0.005856212228536606,
0.07106562703847885,
-0.005949603859335184,
0.040367212146520615,
-0.00004399197860038839,
-0.036961160600185394,
0.0063616265542805195,
-0.019359560683369637,
-0.033401284366846085,
-0.01630510203540325,
0.014920705929398537,
0.011102631688117981,
0.005155774299055338,
0.04030128940939903,
0.05348600447177887,
-0.018074050545692444,
0.0631987452507019,
0.044564347714185715,
0.04205925017595291,
0.04065288230776787,
0.03050064668059349,
-0.04610256478190422,
0.04605861380696297,
0.011207010596990585,
0.03779619187116623,
-0.03902676701545715,
-0.027863703668117523,
-0.01199809368699789,
-0.07488919794559479,
-0.009992917068302631,
0.04087262600660324,
-0.06776945292949677,
0.02645733393728733,
0.047640781849622726,
0.049706388264894485,
0.0031066492665559053,
0.004856371320784092,
0.03531306982040405,
-0.005331570282578468,
0.03322548791766167,
-0.043223898857831955,
-0.041949376463890076,
-0.0874146819114685,
0.007570225745439529,
-0.009339175187051296,
0.03170924633741379,
0.01330557744950056,
-0.044718168675899506,
-0.00673519354313612,
0.0003115919535048306,
0.01620621606707573,
0.01861242763698101,
-0.06746180355548859,
-0.03929045796394348,
-0.008097614161670208,
0.00022094702580943704,
0.05458473414182663,
0.00843821931630373,
0.08117391169071198,
-0.03819173201918602,
-0.02621561475098133,
0.06245161592960358,
-0.09800640493631363,
-0.0459267683327198,
-0.03764237090945244,
0.05379365012049675,
0.027446188032627106,
0.0033758371137082577,
-0.006097931880503893,
0.0046723345294594765,
0.00673519354313612,
0.018755260854959488,
0.02582007274031639,
0.04493791237473488,
-0.007520782761275768,
0.00012841365241911262,
0.014272456988692284,
-0.011558602564036846,
0.023227078840136528,
0.0745815560221672,
-0.014547138474881649,
0.013997775502502918,
0.001560191623866558,
0.031181858852505684,
0.0095039838925004,
0.018634401261806488,
0.06188027560710907,
-0.030786316841840744,
-0.047640781849622726,
0.005221697501838207,
-0.0424547903239727,
0.08060257881879807,
0.04434460029006004,
-0.010459876619279385,
-0.017810355871915817,
0.025380581617355347,
-0.07216435670852661,
0.027358289808034897,
0.03674141317605972,
-0.017260992899537086,
0.0014681732282042503,
0.014184558764100075,
-0.016733605414628983,
0.03713695704936981,
-0.019436471164226532,
-0.03208281472325325,
-0.00030661336495541036,
0.0557713583111763,
0.06631913036108017,
0.022523893043398857,
-0.10196182131767273,
-0.029270073398947716,
-0.0241719838231802,
-0.04252071678638458,
0.002799005713313818,
0.05164014548063278,
0.04909110069274902,
0.0015807927120476961,
0.04878345504403114,
0.008509636856615543,
0.08644779771566391
]
|
32,026 | pingouin.nonparametric | mwu | Mann-Whitney U Test (= Wilcoxon rank-sum test). It is the non-parametric
version of the independent T-test.
Parameters
----------
x, y : array_like
First and second set of observations. ``x`` and ``y`` must be
independent.
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of
"two-sided" (default), "greater" or "less". See :py:func:`scipy.stats.mannwhitneyu` for
more details.
**kwargs : dict
Additional keywords arguments that are passed to :py:func:`scipy.stats.mannwhitneyu`.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'U-val'``: U-value
* ``'alternative'``: tail of the test
* ``'p-val'``: p-value
* ``'RBC'`` : rank-biserial correlation
* ``'CLES'`` : common language effect size
See also
--------
scipy.stats.mannwhitneyu, wilcoxon, ttest
Notes
-----
The Mann–Whitney U test [1]_ (also called Wilcoxon rank-sum test) is a
non-parametric test of the null hypothesis that it is equally likely that
a randomly selected value from one sample will be less than or greater
than a randomly selected value from a second sample. The test assumes
that the two samples are independent. This test corrects for ties and by
default uses a continuity correction (see :py:func:`scipy.stats.mannwhitneyu` for details).
The rank biserial correlation [2]_ is the difference between
the proportion of favorable evidence minus the proportion of unfavorable
evidence.
The common language effect size is the proportion of pairs where ``x`` is
higher than ``y``. It was first introduced by McGraw and Wong (1992) [3]_.
Pingouin uses a brute-force version of the formula given by Vargha and
Delaney 2000 [4]_:
.. math:: \text{CL} = P(X > Y) + .5 \times P(X = Y)
The advantage is of this method are twofold. First, the brute-force
approach pairs each observation of ``x`` to its ``y`` counterpart, and
therefore does not require normally distributed data. Second, the formula
takes ties into account and therefore works with ordinal data.
When tail is ``'less'``, the CLES is then set to :math:`1 - \text{CL}`,
which gives the proportion of pairs where ``x`` is *lower* than ``y``.
References
----------
.. [1] Mann, H. B., & Whitney, D. R. (1947). On a test of whether one of
two random variables is stochastically larger than the other.
The annals of mathematical statistics, 50-60.
.. [2] Kerby, D. S. (2014). The simple difference formula: An approach to
teaching nonparametric correlation. Comprehensive Psychology,
3, 11-IT.
.. [3] McGraw, K. O., & Wong, S. P. (1992). A common language effect size
statistic. Psychological bulletin, 111(2), 361.
.. [4] Vargha, A., & Delaney, H. D. (2000). A Critique and Improvement of
the “CL” Common Language Effect Size Statistics of McGraw and Wong.
Journal of Educational and Behavioral Statistics: A Quarterly
Publication Sponsored by the American Educational Research
Association and the American Statistical Association, 25(2),
101–132. https://doi.org/10.2307/1165329
Examples
--------
>>> import numpy as np
>>> import pingouin as pg
>>> np.random.seed(123)
>>> x = np.random.uniform(low=0, high=1, size=20)
>>> y = np.random.uniform(low=0.2, high=1.2, size=20)
>>> pg.mwu(x, y, alternative='two-sided')
U-val alternative p-val RBC CLES
MWU 97.0 two-sided 0.00556 0.515 0.2425
Compare with SciPy
>>> import scipy
>>> scipy.stats.mannwhitneyu(x, y, use_continuity=True, alternative='two-sided')
MannwhitneyuResult(statistic=97.0, pvalue=0.0055604599321374135)
One-sided test
>>> pg.mwu(x, y, alternative='greater')
U-val alternative p-val RBC CLES
MWU 97.0 greater 0.997442 0.515 0.2425
>>> pg.mwu(x, y, alternative='less')
U-val alternative p-val RBC CLES
MWU 97.0 less 0.00278 0.515 0.7575
Passing keyword arguments to :py:func:`scipy.stats.mannwhitneyu`:
>>> pg.mwu(x, y, alternative='two-sided', method='exact')
U-val alternative p-val RBC CLES
MWU 97.0 two-sided 0.004681 0.515 0.2425
| def mwu(x, y, alternative="two-sided", **kwargs):
"""Mann-Whitney U Test (= Wilcoxon rank-sum test). It is the non-parametric
version of the independent T-test.
Parameters
----------
x, y : array_like
First and second set of observations. ``x`` and ``y`` must be
independent.
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of
"two-sided" (default), "greater" or "less". See :py:func:`scipy.stats.mannwhitneyu` for
more details.
**kwargs : dict
Additional keywords arguments that are passed to :py:func:`scipy.stats.mannwhitneyu`.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'U-val'``: U-value
* ``'alternative'``: tail of the test
* ``'p-val'``: p-value
* ``'RBC'`` : rank-biserial correlation
* ``'CLES'`` : common language effect size
See also
--------
scipy.stats.mannwhitneyu, wilcoxon, ttest
Notes
-----
The Mann–Whitney U test [1]_ (also called Wilcoxon rank-sum test) is a
non-parametric test of the null hypothesis that it is equally likely that
a randomly selected value from one sample will be less than or greater
than a randomly selected value from a second sample. The test assumes
that the two samples are independent. This test corrects for ties and by
default uses a continuity correction (see :py:func:`scipy.stats.mannwhitneyu` for details).
The rank biserial correlation [2]_ is the difference between
the proportion of favorable evidence minus the proportion of unfavorable
evidence.
The common language effect size is the proportion of pairs where ``x`` is
higher than ``y``. It was first introduced by McGraw and Wong (1992) [3]_.
Pingouin uses a brute-force version of the formula given by Vargha and
Delaney 2000 [4]_:
.. math:: \\text{CL} = P(X > Y) + .5 \\times P(X = Y)
The advantage is of this method are twofold. First, the brute-force
approach pairs each observation of ``x`` to its ``y`` counterpart, and
therefore does not require normally distributed data. Second, the formula
takes ties into account and therefore works with ordinal data.
When tail is ``'less'``, the CLES is then set to :math:`1 - \\text{CL}`,
which gives the proportion of pairs where ``x`` is *lower* than ``y``.
References
----------
.. [1] Mann, H. B., & Whitney, D. R. (1947). On a test of whether one of
two random variables is stochastically larger than the other.
The annals of mathematical statistics, 50-60.
.. [2] Kerby, D. S. (2014). The simple difference formula: An approach to
teaching nonparametric correlation. Comprehensive Psychology,
3, 11-IT.
.. [3] McGraw, K. O., & Wong, S. P. (1992). A common language effect size
statistic. Psychological bulletin, 111(2), 361.
.. [4] Vargha, A., & Delaney, H. D. (2000). A Critique and Improvement of
the “CL” Common Language Effect Size Statistics of McGraw and Wong.
Journal of Educational and Behavioral Statistics: A Quarterly
Publication Sponsored by the American Educational Research
Association and the American Statistical Association, 25(2),
101–132. https://doi.org/10.2307/1165329
Examples
--------
>>> import numpy as np
>>> import pingouin as pg
>>> np.random.seed(123)
>>> x = np.random.uniform(low=0, high=1, size=20)
>>> y = np.random.uniform(low=0.2, high=1.2, size=20)
>>> pg.mwu(x, y, alternative='two-sided')
U-val alternative p-val RBC CLES
MWU 97.0 two-sided 0.00556 0.515 0.2425
Compare with SciPy
>>> import scipy
>>> scipy.stats.mannwhitneyu(x, y, use_continuity=True, alternative='two-sided')
MannwhitneyuResult(statistic=97.0, pvalue=0.0055604599321374135)
One-sided test
>>> pg.mwu(x, y, alternative='greater')
U-val alternative p-val RBC CLES
MWU 97.0 greater 0.997442 0.515 0.2425
>>> pg.mwu(x, y, alternative='less')
U-val alternative p-val RBC CLES
MWU 97.0 less 0.00278 0.515 0.7575
Passing keyword arguments to :py:func:`scipy.stats.mannwhitneyu`:
>>> pg.mwu(x, y, alternative='two-sided', method='exact')
U-val alternative p-val RBC CLES
MWU 97.0 two-sided 0.004681 0.515 0.2425
"""
x = np.asarray(x)
y = np.asarray(y)
# Remove NA
x, y = remove_na(x, y, paired=False)
# Check tails
assert alternative in [
"two-sided",
"greater",
"less",
], "Alternative must be one of 'two-sided' (default), 'greater' or 'less'."
if "tail" in kwargs:
raise ValueError(
"Since Pingouin 0.4.0, the 'tail' argument has been renamed to 'alternative'."
)
uval, pval = scipy.stats.mannwhitneyu(x, y, alternative=alternative, **kwargs)
# Effect size 1: Common Language Effect Size
# CLES is tail-specific and calculated according to the formula given in
# Vargha and Delaney 2000 which works with ordinal data.
diff = x[:, None] - y
# cles = max((diff < 0).sum(), (diff > 0).sum()) / diff.size
# Tail = 'greater', with ties set to 0.5
# Note that tail = 'two-sided' gives same output as tail = 'greater'
cles = np.where(diff == 0, 0.5, diff > 0).mean()
cles = 1 - cles if alternative == "less" else cles
# Effect size 2: rank biserial correlation (Wendt 1972)
rbc = 1 - (2 * uval) / diff.size # diff.size = x.size * y.size
# Fill output DataFrame
stats = pd.DataFrame(
{"U-val": uval, "alternative": alternative, "p-val": pval, "RBC": rbc, "CLES": cles},
index=["MWU"],
)
return _postprocess_dataframe(stats)
| (x, y, alternative='two-sided', **kwargs) | [
-0.027782242745161057,
0.02837596833705902,
0.05056900531053543,
0.010354362428188324,
0.038714975118637085,
-0.017893647775053978,
-0.06518692523241043,
0.020319731906056404,
0.034272272139787674,
0.016695961356163025,
0.013553312048316002,
0.05490934103727341,
0.06530977040529251,
0.032388731837272644,
-0.0633033886551857,
0.04158123582601547,
-0.03466126695275307,
-0.007308961357921362,
0.00045105197932571173,
-0.00861413311213255,
-0.029051586985588074,
0.0007485543610528111,
0.06580112874507904,
0.11162032932043076,
-0.020125236362218857,
-0.011424090713262558,
-0.031221754848957062,
-0.0337604396045208,
-0.027434196323156357,
-0.011843793094158173,
-0.02796650305390358,
-0.0022187919821590185,
-0.00861413311213255,
-0.037261370569467545,
0.05155172199010849,
-0.011884739622473717,
0.04962723329663277,
0.021394578740000725,
-0.14306728541851044,
-0.027086151763796806,
0.003306434955447912,
-0.0410284548997879,
0.08615157008171082,
0.01914251782000065,
-0.024404151365160942,
0.011188648641109467,
-0.0067613013088703156,
0.035643983632326126,
-0.019050387665629387,
-0.011526457034051418,
0.027454670518636703,
-0.027393249794840813,
0.03066897578537464,
0.018487373366951942,
-0.005159266758710146,
0.03394469991326332,
-0.02929726615548134,
0.038223616778850555,
0.02686094492673874,
-0.02964531071484089,
-0.01592821255326271,
0.040803249925374985,
0.02233635075390339,
-0.003270606743171811,
-0.0072833700105547905,
-0.014761235564947128,
0.007442038040608168,
-0.003163121873512864,
0.028560226783156395,
0.026103433221578598,
0.014003724791109562,
0.04864451661705971,
0.018374770879745483,
-0.001530377776362002,
0.010456728748977184,
0.01296982355415821,
-0.010840602219104767,
-0.038858287036418915,
-0.0201866552233696,
0.02088274620473385,
0.01891731284558773,
0.05752992257475853,
0.00958661362528801,
-0.046228669583797455,
0.019459854811429977,
-0.04063946381211281,
0.02198830433189869,
0.030873708426952362,
0.052902959287166595,
-0.018559029325842857,
-0.07693859189748764,
0.0054766028188169,
0.07616060972213745,
-0.01342023629695177,
-0.015528984367847443,
0.023564746603369713,
-0.030628029257059097,
0.027516091242432594,
-0.008552713319659233,
0.004706295672804117,
0.0031605628319084644,
0.006720354780554771,
0.02733183093369007,
0.06985483318567276,
-0.004066505469381809,
0.02851928025484085,
-0.03531641140580177,
0.012775328010320663,
-0.0549502857029438,
-0.0243427325040102,
-0.04995480552315712,
-0.07431801408529282,
-0.022725341841578484,
-0.03126269951462746,
0.022090671584010124,
-0.012243022210896015,
-0.07071471214294434,
0.010584686882793903,
0.004504121840000153,
0.013379289768636227,
-0.008245614357292652,
-0.00700698047876358,
-0.01388088520616293,
-0.055482592433691025,
-0.004440142773091793,
-0.0633033886551857,
0.04680192098021507,
0.006858549080789089,
0.02007405273616314,
0.01682903803884983,
-0.012826510705053806,
-0.022090671584010124,
-0.0036928681656718254,
0.055482592433691025,
-0.03421085327863693,
0.016521938145160675,
0.015651823952794075,
-0.003644244046881795,
0.10023718327283859,
-0.04139697551727295,
0.05261633172631264,
0.06637437641620636,
-0.01401396095752716,
0.031958792358636856,
-0.0030223680660128593,
0.022418243810534477,
-0.0035060495138168335,
0.0031400895677506924,
0.027700349688529968,
-0.013082426972687244,
-0.03617628663778305,
-0.056588150560855865,
0.06182930991053581,
-0.035992030054330826,
0.002753656357526779,
-0.04905398190021515,
0.007738900370895863,
-0.024588411673903465,
0.008076709695160389,
-0.010257113724946976,
0.03498883917927742,
-0.02329859510064125,
0.019889792427420616,
0.061870258301496506,
-0.009975606575608253,
0.033924225717782974,
0.020667778328061104,
-0.019101571291685104,
0.021169373765587807,
-0.00812277477234602,
-0.002154812915250659,
-0.026267219334840775,
-0.023564746603369713,
-0.008649961091578007,
-0.003498371923342347,
-0.04209306836128235,
-0.010164984501898289,
-0.06576018035411835,
-0.030730394646525383,
0.00117849325761199,
-0.0040588281117379665,
-0.012498938478529453,
-0.02538686990737915,
-0.055892057716846466,
-0.0438537672162056,
0.022725341841578484,
0.06080564484000206,
-0.009330698288977146,
0.005445892922580242,
0.002666644984856248,
-0.0018630686681717634,
-0.03660622611641884,
-0.010103564709424973,
0.04856262356042862,
0.04757990688085556,
-0.007380617782473564,
0.03777320310473442,
0.009115728549659252,
0.006797129288315773,
-0.047129493206739426,
-0.02796650305390358,
0.04430418089032173,
0.011669770814478397,
0.010180339217185974,
0.05413135513663292,
-0.02239776961505413,
-0.0399843193590641,
0.014689579606056213,
-0.056670043617486954,
-0.04983196780085564,
0.09802607446908951,
0.018497610464692116,
-0.04182691499590874,
0.04577825590968132,
-0.011956396512687206,
-0.032245419919490814,
0.06518692523241043,
0.004634639248251915,
-0.010385071858763695,
-0.02929726615548134,
-0.010922495275735855,
0.013522602617740631,
-0.03691332787275314,
0.029174426570534706,
0.02985004521906376,
-0.014239166863262653,
0.0313241221010685,
0.060559965670108795,
0.07517789304256439,
-0.03867403045296669,
0.01533448789268732,
0.03484552353620529,
0.035173095762729645,
-0.0028918511234223843,
-0.06653816252946854,
-0.050609949976205826,
-0.06576018035411835,
0.016235312446951866,
0.008962178602814674,
0.025366395711898804,
-0.051019418984651566,
-0.04757990688085556,
0.02720899134874344,
0.01662430539727211,
-0.025018349289894104,
-0.0077081904746592045,
0.020923694595694542,
0.034538425505161285,
0.0018617890309542418,
0.0201866552233696,
-0.0014228930231183767,
-0.02593964710831642,
0.015948686748743057,
0.004844490438699722,
-0.0040281182155013084,
0.006408137269318104,
-0.0003560431650839746,
-0.020442571491003036,
0.018405480310320854,
-0.05900399759411812,
0.018640922382473946,
-0.007958987727761269,
-0.022090671584010124,
0.02567349560558796,
-0.0681760236620903,
-0.04934060946106911,
-0.03896065428853035,
0.041785966604948044,
-0.04848073050379753,
-0.0020076611544936895,
-0.07255730777978897,
0.010687053203582764,
-0.013184793293476105,
-0.02837596833705902,
-0.04377187415957451,
0.00020217365818098187,
0.07464558631181717,
-0.010062618181109428,
0.039902426302433014,
0.00970433559268713,
-0.03359665349125862,
-0.015610877424478531,
0.0024516754783689976,
0.00532305333763361,
0.008537358604371548,
-0.024936456233263016,
-0.007457392755895853,
-0.006264823954552412,
0.006807365920394659,
-0.031344592571258545,
-0.022029250860214233,
-0.09753471612930298,
-0.010154747404158115,
-0.0010729279601946473,
0.029665784910321236,
0.028539754450321198,
-0.06273013353347778,
-0.03869450092315674,
0.02503882348537445,
0.008394045755267143,
-0.026942837983369827,
0.010251996107399464,
0.0033985646441578865,
-0.00268711824901402,
-0.008301915600895882,
-0.0038694501854479313,
0.08680671453475952,
-0.0758330374956131,
-0.02503882348537445,
-0.008414519019424915,
-0.006131747737526894,
0.005010835826396942,
0.0013358816504478455,
-0.00023096420045476407,
0.0020857155323028564,
-0.027086151763796806,
0.0065156216733157635,
0.02796650305390358,
0.032798197120428085,
0.03672906756401062,
0.034272272139787674,
-0.061870258301496506,
0.072311632335186,
0.017340868711471558,
-0.012427281588315964,
-0.019562220200896263,
-0.02091345749795437,
0.002656408352777362,
0.013164320029318333,
-0.03805983066558838,
-0.057570867240428925,
-0.029686257243156433,
-0.028642121702432632,
0.016317205503582954,
-0.020790617913007736,
0.017248740419745445,
0.04495932534337044,
0.007308961357921362,
0.05630152300000191,
-0.015426618047058582,
-0.010687053203582764,
0.01795506849884987,
-0.03945201262831688,
0.010420899838209152,
0.039963845163583755,
-0.03277772292494774,
-0.03081228956580162,
0.01360449567437172,
0.04418134316802025,
0.02587822824716568,
0.027311356738209724,
0.07329434901475906,
0.015999870374798775,
0.0001489911082899198,
0.03459984436631203,
0.04307578504085541,
-0.026819998398423195,
-0.031139861792325974,
0.023708060383796692,
0.04786653071641922,
-0.08283489942550659,
0.023626167327165604,
0.018814945593476295,
0.014402953907847404,
-0.028048396110534668,
-0.01665501482784748,
0.03914491459727287,
0.01380922831594944,
-0.04545068368315697,
-0.03846929594874382,
-0.02407657913863659,
-0.0354597233235836,
-0.024445097893476486,
0.02671763300895691,
0.017443235963582993,
0.04233874753117561,
-0.013727335259318352,
-0.021128427237272263,
-0.04753895848989487,
-0.03943153843283653,
0.03728184476494789,
-0.014382480643689632,
-0.06838075816631317,
0.00016266661987174302,
0.02077014371752739,
0.00570692727342248,
-0.04063946381211281,
-0.0040281182155013084,
-0.07214784622192383,
-0.00980670191347599,
0.018978731706738472,
-0.018876366317272186,
0.04815315827727318,
0.04127413406968117,
-0.03457937389612198,
0.027516091242432594,
0.0018374769715592265,
-0.0011477833613753319,
-0.03965674713253975,
-0.005338408052921295,
0.04061898961663246,
-0.03152885288000107,
-0.033903755247592926,
0.024445097893476486,
-0.08086945861577988,
-0.0036621582694351673,
-0.005228364374488592,
0.04035283625125885,
-0.018896838650107384,
0.06449083983898163,
-0.07820793241262436,
0.022090671584010124,
-0.03040282242000103,
-0.035992030054330826,
-0.030075250193476677,
0.032532043755054474,
-0.026471953839063644,
-0.04389471560716629,
0.036626700311899185,
0.015610877424478531,
0.06686573475599289,
-0.09294869750738144,
0.06440894305706024,
0.024015158414840698,
0.05212497338652611,
-0.060969430953264236,
0.003654480678960681,
-0.1057240292429924,
-0.0034548663534224033,
0.0203402042388916,
-0.00039571014349348843,
-0.015907740220427513,
-0.019429143518209457,
-0.0243427325040102,
0.016573121771216393,
-0.050323326140642166,
-0.028089342638850212,
0.016470754519104958,
-0.0029865398537367582,
-0.002909765113145113,
-0.014167510904371738,
0.028130289167165756,
-0.0018464340828359127,
0.008409400470554829,
-0.08713428676128387,
0.004268679302185774,
-0.034395113587379456,
-0.0563424713909626,
-0.06805318593978882,
-0.014536029659211636,
0.042256854474544525,
0.0382850356400013,
0.02845786139369011,
0.035377830266952515,
-0.0018336382927373052,
-0.01566206105053425,
-0.04201117530465126,
-0.036360546946525574,
-0.01856926642358303,
-0.03220447152853012,
0.019429143518209457,
-0.010635869577527046,
0.005640388932079077,
0.02503882348537445,
-0.03351476043462753,
0.07816699147224426,
0.00552778597921133,
-0.03881734237074852,
0.0459010973572731,
0.032593462616205215,
0.021374106407165527,
0.004575778264552355,
-0.013297396712005138,
0.005246278364211321,
0.0702643021941185,
0.015273068100214005,
-0.10384048521518707,
0.008481056429445744,
0.03629912808537483,
-0.042666319757699966,
-0.003106820397078991,
0.05724329501390457,
0.07493221014738083,
-0.019152754917740822,
0.009893713518977165,
-0.04389471560716629,
-0.010410663671791553,
-0.05466366186738014,
0.07247541844844818,
-0.022070197388529778,
0.0438128225505352,
0.08340814709663391,
0.03674954175949097,
-0.0006289136363193393,
-0.09794417768716812,
0.015088808722794056,
0.018620450049638748,
-0.03261393681168556,
0.05245254561305046,
-0.0049059102311730385,
0.044345129281282425,
0.03443605825304985,
-0.03466126695275307,
-0.057775601744651794,
0.022663922980427742,
0.012529647909104824,
-0.0051132021471858025,
-0.005363999865949154,
-0.0027050322387367487,
-0.003037723246961832,
-0.005220686551183462,
-0.03150837868452072,
0.03591013699769974,
0.0037798795383423567,
0.01700305938720703,
0.00680224783718586,
-0.036217235028743744,
0.07644723355770111,
0.03945201262831688,
-0.038223616778850555,
0.020749671384692192,
0.014863602817058563,
0.04328051581978798,
0.012857221066951752,
0.029379159212112427,
0.03570540249347687,
-0.036626700311899185,
0.00014675184502266347,
0.020985113456845284,
0.0521659217774868,
-0.043935660272836685,
-0.05679288133978844,
-0.05527786165475845,
-0.021599311381578445,
-0.023400960490107536,
-0.03081228956580162,
-0.056670043617486954,
-0.009525193832814693,
0.06420420855283737,
0.03623770922422409,
0.011628824286162853,
-0.009069663472473621,
0.06641532480716705,
-0.04401755705475807,
0.0139115946367383,
0.033023402094841,
-0.022152090445160866,
0.03249109908938408,
-0.03304387629032135,
-0.0009526473586447537,
0.0060805645771324635,
-0.07988674193620682,
-0.022991495206952095,
0.0619112029671669,
0.00975040066987276,
-0.007958987727761269,
0.006797129288315773,
0.030239036306738853,
-0.025059295818209648,
0.04074183106422424,
-0.0410284548997879,
-0.07329434901475906,
0.03894018009305,
-0.02727041020989418,
-0.025079770013689995,
0.0647365152835846,
0.03873544931411743,
0.00042098184349015355,
-0.06530977040529251,
0.004693499766290188,
-0.008926350623369217,
0.061870258301496506,
0.009591732174158096,
0.000037687634176108986,
-0.058758318424224854,
0.015283304266631603,
0.024875037372112274,
-0.04360808804631233,
0.023708060383796692,
-0.033637601882219315,
-0.03290056437253952,
0.0274751428514719,
0.07120607048273087,
-0.04614677652716637,
0.0424615852534771,
0.01819051057100296,
-0.015590404160320759,
0.025632549077272415,
-0.016173891723155975,
0.04905398190021515,
0.006029381416738033,
-0.016665251925587654,
-0.017095189541578293,
-0.03707711398601532,
0.046924762427806854,
0.007503457833081484,
-0.022090671584010124,
-0.010461847297847271,
0.11178411543369293,
0.051510777324438095,
0.004857285879552364,
0.012406808324158192,
-0.038858287036418915,
-0.04479553923010826,
0.00020265349303372204,
-0.0014344092924147844,
-0.012427281588315964,
-0.0667838454246521,
-0.007810556795448065,
-0.05118320509791374,
0.009085019119083881,
-0.00657704146578908,
-0.03075086884200573,
-0.014402953907847404,
0.03365807607769966,
-0.020002396777272224,
-0.005000599194318056,
-0.05761181563138962,
0.01926535740494728,
-0.028621647506952286,
-0.007319197990000248,
0.028212182223796844,
0.041294608265161514,
0.012898167595267296,
0.012509174644947052,
-0.00690461415797472,
0.009090136736631393,
-0.008030644617974758,
-0.0018336382927373052,
-0.003204068634659052,
-0.027864135801792145,
0.01492502260953188,
0.07247541844844818,
-0.004821457900106907,
-0.04119224101305008,
0.012038289569318295,
0.01705424301326275,
-0.039349645376205444,
0.017269212752580643,
0.013471418991684914,
-0.005302580073475838,
0.0379369892179966,
0.07972295582294464,
0.03652433305978775,
-0.025960121303796768,
0.049709126353263855,
0.022008778527379036,
-0.010942968539893627,
-0.0008867490105330944,
-0.0014766354579478502,
0.0025028586387634277,
0.006060091312974691,
0.02735230326652527,
-0.014515556395053864,
0.007042808923870325,
0.02962483838200569,
-0.012253259308636189,
0.019367724657058716,
0.03674954175949097,
-0.03965674713253975,
-0.0003374892403371632,
0.009591732174158096,
-0.008844457566738129,
0.016173891723155975,
0.0716974288225174,
0.04467270150780678,
0.024445097893476486,
-0.025202609598636627,
-0.008685790002346039,
-0.0438128225505352,
0.049299661070108414,
0.05724329501390457,
0.009458656422793865,
-0.05118320509791374,
0.0030249273404479027,
-0.016051052138209343,
-0.04753895848989487,
0.01134219765663147,
-0.027741296216845512,
-0.01067681610584259,
0.02602154016494751,
0.0281712356954813,
-0.02512071654200554,
-0.03679048642516136,
0.03046424314379692,
0.03242967650294304,
-0.03324861079454422,
0.006607751827687025,
-0.03779367730021477,
-0.028048396110534668,
-0.001602034317329526,
0.003498371923342347,
-0.021312685683369637,
0.05167456343770027,
0.02164025790989399,
-0.012683197855949402,
-0.01563134975731373,
0.01812908984720707,
0.027597984299063683,
-0.0323682576417923,
-0.003767083864659071,
0.0060908012092113495,
0.012826510705053806,
-0.003808030392974615,
-0.019940976053476334,
0.015395907685160637,
-0.008204667828977108,
-0.041847389191389084,
0.07923159748315811,
-0.04680192098021507,
-0.04233874753117561,
0.056465309113264084,
0.029665784910321236,
-0.05970009043812752,
0.02315528132021427,
0.0022558995988219976,
-0.03263441100716591,
0.03222494572401047,
-0.013358816504478455,
0.00197311257943511,
0.03494789078831673,
0.03834645450115204,
-0.003664717311039567,
-0.01085083931684494,
-0.033842332661151886,
0.001534216571599245,
0.05503218248486519,
-0.059372514486312866,
0.018139326944947243,
-0.04237969219684601,
0.016020342707633972,
0.005435656290501356,
-0.006131747737526894,
0.058553583920001984,
0.03402659296989441,
0.003674953943118453,
-0.02712709829211235,
-0.030443768948316574,
0.03359665349125862,
0.024813616648316383,
-0.03984100744128227,
0.009105492383241653,
0.0004225813318043947,
-0.07710237801074982,
-0.02039138786494732,
0.031139861792325974,
0.01804719679057598,
0.022520609200000763,
0.06895401328802109,
0.017013296484947205,
0.057980332523584366,
-0.059822928160429,
-0.04528689756989479,
0.010717762634158134,
0.08226164430379868,
0.04704760015010834,
0.050323326140642166,
-0.05744802951812744,
-0.009903949685394764,
-0.04680192098021507,
-0.04340335726737976,
0.021804044023156166,
0.025509709492325783,
0.07251635938882828,
-0.03922680765390396,
0.021885937079787254,
-0.015764426440000534,
0.07865834981203079
]
|
32,028 | pingouin.distribution | normality | Univariate normality test.
Parameters
----------
data : :py:class:`pandas.DataFrame`, series, list or 1D np.array
Iterable. Can be either a single list, 1D numpy array,
or a wide- or long-format pandas dataframe.
dv : str
Dependent variable (only when ``data`` is a long-format dataframe).
group : str
Grouping variable (only when ``data`` is a long-format dataframe).
method : str
Normality test. `'shapiro'` (default) performs the Shapiro-Wilk test
using :py:func:`scipy.stats.shapiro`, `'normaltest'` performs the
omnibus test of normality using :py:func:`scipy.stats.normaltest`, `'jarque_bera'` performs
the Jarque-Bera test using :py:func:`scipy.stats.jarque_bera`.
The Omnibus and Jarque-Bera tests are more suitable than the Shapiro test for
large samples.
alpha : float
Significance level.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'W'``: Test statistic.
* ``'pval'``: p-value.
* ``'normal'``: True if ``data`` is normally distributed.
See Also
--------
homoscedasticity : Test equality of variance.
sphericity : Mauchly's test for sphericity.
Notes
-----
The Shapiro-Wilk test calculates a :math:`W` statistic that tests whether a
random sample :math:`x_1, x_2, ..., x_n` comes from a normal distribution.
The :math:`W` statistic is calculated as follows:
.. math::
W = \frac{(\sum_{i=1}^n a_i x_{i})^2}
{\sum_{i=1}^n (x_i - \overline{x})^2}
where the :math:`x_i` are the ordered sample values (in ascending
order) and the :math:`a_i` are constants generated from the means,
variances and covariances of the order statistics of a sample of size
:math:`n` from a standard normal distribution. Specifically:
.. math:: (a_1, ..., a_n) = \frac{m^TV^{-1}}{(m^TV^{-1}V^{-1}m)^{1/2}}
with :math:`m = (m_1, ..., m_n)^T` and :math:`(m_1, ..., m_n)` are the
expected values of the order statistics of independent and identically
distributed random variables sampled from the standard normal distribution,
and :math:`V` is the covariance matrix of those order statistics.
The null-hypothesis of this test is that the population is normally
distributed. Thus, if the p-value is less than the
chosen alpha level (typically set at 0.05), then the null hypothesis is
rejected and there is evidence that the data tested are not normally
distributed.
The result of the Shapiro-Wilk test should be interpreted with caution in
the case of large sample sizes. Indeed, quoting from
`Wikipedia <https://en.wikipedia.org/wiki/Shapiro%E2%80%93Wilk_test>`_:
*"Like most statistical significance tests, if the sample size is
sufficiently large this test may detect even trivial departures from
the null hypothesis (i.e., although there may be some statistically
significant effect, it may be too small to be of any practical
significance); thus, additional investigation of the effect size is
typically advisable, e.g., a Q–Q plot in this case."*
Note that missing values are automatically removed (casewise deletion).
References
----------
* Shapiro, S. S., & Wilk, M. B. (1965). An analysis of variance test
for normality (complete samples). Biometrika, 52(3/4), 591-611.
* https://www.itl.nist.gov/div898/handbook/prc/section2/prc213.htm
Examples
--------
1. Shapiro-Wilk test on a 1D array.
>>> import numpy as np
>>> import pingouin as pg
>>> np.random.seed(123)
>>> x = np.random.normal(size=100)
>>> pg.normality(x)
W pval normal
0 0.98414 0.274886 True
2. Omnibus test on a wide-format dataframe with missing values
>>> data = pg.read_dataset('mediation')
>>> data.loc[1, 'X'] = np.nan
>>> pg.normality(data, method='normaltest').round(3)
W pval normal
X 1.792 0.408 True
M 0.492 0.782 True
Y 0.349 0.840 True
Mbin 839.716 0.000 False
Ybin 814.468 0.000 False
W1 24.816 0.000 False
W2 43.400 0.000 False
3. Pandas Series
>>> pg.normality(data['X'], method='normaltest')
W pval normal
X 1.791839 0.408232 True
4. Long-format dataframe
>>> data = pg.read_dataset('rm_anova2')
>>> pg.normality(data, dv='Performance', group='Time')
W pval normal
Time
Pre 0.967718 0.478773 True
Post 0.940728 0.095157 True
5. Same but using the Jarque-Bera test
>>> pg.normality(data, dv='Performance', group='Time', method="jarque_bera")
W pval normal
Time
Pre 0.304021 0.858979 True
Post 1.265656 0.531088 True
| def normality(data, dv=None, group=None, method="shapiro", alpha=0.05):
"""Univariate normality test.
Parameters
----------
data : :py:class:`pandas.DataFrame`, series, list or 1D np.array
Iterable. Can be either a single list, 1D numpy array,
or a wide- or long-format pandas dataframe.
dv : str
Dependent variable (only when ``data`` is a long-format dataframe).
group : str
Grouping variable (only when ``data`` is a long-format dataframe).
method : str
Normality test. `'shapiro'` (default) performs the Shapiro-Wilk test
using :py:func:`scipy.stats.shapiro`, `'normaltest'` performs the
omnibus test of normality using :py:func:`scipy.stats.normaltest`, `'jarque_bera'` performs
the Jarque-Bera test using :py:func:`scipy.stats.jarque_bera`.
The Omnibus and Jarque-Bera tests are more suitable than the Shapiro test for
large samples.
alpha : float
Significance level.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'W'``: Test statistic.
* ``'pval'``: p-value.
* ``'normal'``: True if ``data`` is normally distributed.
See Also
--------
homoscedasticity : Test equality of variance.
sphericity : Mauchly's test for sphericity.
Notes
-----
The Shapiro-Wilk test calculates a :math:`W` statistic that tests whether a
random sample :math:`x_1, x_2, ..., x_n` comes from a normal distribution.
The :math:`W` statistic is calculated as follows:
.. math::
W = \\frac{(\\sum_{i=1}^n a_i x_{i})^2}
{\\sum_{i=1}^n (x_i - \\overline{x})^2}
where the :math:`x_i` are the ordered sample values (in ascending
order) and the :math:`a_i` are constants generated from the means,
variances and covariances of the order statistics of a sample of size
:math:`n` from a standard normal distribution. Specifically:
.. math:: (a_1, ..., a_n) = \\frac{m^TV^{-1}}{(m^TV^{-1}V^{-1}m)^{1/2}}
with :math:`m = (m_1, ..., m_n)^T` and :math:`(m_1, ..., m_n)` are the
expected values of the order statistics of independent and identically
distributed random variables sampled from the standard normal distribution,
and :math:`V` is the covariance matrix of those order statistics.
The null-hypothesis of this test is that the population is normally
distributed. Thus, if the p-value is less than the
chosen alpha level (typically set at 0.05), then the null hypothesis is
rejected and there is evidence that the data tested are not normally
distributed.
The result of the Shapiro-Wilk test should be interpreted with caution in
the case of large sample sizes. Indeed, quoting from
`Wikipedia <https://en.wikipedia.org/wiki/Shapiro%E2%80%93Wilk_test>`_:
*"Like most statistical significance tests, if the sample size is
sufficiently large this test may detect even trivial departures from
the null hypothesis (i.e., although there may be some statistically
significant effect, it may be too small to be of any practical
significance); thus, additional investigation of the effect size is
typically advisable, e.g., a Q–Q plot in this case."*
Note that missing values are automatically removed (casewise deletion).
References
----------
* Shapiro, S. S., & Wilk, M. B. (1965). An analysis of variance test
for normality (complete samples). Biometrika, 52(3/4), 591-611.
* https://www.itl.nist.gov/div898/handbook/prc/section2/prc213.htm
Examples
--------
1. Shapiro-Wilk test on a 1D array.
>>> import numpy as np
>>> import pingouin as pg
>>> np.random.seed(123)
>>> x = np.random.normal(size=100)
>>> pg.normality(x)
W pval normal
0 0.98414 0.274886 True
2. Omnibus test on a wide-format dataframe with missing values
>>> data = pg.read_dataset('mediation')
>>> data.loc[1, 'X'] = np.nan
>>> pg.normality(data, method='normaltest').round(3)
W pval normal
X 1.792 0.408 True
M 0.492 0.782 True
Y 0.349 0.840 True
Mbin 839.716 0.000 False
Ybin 814.468 0.000 False
W1 24.816 0.000 False
W2 43.400 0.000 False
3. Pandas Series
>>> pg.normality(data['X'], method='normaltest')
W pval normal
X 1.791839 0.408232 True
4. Long-format dataframe
>>> data = pg.read_dataset('rm_anova2')
>>> pg.normality(data, dv='Performance', group='Time')
W pval normal
Time
Pre 0.967718 0.478773 True
Post 0.940728 0.095157 True
5. Same but using the Jarque-Bera test
>>> pg.normality(data, dv='Performance', group='Time', method="jarque_bera")
W pval normal
Time
Pre 0.304021 0.858979 True
Post 1.265656 0.531088 True
"""
assert isinstance(data, (pd.DataFrame, pd.Series, list, np.ndarray))
assert method in ["shapiro", "normaltest", "jarque_bera"]
if isinstance(data, pd.Series):
data = data.to_frame()
col_names = ["W", "pval"]
func = getattr(scipy.stats, method)
if isinstance(data, (list, np.ndarray)):
data = np.asarray(data)
assert data.ndim == 1, "Data must be 1D."
assert data.size > 3, "Data must have more than 3 samples."
data = remove_na(data)
stats = pd.DataFrame(func(data)).T
stats.columns = col_names
stats["normal"] = np.where(stats["pval"] > alpha, True, False)
else:
# Data is a Pandas DataFrame
if dv is None and group is None:
# Wide-format
# Get numeric data only
numdata = data._get_numeric_data()
stats = numdata.apply(lambda x: func(x.dropna()), result_type="expand", axis=0).T
stats.columns = col_names
stats["normal"] = np.where(stats["pval"] > alpha, True, False)
else:
# Long-format
stats = pd.DataFrame([])
assert group in data.columns
assert dv in data.columns
grp = data.groupby(group, observed=True, sort=False)
cols = grp.groups.keys()
for idx, tmp in grp:
if tmp[dv].count() <= 3:
warnings.warn(f"Group {idx} has less than 4 valid samples. Returning NaN.")
st_grp = pd.DataFrame(
{"W": np.nan, "pval": np.nan, "normal": False}, index=[idx]
)
else:
st_grp = normality(tmp[dv].to_numpy(), method=method, alpha=alpha)
stats = pd.concat([stats, st_grp], axis=0, ignore_index=True)
stats.index = cols
stats.index.name = group
return _postprocess_dataframe(stats)
| (data, dv=None, group=None, method='shapiro', alpha=0.05) | [
0.01754465140402317,
0.02500315010547638,
0.07713178545236588,
-0.026114851236343384,
0.07567647099494934,
-0.03171377629041672,
-0.01976805180311203,
-0.05578714236617088,
0.059021178632974625,
0.07308924198150635,
-0.04378077760338783,
0.009969930164515972,
0.02312336675822735,
0.007443338632583618,
-0.0711083933711052,
0.00896434672176838,
-0.052310552448034286,
0.022395707666873932,
0.01150104496628046,
-0.02352762036025524,
-0.03383611515164375,
0.08060837537050247,
-0.02627655304968357,
0.0062255216762423515,
0.02187017723917961,
0.014462210237979889,
-0.01840369403362274,
-0.040344614535570145,
0.002824729308485985,
0.0118951927870512,
0.02744889073073864,
-0.007170466706156731,
0.015321251004934311,
-0.013582956045866013,
0.03446270897984505,
-0.049116939306259155,
0.007685891818255186,
-0.033148881047964096,
-0.061204154044389725,
0.029692504554986954,
-0.020000498741865158,
-0.025771234184503555,
-0.0011413877364248037,
0.012440936639904976,
-0.018383480608463287,
0.009156367741525173,
0.0432148240506649,
0.048510558903217316,
-0.061770111322402954,
-0.0279339961707592,
-0.005957703106105328,
0.01765582151710987,
0.0580509677529335,
0.03814142569899559,
-0.004492280073463917,
0.04935949295759201,
-0.023426556959748268,
0.02849995344877243,
0.05748501047492027,
-0.0510573610663414,
0.06435734033584595,
0.03456377238035202,
-0.0532403364777565,
-0.04208290949463844,
-0.012774446979165077,
-0.054655227810144424,
-0.025771234184503555,
0.04374035447835922,
0.01481593307107687,
0.008312486112117767,
-0.04875311255455017,
0.019818583503365517,
-0.008504507131874561,
0.0427701435983181,
0.010611684992909431,
0.09386792778968811,
0.009934558533132076,
-0.035109516233205795,
0.017453694716095924,
0.0011527574388310313,
0.03369462490081787,
0.028479740023612976,
0.02356804721057415,
-0.007716210559010506,
-0.04681268706917763,
-0.03799993917346001,
0.01136966235935688,
0.021142518147826195,
0.09006793797016144,
-0.02662016823887825,
-0.02255740948021412,
0.04386163130402565,
0.054574377834796906,
-0.007690944708883762,
-0.012804766185581684,
0.03355313464999199,
0.006826850585639477,
-0.018383480608463287,
0.007685891818255186,
-0.04592332988977432,
0.011804236099123955,
0.08780410885810852,
0.06362967938184738,
0.09176580607891083,
-0.030743567273020744,
0.027994634583592415,
-0.010894662700593472,
0.0003012960369233042,
-0.031168034300208092,
0.04539779946208,
-0.08893602341413498,
-0.00045983967720530927,
-0.014603699557483196,
-0.04555949941277504,
0.0011710751568898559,
-0.09540409594774246,
-0.08068922907114029,
0.0471360944211483,
-0.071553073823452,
0.0027893572114408016,
0.0030900214333087206,
0.038464829325675964,
-0.01754465140402317,
-0.03713079169392586,
0.006351851392537355,
-0.01668561063706875,
0.014340933412313461,
-0.035776536911726,
-0.011420194059610367,
0.0567169263958931,
-0.009985090233385563,
0.023507408797740936,
-0.009050250984728336,
0.04341695085167885,
-0.012380299158394337,
-0.025649957358837128,
0.04076908156275749,
0.015644654631614685,
0.08998708426952362,
-0.03482653945684433,
0.03508930280804634,
-0.014047848992049694,
-0.02605421282351017,
-0.016271250322461128,
0.04216375946998596,
0.03482653945684433,
0.03072335384786129,
0.008984560146927834,
-0.025387192144989967,
-0.021587198600172997,
-0.009105836041271687,
-0.022314857691526413,
0.09459558874368668,
-0.07579774409532547,
0.030864842236042023,
-0.04111269861459732,
0.0024470039643347263,
-0.1034083440899849,
0.001839358708821237,
-0.032016970217227936,
-0.033108457922935486,
-0.019525500014424324,
0.023325493559241295,
0.002458373550325632,
-0.006372063886374235,
0.04386163130402565,
-0.005022863857448101,
-0.015624442137777805,
-0.006831903476268053,
-0.029712717980146408,
0.02744889073073864,
0.036504194140434265,
-0.059425435960292816,
0.027691444382071495,
0.0026731339748948812,
0.008196262642741203,
-0.000937365461140871,
-0.01129891723394394,
-0.011672853492200375,
-0.005240150727331638,
-0.03347228467464447,
-0.009045197628438473,
-0.056150972843170166,
-0.023588258773088455,
-0.06508500128984451,
0.00407539214938879,
0.01649359054863453,
-0.03531164303421974,
-0.015391996130347252,
0.01152125746011734,
-0.031228672713041306,
-0.05999138951301575,
-0.008165944367647171,
-0.013401041738688946,
0.06367010623216629,
0.01114732213318348,
-0.031228672713041306,
-0.055180761963129044,
0.03583717346191406,
-0.06411478668451309,
0.028257399797439575,
0.008772325702011585,
-0.0038707382045686245,
0.041880782693624496,
-0.035938240587711334,
-0.03219888359308243,
-0.05045098066329956,
-0.011096790432929993,
-0.009065411053597927,
-0.005194672383368015,
0.03367441147565842,
-0.020920177921652794,
0.00924227200448513,
0.06047649681568146,
0.020051030442118645,
-0.05101693794131279,
0.08691474795341492,
-0.029732929542660713,
0.029914844781160355,
0.029995694756507874,
-0.010702641680836678,
-0.0776573196053505,
-0.0033174147829413414,
0.05364459380507469,
-0.019970180466771126,
0.052916932851076126,
0.01634199358522892,
0.03189569339156151,
0.025326553732156754,
-0.05380629375576973,
0.024295704439282417,
-0.006452914793044329,
-0.009227112866938114,
-0.033977605402469635,
-0.07834455370903015,
-0.05982968956232071,
-0.028681866824626923,
0.022496771067380905,
0.007028977852314711,
-0.010652109980583191,
-0.01259253267198801,
-0.03173398971557617,
0.019070712849497795,
0.039556317031383514,
-0.03351271152496338,
-0.036201003938913345,
0.015644654631614685,
0.030177609995007515,
0.03909142687916756,
-0.007549455855041742,
-0.016099441796541214,
-0.04378077760338783,
-0.015068592503666878,
0.023244641721248627,
0.02352762036025524,
-0.023709535598754883,
0.011157428845763206,
0.05146161839365959,
0.04972332343459129,
-0.047499921172857285,
-0.02627655304968357,
-0.07236158102750778,
-0.015978164970874786,
0.0549786314368248,
-0.01815103366971016,
-0.04018291085958481,
0.004249726887792349,
0.012804766185581684,
0.06649988889694214,
0.010379238054156303,
0.02845952846109867,
0.028681866824626923,
-0.009813281707465649,
-0.028621230274438858,
-0.012582425959408283,
0.053523316979408264,
-0.002261299407109618,
-0.017413269728422165,
0.05922330543398857,
0.02304251492023468,
0.017302099615335464,
0.006442808546125889,
-0.02692336030304432,
-0.028035059571266174,
0.006518606096506119,
0.012026576325297356,
-0.039475467056035995,
-0.09968920052051544,
0.01370423287153244,
0.011864874511957169,
-0.028176549822092056,
-0.026781870052218437,
-0.0650445744395256,
-0.010662216693162918,
-0.013047318905591965,
-0.020576562732458115,
-0.03607972711324692,
-0.039253126829862595,
0.010348918847739697,
-0.03128930926322937,
0.02898505888879299,
0.01619039848446846,
0.06957222521305084,
0.03456377238035202,
-0.020020712167024612,
0.01610954850912094,
0.0294499509036541,
-0.04127439856529236,
-0.03304781764745712,
-0.04024355113506317,
-0.00674094632267952,
0.050774384289979935,
-0.015482952818274498,
0.00021223368821665645,
0.031754203140735626,
-0.050733957439661026,
0.04382120445370674,
-0.014310615137219429,
0.01246115006506443,
0.07385732233524323,
-0.028115911409258842,
-0.01466433797031641,
0.07975944131612778,
0.016816994175314903,
-0.000515424704644829,
-0.02112230658531189,
0.004755045287311077,
-0.03915206342935562,
0.005598926916718483,
0.014532954432070255,
-0.0362212173640728,
-0.029268037527799606,
0.06189138814806938,
0.04349780082702637,
0.008453975431621075,
0.009707164950668812,
0.025508468970656395,
-0.05283608287572861,
0.05417012423276901,
-0.029308462515473366,
-0.020960602909326553,
0.04499354213476181,
-0.005189619027078152,
-0.04729779437184334,
-0.0008963083382695913,
-0.04754034802317619,
0.03500845283269882,
-0.031168034300208092,
0.028378676623106003,
-0.012824978679418564,
0.00015151653497014195,
0.03614036738872528,
-0.004616082645952702,
0.024538258090615273,
0.0342605821788311,
-0.020232945680618286,
0.015371783636510372,
-0.014047848992049694,
-0.0075646149925887585,
-0.005285629536956549,
0.002882841043174267,
0.06823818385601044,
-0.02273932471871376,
0.0010548520367592573,
0.022880813106894493,
-0.0781020000576973,
0.01660476066172123,
-0.021243581548333168,
-0.00019802161841653287,
-0.012491468340158463,
-0.005861692596226931,
-0.059425435960292816,
-0.04818715527653694,
-0.028904207050800323,
0.01221859734505415,
0.011076577939093113,
0.019212203100323677,
-0.05364459380507469,
0.024558469653129578,
-0.015250506810843945,
0.04644886031746864,
0.0009247325360774994,
-0.017484012991189957,
0.01016700454056263,
0.021526560187339783,
-0.028782932087779045,
-0.019323373213410378,
0.04133503884077072,
-0.05756586417555809,
-0.034503135830163956,
-0.005715150386095047,
-0.028156336396932602,
0.03609994053840637,
0.0018608346581459045,
-0.011288811452686787,
0.0377371720969677,
-0.02910633571445942,
-0.02322443015873432,
-0.05809139460325241,
-0.0011944461148232222,
0.0005609033396467566,
-0.01127870474010706,
-0.028479740023612976,
-0.0063013192266225815,
-0.059465859085321426,
-0.06431691348552704,
-0.011834555305540562,
-0.053442467004060745,
-0.008580304682254791,
0.03882865980267525,
-0.023143578320741653,
0.06916797161102295,
-0.041436102241277695,
-0.014977634884417057,
0.049602046608924866,
0.04220418632030487,
0.04834885522723198,
0.04224461317062378,
0.019859010353684425,
0.04192120581865311,
0.04648928344249725,
-0.07947646826505661,
0.00944945216178894,
0.05813181772828102,
0.039475467056035995,
-0.03294675424695015,
-0.017554758116602898,
-0.0711488202214241,
-0.028297826647758484,
0.019222307950258255,
0.027832932770252228,
0.019363798201084137,
-0.05655522644519806,
-0.0014995321398600936,
0.013805296272039413,
-0.019899435341358185,
-0.07191690057516098,
0.05655522644519806,
-0.017787205055356026,
0.026175489649176598,
-0.001067484961822629,
0.04220418632030487,
0.021789325401186943,
-0.02352762036025524,
-0.03250207379460335,
0.050127577036619186,
0.029268037527799606,
-0.03739355504512787,
-0.0064933402463793755,
-0.024720171466469765,
0.07341264188289642,
0.04390205442905426,
0.06322542577981949,
0.042527589946985245,
-0.039515893906354904,
0.014017529785633087,
-0.022193580865859985,
-0.008428709581494331,
-0.020980816334486008,
0.010561153292655945,
0.0010889610275626183,
0.023285068571567535,
-0.1173955500125885,
0.0026630274951457977,
-0.03165313974022865,
0.052310552448034286,
0.014128699898719788,
-0.012713808566331863,
0.025690382346510887,
-0.0005084765725769103,
0.0277116559445858,
0.012946255505084991,
-0.009808228351175785,
0.006084032356739044,
-0.006836956832557917,
0.060557346791028976,
-0.06140628084540367,
-0.03456377238035202,
0.02391166239976883,
0.006508499849587679,
0.0028550485149025917,
0.007903178222477436,
0.025104213505983353,
0.018777629360556602,
-0.015765931457281113,
-0.057848840951919556,
-0.0023813126608729362,
0.04167865589261055,
0.046933963894844055,
-0.036281853914260864,
0.06144670769572258,
0.0118951927870512,
0.04446801170706749,
0.06932967156171799,
-0.027469104155898094,
-0.000631963717751205,
0.022274430841207504,
-0.019101032987236977,
0.04442758485674858,
-0.04089035838842392,
0.04337652400135994,
0.03199675679206848,
-0.026903146877884865,
-0.029571227729320526,
0.03937440365552902,
0.013865934684872627,
0.011996257118880749,
0.023426556959748268,
-0.028661655262112617,
-0.025366978719830513,
-0.03389675170183182,
-0.05146161839365959,
0.02744889073073864,
-0.05004672706127167,
0.023062728345394135,
0.019869117066264153,
-0.02409357763826847,
0.007579774595797062,
-0.006200255826115608,
0.007306902669370174,
0.012178171426057816,
-0.039778657257556915,
-0.04430631175637245,
0.03753504529595375,
-0.002978851553052664,
0.05028928071260452,
-0.04212333634495735,
0.018434012308716774,
0.02959144115447998,
0.014088274911046028,
-0.0044543808326125145,
-0.042487163096666336,
0.019454754889011383,
-0.004691880661994219,
0.013067531399428844,
-0.012147852219641209,
-0.04070844501256943,
-0.01176381018012762,
0.002391418907791376,
0.025771234184503555,
0.015715399757027626,
0.002718612551689148,
0.0222542192786932,
-0.03171377629041672,
0.06314457952976227,
-0.011207960546016693,
0.004285099450498819,
0.028075486421585083,
-0.018959542736411095,
0.021364858373999596,
0.041961632668972015,
-0.04131482541561127,
0.01683720573782921,
0.00818615686148405,
0.03462441265583038,
0.006260893773287535,
-0.013582956045866013,
0.033108457922935486,
-0.010874450206756592,
-0.017494119703769684,
-0.01161221507936716,
-0.08756155520677567,
0.05469565466046333,
-0.02613506279885769,
-0.037555258721113205,
0.03658504784107208,
0.023022303357720375,
0.02666059508919716,
-0.05392757058143616,
-0.05663607642054558,
-0.016806887462735176,
0.03302760422229767,
0.015199975110590458,
0.013694126158952713,
-0.012552106752991676,
0.035675473511219025,
-0.004752518609166145,
-0.026519104838371277,
-0.04519566893577576,
-0.043053120374679565,
-0.001998533960431814,
-0.06803605705499649,
0.011420194059610367,
-0.033452071249485016,
-0.025084001943469048,
-0.02334570698440075,
-0.04939991980791092,
0.0301169715821743,
0.04511481896042824,
0.051219064742326736,
-0.04733822122216225,
-0.019434543326497078,
0.008691474795341492,
-0.0707041397690773,
0.041880782693624496,
0.029955269768834114,
0.008661155588924885,
-0.037636108696460724,
0.07292754203081131,
0.040344614535570145,
0.005669671576470137,
0.028095697984099388,
0.010490408167243004,
-0.03583717346191406,
0.02605421282351017,
-0.024841448292136192,
0.03749461844563484,
-0.023770174011588097,
0.03989993408322334,
-0.035028666257858276,
-0.005080975592136383,
0.022234005853533745,
-0.03571590036153793,
0.004209301434457302,
0.09257431328296661,
0.005548395216464996,
-0.02609463781118393,
-0.08796581625938416,
0.05970841273665428,
-0.034280795603990555,
-0.01584678329527378,
0.005609033163636923,
0.023729749023914337,
-0.01052072737365961,
0.028257399797439575,
-0.025084001943469048,
0.02906590886414051,
-0.026943571865558624,
-0.052391402423381805,
-0.11699129641056061,
-0.0318552665412426,
-0.0010321126319468021,
0.02714570052921772,
-0.007119935005903244,
-0.027509529143571854,
-0.007918338291347027,
-0.0016107021365314722,
-0.0001564907724969089,
-0.0060335006564855576,
0.0220318790525198,
0.016210611909627914,
-0.014037743210792542,
0.06443819403648376,
0.01348189264535904,
-0.008853176608681679,
-0.009732430800795555,
-0.0041006579995155334,
-0.02666059508919716,
0.04442758485674858,
-0.006427648942917585,
-0.009833494201302528,
-0.030864842236042023,
-0.0488743893802166,
-0.024295704439282417,
0.007903178222477436,
0.03963716700673103,
-0.008883495815098286,
-0.005977915599942207,
0.014189338311553001,
-0.007301849778741598,
-0.03704993799328804,
-0.0039869616739451885,
-0.05174459517002106,
0.02583187259733677,
0.051946721971035004,
0.008474187925457954,
0.02902548387646675,
-0.005080975592136383,
-0.0036761907394975424,
0.002966218627989292,
-0.0056039802730083466,
0.10162962228059769,
-0.009560622274875641,
-0.007089615799486637,
0.007256370969116688,
0.027347827330231667,
-0.020657412707805634,
-0.0008571462240070105,
-0.05598926916718483,
0.027266975492239,
0.01871699094772339,
0.05861692503094673,
0.00886833667755127,
-0.03856589272618294,
0.026983998715877533,
0.006306372582912445,
-0.020798901095986366,
-0.03581696376204491,
-0.021304219961166382,
-0.027529742568731308,
-0.06536797434091568,
-0.029348887503147125,
-0.0049344333820044994,
-0.0224765595048666,
0.0034690103493630886,
-0.024639321491122246,
0.04070844501256943,
0.025649957358837128,
0.012491468340158463,
0.016281357035040855,
-0.020960602909326553,
-0.029874419793486595,
0.003812626702710986,
0.02827761322259903,
0.027832932770252228,
0.01503827329725027,
0.015230294317007065,
0.029793567955493927,
0.0624169185757637,
-0.043578650802373886,
-0.012946255505084991,
0.014290401712059975,
0.02044517919421196,
-0.008120465092360973,
0.026741445064544678,
0.053482890129089355,
-0.037292491644620895,
0.03571590036153793,
-0.021627623587846756,
-0.021405283361673355,
0.05764671415090561,
0.003557441057637334,
0.01968720182776451,
-0.017554758116602898,
-0.02146592177450657,
-0.002657974371686578,
0.05315948650240898,
-0.011399981565773487,
0.04770204797387123,
-0.024558469653129578,
0.02500315010547638,
0.02888399548828602,
-0.003923796582967043,
-0.0030874949879944324,
-0.010874450206756592,
-0.006230575032532215,
-0.05004672706127167,
0.0018924170872196555,
-0.014866464771330357,
0.024113789200782776,
0.008651049807667732,
0.030662715435028076,
-0.01653401553630829,
-0.1134338527917862,
0.0423254631459713,
0.034098878502845764,
0.030218034982681274,
0.02199145406484604,
0.02160741202533245,
-0.07260413467884064,
0.025063788518309593,
-0.05469565466046333,
-0.04454886168241501,
0.05865735188126564,
0.03591802716255188,
0.06536797434091568,
0.061729684472084045,
-0.02409357763826847,
0.009631367400288582,
-0.07131052017211914,
-0.007261424325406551,
-0.02213294245302677,
0.009343335404992104,
0.08748070895671844,
-0.03874780982732773,
0.025932935997843742,
0.025852086022496223,
0.0364435575902462
]
|
32,030 | pingouin.pairwise | pairwise_corr | Pairwise (partial) correlations between columns of a pandas dataframe.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a
Pandas method, in which case this argument is no longer needed.
columns : list or str
Column names in data:
* ``["a", "b", "c"]``: combination between columns a, b, and c.
* ``["a"]``: product between a and all the other numeric columns.
* ``[["a"], ["b", "c"]]``: product between ["a"] and ["b", "c"].
* ``[["a", "d"], ["b", "c"]]``: product between ["a", "d"] and
["b", "c"].
* ``[["a", "d"], None]``: product between ["a", "d"] and all other
numeric columns in dataframe.
If column is None, the function will return the pairwise correlation
between the combination of all the numeric columns in data.
See the examples section for more details on this.
covar : None, string or list
Covariate(s) for partial correlation. Must be one or more columns
in data. Use a list if there are more than one covariate. If
``covar`` is not None, a partial correlation will be computed using
:py:func:`pingouin.partial_corr` function.
.. important:: Only ``method='pearson'`` and ``method='spearman'``
are currently supported in partial correlation.
alternative : string
Defines the alternative hypothesis, or tail of the correlation. Must be one of
"two-sided" (default), "greater" or "less". Both "greater" and "less" return a one-sided
p-value. "greater" tests against the alternative hypothesis that the correlation is
positive (greater than zero), "less" tests against the hypothesis that the correlation is
negative.
method : string
Correlation type:
* ``'pearson'``: Pearson :math:`r` product-moment correlation
* ``'spearman'``: Spearman :math:`\rho` rank-order correlation
* ``'kendall'``: Kendall's :math:`\tau_B` correlation
(for ordinal data)
* ``'bicor'``: Biweight midcorrelation (robust)
* ``'percbend'``: Percentage bend correlation (robust)
* ``'shepherd'``: Shepherd's pi correlation (robust)
* ``'skipped'``: Skipped correlation (robust)
padjust : string
Method used for testing and adjustment of pvalues.
* ``'none'``: no correction
* ``'bonf'``: one-step Bonferroni correction
* ``'sidak'``: one-step Sidak correction
* ``'holm'``: step-down method using Bonferroni adjustments
* ``'fdr_bh'``: Benjamini/Hochberg FDR correction
* ``'fdr_by'``: Benjamini/Yekutieli FDR correction
nan_policy : string
Can be ``'listwise'`` for listwise deletion of missing values
(= complete-case analysis) or ``'pairwise'`` (default) for the more
liberal pairwise deletion (= available-case analysis).
.. versionadded:: 0.2.9
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'X'``: Name(s) of first columns.
* ``'Y'``: Name(s) of second columns.
* ``'method'``: Correlation type.
* ``'covar'``: List of specified covariate(s), only when covariates are passed.
* ``'alternative'``: Tail of the test.
* ``'n'``: Sample size (after removal of missing values).
* ``'r'``: Correlation coefficients.
* ``'CI95'``: 95% parametric confidence intervals.
* ``'p-unc'``: Uncorrected p-values.
* ``'p-corr'``: Corrected p-values.
* ``'p-adjust'``: P-values correction method.
* ``'BF10'``: Bayes Factor of the alternative hypothesis (only for Pearson correlation)
* ``'power'``: achieved power of the test (= 1 - type II error).
Notes
-----
Please refer to the :py:func:`pingouin.corr()` function for a description
of the different methods. Missing values are automatically removed from the
data using a pairwise deletion.
This function is more flexible and gives a much more detailed
output than the :py:func:`pandas.DataFrame.corr()` method (i.e. p-values,
confidence interval, Bayes Factor...). This comes however at
an increased computational cost. While this should not be discernible for
a dataframe with less than 10,000 rows and/or less than 20 columns, this
function can be slow for very large datasets.
A faster alternative to get the r-values and p-values in a matrix format is
to use the :py:func:`pingouin.rcorr` function, which works directly as a
:py:class:`pandas.DataFrame` method (see example below).
This function also works with two-dimensional multi-index columns. In this
case, columns must be list(s) of tuple(s). Please refer to this `example
Jupyter notebook
<https://github.com/raphaelvallat/pingouin/blob/master/notebooks/04_Correlations.ipynb>`_
for more details.
If and only if ``covar`` is specified, this function will compute the
pairwise partial correlation between the variables. If you are only
interested in computing the partial correlation matrix (i.e. the raw
pairwise partial correlation coefficient matrix, without the p-values,
sample sizes, etc), a better alternative is to use the
:py:func:`pingouin.pcorr` function (see example 7).
Examples
--------
1. One-sided spearman correlation corrected for multiple comparisons
>>> import pandas as pd
>>> import pingouin as pg
>>> pd.set_option('display.expand_frame_repr', False)
>>> pd.set_option('display.max_columns', 20)
>>> data = pg.read_dataset('pairwise_corr').iloc[:, 1:]
>>> pg.pairwise_corr(data, method='spearman', alternative='greater', padjust='bonf').round(3)
X Y method alternative n r CI95% p-unc p-corr p-adjust power
0 Neuroticism Extraversion spearman greater 500 -0.325 [-0.39, 1.0] 1.000 1.000 bonf 0.000
1 Neuroticism Openness spearman greater 500 -0.028 [-0.1, 1.0] 0.735 1.000 bonf 0.012
2 Neuroticism Agreeableness spearman greater 500 -0.151 [-0.22, 1.0] 1.000 1.000 bonf 0.000
3 Neuroticism Conscientiousness spearman greater 500 -0.356 [-0.42, 1.0] 1.000 1.000 bonf 0.000
4 Extraversion Openness spearman greater 500 0.243 [0.17, 1.0] 0.000 0.000 bonf 1.000
5 Extraversion Agreeableness spearman greater 500 0.062 [-0.01, 1.0] 0.083 0.832 bonf 0.398
6 Extraversion Conscientiousness spearman greater 500 0.056 [-0.02, 1.0] 0.106 1.000 bonf 0.345
7 Openness Agreeableness spearman greater 500 0.170 [0.1, 1.0] 0.000 0.001 bonf 0.985
8 Openness Conscientiousness spearman greater 500 -0.007 [-0.08, 1.0] 0.560 1.000 bonf 0.036
9 Agreeableness Conscientiousness spearman greater 500 0.161 [0.09, 1.0] 0.000 0.002 bonf 0.976
2. Robust two-sided biweight midcorrelation with uncorrected p-values
>>> pcor = pg.pairwise_corr(data, columns=['Openness', 'Extraversion',
... 'Neuroticism'], method='bicor')
>>> pcor.round(3)
X Y method alternative n r CI95% p-unc power
0 Openness Extraversion bicor two-sided 500 0.247 [0.16, 0.33] 0.000 1.000
1 Openness Neuroticism bicor two-sided 500 -0.028 [-0.12, 0.06] 0.535 0.095
2 Extraversion Neuroticism bicor two-sided 500 -0.343 [-0.42, -0.26] 0.000 1.000
3. One-versus-all pairwise correlations
>>> pg.pairwise_corr(data, columns=['Neuroticism']).round(3)
X Y method alternative n r CI95% p-unc BF10 power
0 Neuroticism Extraversion pearson two-sided 500 -0.350 [-0.42, -0.27] 0.000 6.765e+12 1.000
1 Neuroticism Openness pearson two-sided 500 -0.010 [-0.1, 0.08] 0.817 0.058 0.056
2 Neuroticism Agreeableness pearson two-sided 500 -0.134 [-0.22, -0.05] 0.003 5.122 0.854
3 Neuroticism Conscientiousness pearson two-sided 500 -0.368 [-0.44, -0.29] 0.000 2.644e+14 1.000
4. Pairwise correlations between two lists of columns (cartesian product)
>>> columns = [['Neuroticism', 'Extraversion'], ['Openness']]
>>> pg.pairwise_corr(data, columns).round(3)
X Y method alternative n r CI95% p-unc BF10 power
0 Neuroticism Openness pearson two-sided 500 -0.010 [-0.1, 0.08] 0.817 0.058 0.056
1 Extraversion Openness pearson two-sided 500 0.267 [0.18, 0.35] 0.000 5.277e+06 1.000
5. As a Pandas method
>>> pcor = data.pairwise_corr(covar='Neuroticism', method='spearman')
6. Pairwise partial correlation
>>> pg.pairwise_corr(data, covar=['Neuroticism', 'Openness'])
X Y method covar alternative n r CI95% p-unc
0 Extraversion Agreeableness pearson ['Neuroticism', 'Openness'] two-sided 500 -0.038737 [-0.13, 0.05] 0.388361
1 Extraversion Conscientiousness pearson ['Neuroticism', 'Openness'] two-sided 500 -0.071427 [-0.16, 0.02] 0.111389
2 Agreeableness Conscientiousness pearson ['Neuroticism', 'Openness'] two-sided 500 0.123108 [0.04, 0.21] 0.005944
7. Pairwise partial correlation matrix using :py:func:`pingouin.pcorr`
>>> data[['Neuroticism', 'Openness', 'Extraversion']].pcorr().round(3)
Neuroticism Openness Extraversion
Neuroticism 1.000 0.092 -0.360
Openness 0.092 1.000 0.281
Extraversion -0.360 0.281 1.000
8. Correlation matrix with p-values using :py:func:`pingouin.rcorr`
>>> data[['Neuroticism', 'Openness', 'Extraversion']].rcorr()
Neuroticism Openness Extraversion
Neuroticism - ***
Openness -0.01 - ***
Extraversion -0.35 0.267 -
| @pf.register_dataframe_method
def pairwise_corr(
data,
columns=None,
covar=None,
alternative="two-sided",
method="pearson",
padjust="none",
nan_policy="pairwise",
):
"""Pairwise (partial) correlations between columns of a pandas dataframe.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a
Pandas method, in which case this argument is no longer needed.
columns : list or str
Column names in data:
* ``["a", "b", "c"]``: combination between columns a, b, and c.
* ``["a"]``: product between a and all the other numeric columns.
* ``[["a"], ["b", "c"]]``: product between ["a"] and ["b", "c"].
* ``[["a", "d"], ["b", "c"]]``: product between ["a", "d"] and
["b", "c"].
* ``[["a", "d"], None]``: product between ["a", "d"] and all other
numeric columns in dataframe.
If column is None, the function will return the pairwise correlation
between the combination of all the numeric columns in data.
See the examples section for more details on this.
covar : None, string or list
Covariate(s) for partial correlation. Must be one or more columns
in data. Use a list if there are more than one covariate. If
``covar`` is not None, a partial correlation will be computed using
:py:func:`pingouin.partial_corr` function.
.. important:: Only ``method='pearson'`` and ``method='spearman'``
are currently supported in partial correlation.
alternative : string
Defines the alternative hypothesis, or tail of the correlation. Must be one of
"two-sided" (default), "greater" or "less". Both "greater" and "less" return a one-sided
p-value. "greater" tests against the alternative hypothesis that the correlation is
positive (greater than zero), "less" tests against the hypothesis that the correlation is
negative.
method : string
Correlation type:
* ``'pearson'``: Pearson :math:`r` product-moment correlation
* ``'spearman'``: Spearman :math:`\\rho` rank-order correlation
* ``'kendall'``: Kendall's :math:`\\tau_B` correlation
(for ordinal data)
* ``'bicor'``: Biweight midcorrelation (robust)
* ``'percbend'``: Percentage bend correlation (robust)
* ``'shepherd'``: Shepherd's pi correlation (robust)
* ``'skipped'``: Skipped correlation (robust)
padjust : string
Method used for testing and adjustment of pvalues.
* ``'none'``: no correction
* ``'bonf'``: one-step Bonferroni correction
* ``'sidak'``: one-step Sidak correction
* ``'holm'``: step-down method using Bonferroni adjustments
* ``'fdr_bh'``: Benjamini/Hochberg FDR correction
* ``'fdr_by'``: Benjamini/Yekutieli FDR correction
nan_policy : string
Can be ``'listwise'`` for listwise deletion of missing values
(= complete-case analysis) or ``'pairwise'`` (default) for the more
liberal pairwise deletion (= available-case analysis).
.. versionadded:: 0.2.9
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'X'``: Name(s) of first columns.
* ``'Y'``: Name(s) of second columns.
* ``'method'``: Correlation type.
* ``'covar'``: List of specified covariate(s), only when covariates are passed.
* ``'alternative'``: Tail of the test.
* ``'n'``: Sample size (after removal of missing values).
* ``'r'``: Correlation coefficients.
* ``'CI95'``: 95% parametric confidence intervals.
* ``'p-unc'``: Uncorrected p-values.
* ``'p-corr'``: Corrected p-values.
* ``'p-adjust'``: P-values correction method.
* ``'BF10'``: Bayes Factor of the alternative hypothesis (only for Pearson correlation)
* ``'power'``: achieved power of the test (= 1 - type II error).
Notes
-----
Please refer to the :py:func:`pingouin.corr()` function for a description
of the different methods. Missing values are automatically removed from the
data using a pairwise deletion.
This function is more flexible and gives a much more detailed
output than the :py:func:`pandas.DataFrame.corr()` method (i.e. p-values,
confidence interval, Bayes Factor...). This comes however at
an increased computational cost. While this should not be discernible for
a dataframe with less than 10,000 rows and/or less than 20 columns, this
function can be slow for very large datasets.
A faster alternative to get the r-values and p-values in a matrix format is
to use the :py:func:`pingouin.rcorr` function, which works directly as a
:py:class:`pandas.DataFrame` method (see example below).
This function also works with two-dimensional multi-index columns. In this
case, columns must be list(s) of tuple(s). Please refer to this `example
Jupyter notebook
<https://github.com/raphaelvallat/pingouin/blob/master/notebooks/04_Correlations.ipynb>`_
for more details.
If and only if ``covar`` is specified, this function will compute the
pairwise partial correlation between the variables. If you are only
interested in computing the partial correlation matrix (i.e. the raw
pairwise partial correlation coefficient matrix, without the p-values,
sample sizes, etc), a better alternative is to use the
:py:func:`pingouin.pcorr` function (see example 7).
Examples
--------
1. One-sided spearman correlation corrected for multiple comparisons
>>> import pandas as pd
>>> import pingouin as pg
>>> pd.set_option('display.expand_frame_repr', False)
>>> pd.set_option('display.max_columns', 20)
>>> data = pg.read_dataset('pairwise_corr').iloc[:, 1:]
>>> pg.pairwise_corr(data, method='spearman', alternative='greater', padjust='bonf').round(3)
X Y method alternative n r CI95% p-unc p-corr p-adjust power
0 Neuroticism Extraversion spearman greater 500 -0.325 [-0.39, 1.0] 1.000 1.000 bonf 0.000
1 Neuroticism Openness spearman greater 500 -0.028 [-0.1, 1.0] 0.735 1.000 bonf 0.012
2 Neuroticism Agreeableness spearman greater 500 -0.151 [-0.22, 1.0] 1.000 1.000 bonf 0.000
3 Neuroticism Conscientiousness spearman greater 500 -0.356 [-0.42, 1.0] 1.000 1.000 bonf 0.000
4 Extraversion Openness spearman greater 500 0.243 [0.17, 1.0] 0.000 0.000 bonf 1.000
5 Extraversion Agreeableness spearman greater 500 0.062 [-0.01, 1.0] 0.083 0.832 bonf 0.398
6 Extraversion Conscientiousness spearman greater 500 0.056 [-0.02, 1.0] 0.106 1.000 bonf 0.345
7 Openness Agreeableness spearman greater 500 0.170 [0.1, 1.0] 0.000 0.001 bonf 0.985
8 Openness Conscientiousness spearman greater 500 -0.007 [-0.08, 1.0] 0.560 1.000 bonf 0.036
9 Agreeableness Conscientiousness spearman greater 500 0.161 [0.09, 1.0] 0.000 0.002 bonf 0.976
2. Robust two-sided biweight midcorrelation with uncorrected p-values
>>> pcor = pg.pairwise_corr(data, columns=['Openness', 'Extraversion',
... 'Neuroticism'], method='bicor')
>>> pcor.round(3)
X Y method alternative n r CI95% p-unc power
0 Openness Extraversion bicor two-sided 500 0.247 [0.16, 0.33] 0.000 1.000
1 Openness Neuroticism bicor two-sided 500 -0.028 [-0.12, 0.06] 0.535 0.095
2 Extraversion Neuroticism bicor two-sided 500 -0.343 [-0.42, -0.26] 0.000 1.000
3. One-versus-all pairwise correlations
>>> pg.pairwise_corr(data, columns=['Neuroticism']).round(3)
X Y method alternative n r CI95% p-unc BF10 power
0 Neurotic | (data, columns=None, covar=None, alternative='two-sided', method='pearson', padjust='none', nan_policy='pairwise') | [
-0.013756773434579372,
-0.018204141408205032,
0.05701752379536629,
-0.024092495441436768,
0.012357252649962902,
-0.04835085943341255,
0.006650316994637251,
0.005831337999552488,
0.08268577605485916,
-0.013487236574292183,
-0.02954544499516487,
0.01684608682990074,
0.008993218652904034,
0.030727261677384377,
-0.060003168880939484,
0.0037476064171642065,
-0.028840500861406326,
-0.023740023374557495,
-0.022433804348111153,
-0.02396809495985508,
0.009957333095371723,
0.027347678318619728,
-0.053866010159254074,
0.007230858784168959,
-0.004960524849593639,
0.008713314309716225,
-0.03097606636583805,
-0.009210921823978424,
0.028446560725569725,
0.05871768295764923,
0.01684608682990074,
-0.025108445435762405,
-0.04354065656661987,
0.014326948672533035,
-0.006344495341181755,
-0.04615309461951256,
0.034500785171985626,
-0.03562040254473686,
-0.02071291208267212,
0.0413014218211174,
-0.02072327956557274,
-0.03520572930574417,
-0.03767303377389908,
-0.05635404959321022,
-0.03004305250942707,
0.02823922596871853,
-0.005686202086508274,
0.07057733088731766,
-0.021853262558579445,
-0.0023182807490229607,
0.0365326851606369,
-0.04822646081447601,
-0.02591705694794655,
0.025212112814188004,
0.010527508333325386,
0.0730653703212738,
-0.014233647845685482,
0.07497286051511765,
0.021334921941161156,
-0.04888993501663208,
0.049968086183071136,
-0.005390747915953398,
-0.03491545841097832,
0.0034080930054187775,
0.03947686031460762,
-0.039621997624635696,
0.05822007730603218,
-0.026476865634322166,
0.004483650904148817,
-0.0694991797208786,
-0.042503971606492996,
0.027555014938116074,
0.0025230254977941513,
0.018131572753190994,
-0.0061838096007704735,
-0.026435397565364838,
0.024984043091535568,
-0.058593280613422394,
0.03804624080657959,
-0.009957333095371723,
-0.059381160885095596,
-0.013300633989274502,
0.03369217365980148,
-0.019427426159381866,
-0.006567382253706455,
-0.024714505299925804,
0.02496330998837948,
0.037382762879133224,
0.050051018595695496,
-0.012326152063906193,
-0.05129503831267357,
-0.014793455600738525,
0.04656776785850525,
-0.008879183791577816,
0.010615626350045204,
-0.011476072482764721,
0.02863316424190998,
0.0015744612319394946,
0.04005740210413933,
-0.014409883879125118,
-0.027098875492811203,
0.03290429711341858,
0.009713713079690933,
0.05494416132569313,
0.023366818204522133,
0.008801432326436043,
-0.016224076971411705,
0.03163954243063927,
-0.021853262558579445,
-0.014440984465181828,
-0.07924399524927139,
-0.009096886962652206,
0.0734800398349762,
-0.04279424250125885,
0.03937319293618202,
-0.03562040254473686,
-0.051419440656900406,
0.042960114777088165,
-0.02778308466076851,
0.02633173018693924,
0.03657415136694908,
0.0253157801926136,
-0.006987238302826881,
-0.0556076355278492,
-0.027948953211307526,
0.005149719305336475,
-0.00311782187782228,
-0.01923045702278614,
-0.059464097023010254,
0.0818149670958519,
0.024984043091535568,
-0.007676632143557072,
-0.006375595927238464,
0.03010525368154049,
-0.016732051968574524,
0.026186594739556313,
0.04976074770092964,
-0.024776706472039223,
0.042027100920677185,
-0.02591705694794655,
0.049138739705085754,
0.01925119012594223,
-0.007547046989202499,
0.0187639482319355,
0.03908292204141617,
0.051046233624219894,
0.02488037385046482,
0.012740825302898884,
-0.004058611113578081,
-0.010968098416924477,
-0.009786280803382397,
-0.04619456082582474,
0.05166824534535408,
-0.01591307297348976,
0.03796330466866493,
-0.03253109008073807,
0.007806217297911644,
-0.03387877717614174,
-0.04378945752978325,
-0.05498562753200531,
0.012492021545767784,
-0.05743219703435898,
0.013228066265583038,
0.0019722881261259317,
0.021397121250629425,
-0.014047045260667801,
0.03429345041513443,
-0.04374799132347107,
-0.002742024604231119,
-0.035454533994197845,
-0.018017537891864777,
-0.01923045702278614,
-0.005307813175022602,
-0.031183402985334396,
-0.03655341640114784,
0.04424560070037842,
-0.0074226451106369495,
-0.0581786073744297,
-0.009076152928173542,
-0.02488037385046482,
0.009102070704102516,
-0.06564272195100784,
-0.020453741773962975,
-0.013767140917479992,
-0.011911479756236076,
0.06937477737665176,
0.06265707314014435,
-0.05768100172281265,
0.06585005670785904,
0.012181016616523266,
-0.058510348200798035,
-0.027845285832881927,
-0.0002599804720375687,
0.08218817412853241,
0.0546124204993248,
-0.05349280685186386,
0.04781178757548332,
-0.017685798928141594,
0.014326948672533035,
-0.037776701152324677,
0.041591692715883255,
-0.02674640342593193,
0.00911762099713087,
0.022661874070763588,
0.010346089489758015,
-0.012367619201540947,
-0.014544651843607426,
0.011963313445448875,
0.02351195365190506,
-0.020588509738445282,
0.058925021439790726,
-0.01883651688694954,
0.0611642524600029,
-0.028964903205633163,
-0.029752781614661217,
0.02813555672764778,
0.0346459224820137,
-0.06983091682195663,
0.019614027813076973,
0.033173833042383194,
0.06643059849739075,
-0.029006369411945343,
-0.03512279689311981,
0.0017934603383764625,
-0.005180819891393185,
0.03014671988785267,
-0.020526308566331863,
0.05780540406703949,
0.04640189930796623,
-0.0730653703212738,
-0.0032966495491564274,
-0.008796249516308308,
-0.015581334941089153,
-0.044411469250917435,
-0.029503976926207542,
-0.08625196665525436,
-0.013590904884040356,
0.04930460825562477,
-0.03188834711909294,
0.043001580983400345,
-0.018204141408205032,
0.04055501148104668,
0.02917223982512951,
0.037527896463871,
-0.014306215569376945,
-0.045282281935214996,
0.03953906148672104,
-0.002261263318359852,
0.04988515004515648,
-0.0008747006650082767,
0.01640031300485134,
-0.08198083192110062,
-0.010066185146570206,
-0.028778299689292908,
0.017675433307886124,
-0.06900157034397125,
-0.007127190474420786,
0.027098875492811203,
0.03991226851940155,
-0.0020681810565292835,
0.010346089489758015,
-0.01883651688694954,
-0.0070753563195466995,
0.014212913811206818,
0.00983293168246746,
-0.024569369852542877,
-0.0470653735101223,
-0.010553425177931786,
0.038751184940338135,
0.001255033421330154,
0.010517141781747341,
-0.012015147134661674,
-0.017654698342084885,
0.035496000200510025,
-0.010698560625314713,
-0.0009543956257402897,
0.026642734184861183,
-0.008967301808297634,
-0.0066969674080610275,
-0.028591696172952652,
0.025212112814188004,
-0.007344894111156464,
0.014285481534898281,
-0.0366363525390625,
0.0001647352910367772,
0.042110033333301544,
-0.030001584440469742,
-0.010346089489758015,
0.0450749434530735,
0.033547040075063705,
0.009402708150446415,
-0.052373189479112625,
-0.0215422585606575,
0.03796330466866493,
0.03615947812795639,
0.05593937635421753,
0.011299836449325085,
-0.037755969911813736,
-0.015239229425787926,
-0.0440797284245491,
0.004996808711439371,
-0.01595454104244709,
0.06659647077322006,
0.009651511907577515,
0.00045354850590229034,
-0.01453428529202938,
0.05681018903851509,
-0.03147367388010025,
-0.027990421280264854,
-0.014669054187834263,
0.03588993847370148,
0.034086111932992935,
-0.02247527241706848,
0.015830138698220253,
0.013269533403217793,
-0.03188834711909294,
-0.007453745696693659,
-0.03429345041513443,
0.04412119835615158,
0.02863316424190998,
-0.048682600259780884,
-0.05324400216341019,
0.06124718859791756,
0.035081326961517334,
0.010123202577233315,
0.019831731915473938,
-0.03570333868265152,
-0.006344495341181755,
-0.017043055966496468,
0.005217103753238916,
0.0031281886622309685,
0.0018699156353250146,
-0.00032169546466320753,
0.010688194073736668,
0.046733636409044266,
0.00870294775813818,
0.014834923669695854,
-0.039290256798267365,
0.038688983768224716,
-0.013497603125870228,
0.050009552389383316,
-0.03242742270231247,
0.0376315675675869,
-0.04173683002591133,
-0.03814990818500519,
0.001520035439170897,
0.0034288265742361546,
0.03707175701856613,
0.016338111832737923,
-0.08774478733539581,
0.022392336279153824,
0.010175036266446114,
-0.003916067071259022,
0.08305898308753967,
0.015156295150518417,
0.02301434613764286,
-0.03429345041513443,
0.03939392790198326,
0.04640189930796623,
0.036822956055402756,
0.007909885607659817,
0.001457834499888122,
0.03423124924302101,
0.015653902664780617,
-0.01927192322909832,
0.03402391076087952,
-0.071074940264225,
0.05399041250348091,
-0.04466027393937111,
-0.02347048744559288,
0.0001116863131755963,
-0.05075596272945404,
0.016327746212482452,
-0.007199758198112249,
-0.01925119012594223,
0.035475268959999084,
-0.0005471738404594362,
-0.014731255359947681,
0.010968098416924477,
-0.05295373126864433,
0.028799032792448997,
-0.04370652511715889,
-0.007915069349110126,
0.01602710783481598,
-0.041633158922195435,
-0.023719290271401405,
0.025004776194691658,
-0.015353264287114143,
-0.04094894975423813,
-0.014015944674611092,
-0.04893140494823456,
-0.043955329805612564,
0.0042089298367500305,
-0.0007535384502261877,
-0.01883651688694954,
0.0006359397666528821,
0.0006006277981214225,
0.039186589419841766,
-0.029732048511505127,
-0.002564492868259549,
0.03520572930574417,
-0.07256776094436646,
-0.0143476827070117,
-0.024071762338280678,
-0.02863316424190998,
-0.003980860114097595,
0.04938754439353943,
-0.0346459224820137,
0.018204141408205032,
0.004659886937588453,
-0.065518319606781,
0.0798245370388031,
0.04652630165219307,
-0.013010362163186073,
-0.013570170849561691,
0.08600316196680069,
-0.031660277396440506,
0.03141147270798683,
0.05585644021630287,
0.03912438824772835,
0.06738434731960297,
-0.07758530229330063,
-0.01552950032055378,
0.030685795471072197,
0.028322160243988037,
-0.007028705906122923,
0.005064192693680525,
-0.008215706795454025,
0.0046547031961381435,
0.017623597756028175,
-0.00820015650242567,
0.018473677337169647,
-0.037320561707019806,
-0.025295047089457512,
0.015685003250837326,
-0.014523918740451336,
-0.06323762238025665,
0.053409870713949203,
-0.004755780100822449,
0.0024452742654830217,
0.018960919231176376,
0.011911479756236076,
-0.03277989476919174,
-0.08098562061786652,
-0.04830939322710037,
0.009646328166127205,
0.019054220989346504,
-0.08907174319028854,
-0.04499201104044914,
-0.02072327956557274,
0.06808929145336151,
0.006277111358940601,
0.06244973838329315,
0.059961702674627304,
-0.030893132090568542,
0.021293453872203827,
-0.012502388097345829,
0.002494516782462597,
-0.055400300770998,
-0.052829328924417496,
-0.008117222227156162,
0.008137956261634827,
-0.013373201712965965,
-0.027700150385499,
-0.004188196267932653,
0.05370014160871506,
-0.016151510179042816,
0.0021420447155833244,
-0.0798245370388031,
0.024299832060933113,
-0.014109245501458645,
-0.0468580387532711,
-0.057183392345905304,
-0.013155497610569,
0.012979262508451939,
0.03441785275936127,
-0.06555978953838348,
-0.002559309359639883,
-0.02678786963224411,
-0.027969688177108765,
-0.05075596272945404,
-0.0065310983918607235,
-0.008080937899649143,
-0.020526308566331863,
0.03004305250942707,
-0.07397764921188354,
-0.009407891891896725,
-0.00241546961478889,
0.003936801105737686,
-0.042586907744407654,
0.04515787959098816,
0.0692918449640274,
-0.015726469457149506,
0.08040507882833481,
-0.007858051918447018,
0.05452948808670044,
0.033132366836071014,
-0.0631546825170517,
0.046692170202732086,
-0.004185604862868786,
0.03246888890862465,
0.0008144435123540461,
-0.019645128399133682,
-0.010719294659793377,
0.05125357210636139,
-0.08326631784439087,
-0.010667460970580578,
0.03240668773651123,
-0.04710684344172478,
0.009407891891896725,
-0.037320561707019806,
-0.047189775854349136,
0.04781178757548332,
-0.0058728051371872425,
0.008065388537943363,
0.003568778745830059,
0.036947354674339294,
-0.017623597756028175,
-0.04128068685531616,
-0.01060525979846716,
0.015695368871092796,
-0.009304223582148552,
-0.03340190276503563,
0.10814669728279114,
-0.013933009468019009,
0.04648483172059059,
0.04080381244421005,
-0.036449749022722244,
-0.008402309380471706,
-0.027078140527009964,
-0.023719290271401405,
0.019074954092502594,
-0.0007418757304549217,
0.018204141408205032,
-0.006961321458220482,
0.015467299148440361,
-0.05274639278650284,
-0.06070811301469803,
0.03369217365980148,
-0.019023120403289795,
0.005105660296976566,
0.005774320103228092,
-0.03510206192731857,
-0.022765543311834335,
0.02490110881626606,
-0.02577192150056362,
-0.0078010340221226215,
-0.060832515358924866,
-0.001307515543885529,
0.03703029081225395,
0.05490269139409065,
-0.04227590188384056,
0.044826142489910126,
0.014669054187834263,
-0.03717542812228203,
0.0018310400191694498,
0.03748643025755882,
-0.015581334941089153,
0.013912276364862919,
0.0010885164374485612,
0.019375592470169067,
-0.09636998176574707,
0.034480053931474686,
-0.06833809614181519,
0.019935399293899536,
0.08749598264694214,
0.061413057148456573,
0.03721689432859421,
-0.05672725290060043,
-0.04325038567185402,
0.007375994231551886,
0.0480605885386467,
-0.031100468710064888,
0.0038590498734265566,
0.01223285123705864,
-0.019147520884871483,
0.03435565158724785,
-0.03004305250942707,
-0.03518499806523323,
-0.05038275942206383,
-0.019593294709920883,
-0.02166665904223919,
0.045323748141527176,
-0.03163954243063927,
-0.03516426309943199,
0.04938754439353943,
-0.06634766608476639,
0.04934607446193695,
0.06705261021852493,
-0.027990421280264854,
-0.07090906798839569,
-0.04611162841320038,
-0.007992819882929325,
-0.08849120140075684,
0.004356657154858112,
0.08791065961122513,
-0.030768729746341705,
0.017136357724666595,
0.07936839759349823,
0.04144655913114548,
-0.034044645726680756,
0.01883651688694954,
0.004825755953788757,
-0.036429014056921005,
-0.02071291208267212,
-0.02067144401371479,
0.024299832060933113,
0.009713713079690933,
0.04544815048575401,
-0.0034055013675242662,
-0.007769933436065912,
0.012367619201540947,
0.005180819891393185,
-0.04665070399641991,
0.028944168239831924,
-0.024154696613550186,
-0.05253905802965164,
0.00826235767453909,
-0.029690580442547798,
-0.027140341699123383,
-0.024693772196769714,
-0.00761443143710494,
0.018566979095339775,
0.06547684967517853,
-0.036014340817928314,
0.07364591211080551,
-0.014015944674611092,
-0.0376315675675869,
-0.036014340817928314,
-0.021977664902806282,
0.015384364873170853,
-0.034583721309900284,
0.038688983768224716,
0.012968895025551319,
-0.012212117202579975,
-0.0006783789722248912,
0.03893778473138809,
-0.0007451153942383826,
-0.03288356214761734,
0.03184688091278076,
-0.012585322372615337,
-0.03327750042080879,
0.015902705490589142,
0.02535724826157093,
-0.017633965238928795,
0.0036828138399869204,
-0.026165859773755074,
-0.059007953852415085,
0.03885485231876373,
-0.023180216550827026,
0.000416292721638456,
0.02022567205131054,
-0.04055501148104668,
-0.013248799368739128,
0.01935485750436783,
-0.05121210590004921,
0.013933009468019009,
0.0339617095887661,
-0.0007036480819806457,
0.03139073774218559,
0.027078140527009964,
-0.015633169561624527,
0.02966984733939171,
-0.025585317984223366,
0.03613874316215515,
0.008842899464070797,
0.05067303031682968,
0.028467295691370964,
0.03045772574841976,
0.037818171083927155,
0.05224878713488579,
0.08525674790143967,
-0.04181976243853569,
0.026580533012747765,
0.06406696140766144,
-0.010257971473038197,
-0.053783077746629715,
-0.031743209809064865,
-0.047189775854349136,
0.009978067129850388,
0.03885485231876373,
0.05726632848381996,
-0.0035091694444417953,
-0.03943539410829544,
0.004022327251732349,
-0.014824556186795235,
0.08422006666660309,
0.008998402394354343,
-0.03810844197869301,
-0.08392979949712753,
0.004628786351531744,
-0.015218495391309261,
0.03618021309375763,
0.005955739878118038,
0.00988476537168026,
0.013611637987196445,
-0.04123922064900398,
-0.04602869227528572,
0.03899998590350151,
0.004481059033423662,
0.009267939254641533,
-0.008350475691258907,
0.05075596272945404,
0.05075596272945404,
0.021708127111196518,
0.06191066652536392,
0.0348532572388649,
-0.003444376867264509,
0.032655492424964905,
-0.03246888890862465,
-0.026497598737478256,
0.05552470311522484,
-0.0005999798886477947,
0.0201531033962965,
-0.022869210690259933,
0.05125357210636139,
-0.022330136969685555,
0.009127987548708916,
0.013549437746405602,
-0.05399041250348091,
0.02390589378774166,
0.034521520137786865,
0.010092101991176605,
0.0010787975043058395,
0.04694097489118576,
-0.006204543635249138,
0.08849120140075684,
0.006095691584050655,
-0.030789462849497795,
-0.026062192395329475,
0.023885158821940422,
-0.024154696613550186,
0.03147367388010025,
0.050548627972602844,
-0.000732156855519861,
-0.016089309006929398,
0.03226155415177345,
-0.015602068044245243,
0.017001589760184288,
0.04412119835615158,
-0.046733636409044266,
-0.006437797099351883,
0.022413071244955063,
-0.05229025334119797,
0.014254380948841572,
0.045323748141527176,
-0.02259967289865017,
-0.02496330998837948,
0.019375592470169067,
-0.06398402899503708,
0.02257893979549408,
-0.007686999160796404,
-0.017198558896780014,
-0.008713314309716225,
-0.06887716799974442,
0.005945372860878706,
0.005263754166662693,
-0.008267541415989399,
-0.017934603616595268,
-0.05585644021630287,
-0.043416254222393036,
0.020370807498693466,
0.011030299589037895,
0.0685039609670639,
0.044826142489910126,
0.04036840796470642,
-0.0021057608537375927,
0.05954702943563461
]
|
32,031 | pingouin.pairwise | pairwise_gameshowell | Pairwise Games-Howell post-hoc test.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame
dv : string
Name of column containing the dependent variable.
between: string
Name of column containing the between factor.
effsize : string or None
Effect size type. Available methods are:
* ``'none'``: no effect size
* ``'cohen'``: Unbiased Cohen d
* ``'hedges'``: Hedges g
* ``'r'``: Pearson correlation coefficient
* ``'eta-square'``: Eta-square
* ``'odds-ratio'``: Odds ratio
* ``'AUC'``: Area Under the Curve
* ``'CLES'``: Common Language Effect Size
Returns
-------
stats : :py:class:`pandas.DataFrame`
Stats summary:
* ``'A'``: Name of first measurement
* ``'B'``: Name of second measurement
* ``'mean(A)'``: Mean of first measurement
* ``'mean(B)'``: Mean of second measurement
* ``'diff'``: Mean difference (= mean(A) - mean(B))
* ``'se'``: Standard error
* ``'T'``: T-values
* ``'df'``: adjusted degrees of freedom
* ``'pval'``: Games-Howell corrected p-values
* ``'hedges'``: Hedges effect size (or any effect size defined in
``effsize``)
See also
--------
pairwise_tests, pairwise_tukey
Notes
-----
Games-Howell [1]_ is very similar to the Tukey HSD post-hoc test but is much more robust to
heterogeneity of variances. While the Tukey-HSD post-hoc is optimal after a classic one-way
ANOVA, the Games-Howell is optimal after a Welch ANOVA. Please note that Games-Howell
is not valid for repeated measures ANOVA. Only one-way ANOVA design are supported.
Compared to the Tukey-HSD test, the Games-Howell test uses different pooled variances for
each pair of variables instead of the same pooled variance.
The T-values are defined as:
.. math::
t = \frac{\overline{x}_i - \overline{x}_j}
{\sqrt{(\frac{s_i^2}{n_i} + \frac{s_j^2}{n_j})}}
and the corrected degrees of freedom are:
.. math::
v = \frac{(\frac{s_i^2}{n_i} + \frac{s_j^2}{n_j})^2}
{\frac{(\frac{s_i^2}{n_i})^2}{n_i-1} +
\frac{(\frac{s_j^2}{n_j})^2}{n_j-1}}
where :math:`\overline{x}_i`, :math:`s_i^2`, and :math:`n_i` are the mean, variance and sample
size of the first group and :math:`\overline{x}_j`, :math:`s_j^2`, and :math:`n_j` the mean,
variance and sample size of the second group.
The p-values are then approximated using the Studentized range distribution
:math:`Q(\sqrt2|t_i|, r, v_i)`.
References
----------
.. [1] Games, Paul A., and John F. Howell. "Pairwise multiple comparison
procedures with unequal n's and/or variances: a Monte Carlo study."
Journal of Educational Statistics 1.2 (1976): 113-125.
.. [2] Gleason, John R. "An accurate, non-iterative approximation for
studentized range quantiles." Computational statistics & data
analysis 31.2 (1999): 147-158.
Examples
--------
Pairwise Games-Howell post-hocs on the Penguins dataset.
>>> import pingouin as pg
>>> df = pg.read_dataset('penguins')
>>> pg.pairwise_gameshowell(data=df, dv='body_mass_g',
... between='species').round(3)
A B mean(A) mean(B) diff se T df pval hedges
0 Adelie Chinstrap 3700.662 3733.088 -32.426 59.706 -0.543 152.455 0.85 -0.074
1 Adelie Gentoo 3700.662 5076.016 -1375.354 58.811 -23.386 249.643 0.00 -2.860
2 Chinstrap Gentoo 3733.088 5076.016 -1342.928 65.103 -20.628 170.404 0.00 -2.875
| def pairwise_gameshowell(data=None, dv=None, between=None, effsize="hedges"):
"""Pairwise Games-Howell post-hoc test.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame
dv : string
Name of column containing the dependent variable.
between: string
Name of column containing the between factor.
effsize : string or None
Effect size type. Available methods are:
* ``'none'``: no effect size
* ``'cohen'``: Unbiased Cohen d
* ``'hedges'``: Hedges g
* ``'r'``: Pearson correlation coefficient
* ``'eta-square'``: Eta-square
* ``'odds-ratio'``: Odds ratio
* ``'AUC'``: Area Under the Curve
* ``'CLES'``: Common Language Effect Size
Returns
-------
stats : :py:class:`pandas.DataFrame`
Stats summary:
* ``'A'``: Name of first measurement
* ``'B'``: Name of second measurement
* ``'mean(A)'``: Mean of first measurement
* ``'mean(B)'``: Mean of second measurement
* ``'diff'``: Mean difference (= mean(A) - mean(B))
* ``'se'``: Standard error
* ``'T'``: T-values
* ``'df'``: adjusted degrees of freedom
* ``'pval'``: Games-Howell corrected p-values
* ``'hedges'``: Hedges effect size (or any effect size defined in
``effsize``)
See also
--------
pairwise_tests, pairwise_tukey
Notes
-----
Games-Howell [1]_ is very similar to the Tukey HSD post-hoc test but is much more robust to
heterogeneity of variances. While the Tukey-HSD post-hoc is optimal after a classic one-way
ANOVA, the Games-Howell is optimal after a Welch ANOVA. Please note that Games-Howell
is not valid for repeated measures ANOVA. Only one-way ANOVA design are supported.
Compared to the Tukey-HSD test, the Games-Howell test uses different pooled variances for
each pair of variables instead of the same pooled variance.
The T-values are defined as:
.. math::
t = \\frac{\\overline{x}_i - \\overline{x}_j}
{\\sqrt{(\\frac{s_i^2}{n_i} + \\frac{s_j^2}{n_j})}}
and the corrected degrees of freedom are:
.. math::
v = \\frac{(\\frac{s_i^2}{n_i} + \\frac{s_j^2}{n_j})^2}
{\\frac{(\\frac{s_i^2}{n_i})^2}{n_i-1} +
\\frac{(\\frac{s_j^2}{n_j})^2}{n_j-1}}
where :math:`\\overline{x}_i`, :math:`s_i^2`, and :math:`n_i` are the mean, variance and sample
size of the first group and :math:`\\overline{x}_j`, :math:`s_j^2`, and :math:`n_j` the mean,
variance and sample size of the second group.
The p-values are then approximated using the Studentized range distribution
:math:`Q(\\sqrt2|t_i|, r, v_i)`.
References
----------
.. [1] Games, Paul A., and John F. Howell. "Pairwise multiple comparison
procedures with unequal n's and/or variances: a Monte Carlo study."
Journal of Educational Statistics 1.2 (1976): 113-125.
.. [2] Gleason, John R. "An accurate, non-iterative approximation for
studentized range quantiles." Computational statistics & data
analysis 31.2 (1999): 147-158.
Examples
--------
Pairwise Games-Howell post-hocs on the Penguins dataset.
>>> import pingouin as pg
>>> df = pg.read_dataset('penguins')
>>> pg.pairwise_gameshowell(data=df, dv='body_mass_g',
... between='species').round(3)
A B mean(A) mean(B) diff se T df pval hedges
0 Adelie Chinstrap 3700.662 3733.088 -32.426 59.706 -0.543 152.455 0.85 -0.074
1 Adelie Gentoo 3700.662 5076.016 -1375.354 58.811 -23.386 249.643 0.00 -2.860
2 Chinstrap Gentoo 3733.088 5076.016 -1342.928 65.103 -20.628 170.404 0.00 -2.875
"""
# Check the dataframe
data = _check_dataframe(dv=dv, between=between, effects="between", data=data)
# Reset index (avoid duplicate axis error)
data = data.reset_index(drop=True)
# Extract infos
ng = data[between].nunique()
grp = data.groupby(between, observed=True)[dv] # default is sort=True
# Careful: pd.unique does NOT sort whereas numpy does
# The line below should be equal to labels = np.unique(data[between])
# However, this does not work if between is a Categorical column, because
# Pandas applies a custom, not alphabetical, sorting.
# See https://github.com/raphaelvallat/pingouin/issues/111
labels = np.array(list(grp.groups.keys()))
n = grp.count().to_numpy()
gmeans = grp.mean(numeric_only=True).to_numpy()
gvars = grp.var(numeric_only=True).to_numpy() # numeric_only=True added in pandas 1.5
# Pairwise combinations
g1, g2 = np.array(list(combinations(np.arange(ng), 2))).T
mn = gmeans[g1] - gmeans[g2]
se = np.sqrt(gvars[g1] / n[g1] + gvars[g2] / n[g2])
tval = mn / np.sqrt(gvars[g1] / n[g1] + gvars[g2] / n[g2])
df = (gvars[g1] / n[g1] + gvars[g2] / n[g2]) ** 2 / (
(((gvars[g1] / n[g1]) ** 2) / (n[g1] - 1)) + (((gvars[g2] / n[g2]) ** 2) / (n[g2] - 1))
)
# Compute corrected p-values
pval = studentized_range.sf(np.sqrt(2) * np.abs(tval), ng, df)
pval = np.clip(pval, 0, 1)
# Uncorrected p-values
# from scipy.stats import t
# punc = t.sf(np.abs(tval), n[g1].size + n[g2].size - 2) * 2
# Effect size
# Method 1: Approximation
# d = tval * np.sqrt(1 / n[g1] + 1 / n[g2])
# ef = convert_effsize(d, "cohen", effsize, n[g1], n[g2])
# Method 2: Exact
ef = []
for idx_a, idx_b in zip(g1, g2):
ef.append(
compute_effsize(
grp.get_group(labels[idx_a]),
grp.get_group(labels[idx_b]),
paired=False,
eftype=effsize,
)
)
# Create dataframe
stats = pd.DataFrame(
{
"A": labels[g1],
"B": labels[g2],
"mean(A)": gmeans[g1],
"mean(B)": gmeans[g2],
"diff": mn,
"se": se,
"T": tval,
"df": df,
"pval": pval,
effsize: ef,
}
)
return _postprocess_dataframe(stats)
| (data=None, dv=None, between=None, effsize='hedges') | [
0.026769651100039482,
-0.019592957571148872,
-0.043993718922138214,
-0.014750148169696331,
0.014843503944575787,
-0.016815636307001114,
0.0100298672914505,
-0.0703432708978653,
-0.015870412811636925,
0.021740131080150604,
-0.01590542122721672,
0.012743007391691208,
0.02557937055826187,
0.029476957395672798,
-0.04719113931059837,
0.013629883527755737,
0.018005916848778725,
-0.026442907750606537,
0.026606280356645584,
-0.023093784227967262,
0.0029144377913326025,
-0.024832528084516525,
-0.046374280005693436,
-0.0011822582455351949,
-0.009125486947596073,
0.027073057368397713,
-0.03827570006251335,
-0.01589375175535679,
-0.006283983122557402,
0.029523635283112526,
0.002489962615072727,
-0.05535973235964775,
-0.03262770175933838,
-0.009831487201154232,
-0.010473305359482765,
-0.02396899089217186,
0.015298610553145409,
-0.016162147745490074,
-0.032954443246126175,
0.05881388112902641,
0.0019546279218047857,
-0.03353791683912277,
0.05605989694595337,
-0.007480098865926266,
-0.02639622986316681,
-0.011681090109050274,
0.008040230721235275,
0.026186181232333183,
-0.004279760178178549,
-0.019803008064627647,
0.022627007216215134,
-0.0663289874792099,
-0.019371239468455315,
0.025135932490229607,
0.0011851756135001779,
0.07697150111198425,
0.01165775116533041,
0.013886610977351665,
0.051112063229084015,
-0.06628230959177017,
0.038182344287633896,
0.03463483974337578,
0.03020046092569828,
0.015765387564897537,
-0.04151979833841324,
-0.027516495436429977,
0.016302181407809258,
-0.0458141453564167,
-0.03766889125108719,
-0.01869441196322441,
0.005306669045239687,
0.040562909096479416,
0.04219662770628929,
0.01727074384689331,
-0.0321609228849411,
0.02557937055826187,
0.033374544233083725,
-0.042873453348875046,
0.0432935506105423,
-0.00015744601842015982,
0.03370128944516182,
0.021845156326889992,
-0.005598404910415411,
-0.04467054456472397,
-0.01808760315179825,
-0.026139503344893456,
0.020374808460474014,
0.05928066000342369,
0.017725851386785507,
-0.08495338261127472,
-0.0015622436767444015,
-0.005592570174485445,
0.05736687406897545,
-0.04231331869959831,
0.008559520356357098,
-0.000844574358779937,
-0.03692204877734184,
0.003261603182181716,
-0.04004945233464241,
0.007013321854174137,
0.03386465832591057,
0.057880327105522156,
0.03428475931286812,
0.05097202956676483,
-0.00990733876824379,
-0.01945292390882969,
-0.053259238600730896,
0.016827305778861046,
-0.04042287543416023,
-0.022802049294114113,
-0.06194128841161728,
0.020456494763493538,
-0.01780753582715988,
-0.021343370899558067,
0.01631385087966919,
-0.02901018038392067,
-0.00910214800387621,
0.07393745332956314,
-0.05157884210348129,
-0.0015461982693523169,
0.0026650039944797754,
-0.00394718162715435,
-0.056760065257549286,
-0.007491768337786198,
-0.017294082790613174,
-0.039676032960414886,
0.035918477922677994,
0.013979966752231121,
-0.06651569902896881,
-0.031834181398153305,
0.054426178336143494,
-0.006639900617301464,
-0.00958059448748827,
0.036571964621543884,
-0.001176423509605229,
-0.002611032919958234,
0.060914378613233566,
-0.014365057460963726,
0.09092812985181808,
-0.039606016129255295,
0.04151979833841324,
-0.011914478614926338,
-0.049338310956954956,
-0.0023178388364613056,
0.035918477922677994,
-0.0007541363593190908,
0.016407206654548645,
0.0013142685638740659,
0.031834181398153305,
0.03323451057076454,
0.02295375056564808,
-0.02010641247034073,
0.07071669399738312,
-0.04306016489863396,
0.06483530253171921,
-0.049758411943912506,
0.03339788317680359,
-0.050878673791885376,
-0.021343370899558067,
-0.04294347018003464,
-0.014435073360800743,
-0.0896211564540863,
0.024062346667051315,
0.07916535437107086,
0.01910284161567688,
-0.001932747894898057,
0.00530958641320467,
0.016582246869802475,
0.03661864250898361,
-0.04758789762854576,
-0.03302446007728577,
0.025439336895942688,
-0.03904588147997856,
-0.009277190081775188,
-0.00866454467177391,
0.010374114848673344,
-0.0023368014954030514,
-0.0549396350979805,
0.020374808460474014,
-0.08654042333364487,
-0.018239304423332214,
-0.025439336895942688,
-0.010035702027380466,
0.0016060040798038244,
-0.07561784982681274,
0.01654723845422268,
0.06044759973883629,
-0.018309321254491806,
-0.020444825291633606,
0.004787379875779152,
-0.07010988146066666,
-0.07407748699188232,
-0.05036522075533867,
0.0475645586848259,
0.04516065865755081,
0.03267437964677811,
-0.003967603202909231,
0.033911336213350296,
0.0047348677180707455,
-0.0028590080328285694,
0.011756941676139832,
0.027796560898423195,
-0.03204422816634178,
-0.012474611401557922,
-0.0014790991554036736,
-0.014446742832660675,
-0.03211424499750137,
-0.015111899934709072,
0.044460494071245193,
-0.02480918914079666,
0.003777974983677268,
-0.023630578070878983,
-0.022463634610176086,
0.08047232776880264,
0.05820707231760025,
-0.03001375123858452,
0.02450578473508358,
-0.018472693860530853,
0.0016672685742378235,
-0.003915090579539537,
-0.021681783720850945,
-0.07258380204439163,
-0.03615186735987663,
0.07841850817203522,
0.041729848831892014,
0.01987302303314209,
0.0504118986427784,
0.07309725135564804,
0.04140310734510422,
-0.011074280366301537,
-0.0033491237554699183,
0.015088560990989208,
0.016337189823389053,
-0.026909684762358665,
0.0006148326210677624,
0.021880164742469788,
-0.0793987438082695,
-0.02473917230963707,
-0.023898974061012268,
0.03311781585216522,
-0.011190975084900856,
-0.057646941393613815,
-0.0022332353983074427,
0.03447147086262703,
-0.02812330424785614,
-0.06352832913398743,
0.032604362815618515,
0.006593222729861736,
-0.0030573883559554815,
0.017655834555625916,
0.000018016948160948232,
-0.07099675387144089,
0.006278148386627436,
0.0017970908666029572,
-0.037342146039009094,
-0.0321609228849411,
0.007118346635252237,
0.03162413090467453,
0.05867384746670723,
-0.053492624312639236,
0.007205867674201727,
-0.010018197819590569,
-0.04516065865755081,
0.005688842851668596,
-0.018227634951472282,
0.02200852707028389,
-0.03708542138338089,
0.009382214397192001,
0.01993137039244175,
-0.017830874770879745,
-0.05433282256126404,
0.017527470365166664,
-0.04392370209097862,
0.02373560145497322,
-0.028730114921927452,
0.06838280707597733,
0.03316449373960495,
-0.013209784403443336,
0.011727767996490002,
-0.03188085928559303,
0.00036120504955761135,
-0.02052651159465313,
-0.020083073526620865,
-0.006050594616681337,
-0.015928760170936584,
-0.009977354668080807,
-0.028870146721601486,
-0.03839239478111267,
0.09438227862119675,
0.006132280919700861,
-0.054612889885902405,
-0.03379464149475098,
0.010875900276005268,
0.02148340456187725,
0.04392370209097862,
0.08037897199392319,
0.01840267702937126,
0.005916396621614695,
-0.008623702451586723,
0.002877970924600959,
0.04716780036687851,
-0.013116429559886456,
0.06362168490886688,
0.04961837828159332,
-0.0668424442410469,
0.04000277444720268,
0.07062333822250366,
-0.0658155307173729,
0.03484489023685455,
-0.09083477407693863,
0.010321603156626225,
0.061614543199539185,
0.016663933172822,
0.051345452666282654,
0.04462386667728424,
-0.038999203592538834,
-0.041216395795345306,
-0.04320019483566284,
0.03713209927082062,
0.02623285911977291,
-0.021856825798749924,
-0.018974479287862778,
0.06996984779834747,
0.030247138813138008,
0.07543113827705383,
0.0006925071938894689,
0.01863606460392475,
-0.023397188633680344,
0.07323728501796722,
-0.008308627642691135,
-0.08243279159069061,
-0.03874247893691063,
0.05998082458972931,
0.017644165083765984,
-0.019067833200097084,
-0.016698941588401794,
-0.0036817023064941168,
0.035988494753837585,
0.048684824258089066,
-0.021845156326889992,
0.049338310956954956,
0.007585123647004366,
-0.02450578473508358,
-0.007491768337786198,
0.05559312179684639,
-0.033141154795885086,
-0.031600791960954666,
0.0187994372099638,
-0.017469123005867004,
0.011377685703337193,
-0.01851937174797058,
0.021880164742469788,
0.025906113907694817,
0.027493156492710114,
0.05619993060827255,
0.013419833965599537,
0.027516495436429977,
-0.023747270926833153,
-0.004011363256722689,
0.03377130255103111,
0.026186181232333183,
0.006108941975980997,
0.017900891602039337,
0.032020892947912216,
-0.005913479253649712,
-0.030107107013463974,
-0.003777974983677268,
-0.018951140344142914,
-0.00658738799393177,
0.026256198063492775,
-0.005058694165199995,
-0.04567411541938782,
0.015193586237728596,
0.03990941867232323,
0.02996707335114479,
0.022638676688075066,
-0.03150743618607521,
-0.019592957571148872,
-0.0019604626577347517,
-0.017282413318753242,
0.032184261828660965,
-0.0026679213624447584,
-0.02473917230963707,
0.06506869196891785,
0.03538168594241142,
-0.016768958419561386,
0.040912989526987076,
-0.005286247935146093,
0.025836098939180374,
-0.040912989526987076,
0.006505702156573534,
-0.0029173551592975855,
0.06100773438811302,
0.04042287543416023,
-0.007666809484362602,
0.013536528684198856,
-0.062034640461206436,
-0.0073809088207781315,
-0.060494277626276016,
0.015356957912445068,
-0.009236346930265427,
-0.023467205464839935,
0.05470624566078186,
-0.03832237794995308,
-0.044227104634046555,
-0.03981606289744377,
-0.014236693270504475,
0.0027291858568787575,
-0.03703874349594116,
0.026069486513733864,
-0.08238611370325089,
0.0484047569334507,
-0.034144725650548935,
-0.03038717247545719,
-0.008028561249375343,
-0.006424016319215298,
-0.02746981754899025,
0.037762247025966644,
0.010998429730534554,
0.02113332226872444,
0.06618895381689072,
-0.08434657752513885,
0.004384784959256649,
0.029640330001711845,
0.014365057460963726,
0.00391800794750452,
-0.0715102106332779,
-0.005134545266628265,
-0.026326213032007217,
-0.029383601620793343,
0.011727767996490002,
0.015030214563012123,
-0.026209520176053047,
-0.003970520570874214,
0.05097202956676483,
-0.005455454345792532,
-0.05559312179684639,
0.05624660849571228,
0.04147312045097351,
0.0230704452842474,
-0.04324687272310257,
0.03386465832591057,
0.031834181398153305,
0.01923120580613613,
0.0034599832724779844,
-0.022883733734488487,
-0.012929718010127544,
-0.05078532174229622,
-0.04308350384235382,
-0.0597941130399704,
0.08952780067920685,
0.039489321410655975,
0.0696897804737091,
0.02378227934241295,
-0.030340494588017464,
-0.0027291858568787575,
-0.056573353707790375,
-0.02931358478963375,
-0.05951404571533203,
0.052419040352106094,
-0.0064590247347950935,
-0.006248974706977606,
-0.0660022422671318,
0.07697150111198425,
-0.019196197390556335,
-0.0036408593878149986,
0.014913519844412804,
-0.055499766021966934,
-0.011412694118916988,
0.014610115438699722,
-0.0024797520600259304,
-0.023292163386940956,
0.023362180218100548,
0.005735520273447037,
-0.013046412728726864,
-0.004758206196129322,
-0.03398135304450989,
-0.011243486776947975,
-0.016990676522254944,
0.006196462549269199,
0.015695370733737946,
0.003658363362774253,
0.027329783886671066,
0.037878941744565964,
0.016453882679343224,
0.03199755400419235,
0.002428698353469372,
0.01056666113436222,
-0.006103107240051031,
-0.03430809825658798,
0.0006075392011553049,
-0.04366697371006012,
0.008046065457165241,
0.007841850630939007,
-0.03708542138338089,
0.017784196883440018,
0.05036522075533867,
-0.047027766704559326,
0.03857910633087158,
-0.07459093630313873,
0.048264726996421814,
-0.02319880947470665,
0.022451965138316154,
-0.05867384746670723,
0.07421752065420151,
-0.017177388072013855,
0.03136740252375603,
0.05718016251921654,
-0.026979701593518257,
0.03423808142542839,
-0.0005896704387851059,
-0.07809176295995712,
0.07207034528255463,
-0.026956362649798393,
0.061614543199539185,
-0.02004806511104107,
-0.006353999953716993,
0.013478181324899197,
-0.011488544754683971,
-0.011406859382987022,
0.03412138670682907,
-0.04632760211825371,
0.006353999953716993,
0.03815900534391403,
0.0008336342871189117,
0.009656446054577827,
0.03542836382985115,
0.04700442776083946,
-0.014096660539507866,
-0.0415431372821331,
-0.02272036299109459,
-0.005974743515253067,
0.03694538772106171,
0.051112063229084015,
-0.012241222895681858,
0.008769569918513298,
-0.016302181407809258,
-0.046374280005693436,
0.03181084245443344,
0.013991636224091053,
0.0364319309592247,
-0.02550935372710228,
-0.007065834477543831,
-0.05601321905851364,
-0.0063306610099971294,
0.031834181398153305,
0.013209784403443336,
-0.018659403547644615,
-0.022755371406674385,
-0.030643898993730545,
0.03650194779038429,
-0.009189669042825699,
0.03827570006251335,
0.013711569830775261,
-0.0019750494975596666,
0.022463634610176086,
0.03958267718553543,
-0.0007964379619807005,
0.019954709336161613,
-0.018134281039237976,
-0.04952502250671387,
-0.06903629750013351,
0.012929718010127544,
-0.04415708780288696,
0.005551727022975683,
-0.0050995368510484695,
0.02539266087114811,
0.027376461774110794,
-0.10614505410194397,
-0.014925189316272736,
-0.030643898993730545,
0.08635371178388596,
0.005691760219633579,
-0.01644221507012844,
0.006365668959915638,
0.004895322024822235,
0.006429851055145264,
-0.03309447690844536,
0.010006528347730637,
-0.04481057822704315,
-0.061847932636737823,
0.0016716445097699761,
-0.004860313609242439,
0.012124528177082539,
-0.0075151072815060616,
0.07048330456018448,
-0.055873189121484756,
0.027073057368397713,
0.040026113390922546,
0.017224065959453583,
-0.052185650914907455,
0.004518983419984579,
-0.029150214046239853,
-0.039769385010004044,
0.000953245849814266,
0.028800131753087044,
0.024645816534757614,
-0.004367280751466751,
0.052092295140028,
0.0034920743200927973,
-0.0061672888696193695,
0.039069220423698425,
-0.01648889109492302,
0.010385784320533276,
0.049384988844394684,
-0.033491238951683044,
0.03897586464881897,
0.02129669301211834,
-0.03120403178036213,
-0.03136740252375603,
0.039956096559762955,
0.02985037863254547,
-0.000580553722102195,
-0.058533813804388046,
0.025999469682574272,
-0.028169982135295868,
-0.001985260285437107,
0.010560826398432255,
0.026046147570014,
-0.02082991600036621,
0.007719322107732296,
0.03731880709528923,
-0.011482710018754005,
0.0492449551820755,
0.0051199584268033504,
-0.05806703865528107,
0.03808898851275444,
-0.01417834684252739,
-0.023688925430178642,
-0.060727667063474655,
0.0014615949476137757,
0.043223533779382706,
0.023047106340527534,
-0.03965269401669502,
0.0008671838440932333,
-0.003862578421831131,
0.058533813804388046,
-0.011465205810964108,
-0.03419140353798866,
0.03351457789540291,
0.007439255714416504,
-0.021553421393036842,
0.029173552989959717,
0.04567411541938782,
0.022650346159934998,
-0.002593528712168336,
0.020328130573034286,
-0.025299305096268654,
-0.005589652806520462,
0.03223093971610069,
0.05848713964223862,
-0.004772793035954237,
-0.017830874770879745,
-0.052839137613773346,
-0.031040659174323082,
0.013011404313147068,
0.03813566640019417,
-0.009154660627245903,
0.035918477922677994,
-0.015648692846298218,
0.014411735348403454,
0.06310822814702988,
-0.011756941676139832,
0.011908643878996372,
0.03981606289744377,
0.05167219787836075,
0.04775127023458481,
0.04492726922035217,
0.008104412816464901,
0.0540994368493557,
-0.0015505743212997913,
0.024599138647317886,
-0.06110108643770218,
0.009860660880804062,
-0.01136601623147726,
-0.062034640461206436,
-0.00827361922711134,
0.02777322195470333,
-0.0660022422671318,
-0.04228998348116875,
0.01379325520247221,
0.06642234325408936,
-0.009090478532016277,
-0.06847616285085678,
0.011313503608107567,
0.006937470752745867,
0.04520733654499054,
-0.06371504068374634,
0.011383520439267159,
-0.06390175223350525,
-0.06544211506843567,
-0.027679866179823875,
-0.004256421234458685,
0.014656792394816875,
-0.004664850886911154,
-0.05036522075533867,
-0.009778974577784538,
-0.037832263857126236,
0.016232164576649666,
-0.017585817724466324,
-0.02112165279686451,
-0.05760026350617409,
0.04835807904601097,
0.047844626009464264,
-0.015193586237728596,
0.054426178336143494,
-0.024762511253356934,
-0.0008649958181194961,
0.03878915682435036,
-0.07580456137657166,
-0.03904588147997856,
-0.01744578406214714,
-0.003378297435119748,
0.010998429730534554,
0.034028030931949615,
-0.023327171802520752,
-0.008757900446653366,
0.017002345994114876,
-0.03328118845820427,
0.010770875960588455,
0.016395537182688713,
0.025649387389421463,
0.06478862464427948,
-0.046841055154800415,
-0.05521969869732857,
0.01606879197061062,
0.0443904772400856,
-0.028403371572494507,
0.06357500702142715,
-0.022440295666456223,
-0.021565090864896774,
0.0009656446054577827,
0.0026795908343046904,
0.005411693826317787,
-0.0256260484457016,
-0.007906032726168633,
0.008682048879563808,
-0.04009613022208214,
0.03255768492817879,
0.04000277444720268,
-0.0001412182318745181,
-0.002266785129904747,
-0.028683437034487724,
-0.11436032503843307,
0.006534875836223364,
0.05802036076784134,
-0.003314115572720766,
0.00979064404964447,
0.004556908737868071,
-0.06170789897441864,
0.08149923384189606,
-0.019791338592767715,
-0.0015403635334223509,
0.01267299149185419,
0.06343497335910797,
0.06842948496341705,
0.05848713964223862,
-0.06436852365732193,
-0.0006957892328500748,
-0.049384988844394684,
-0.012451272457838058,
0.014458412304520607,
0.04616422951221466,
0.038649123162031174,
-0.03143741935491562,
0.009510577656328678,
-0.02527596615254879,
0.028333354741334915
]
|
32,032 | pingouin.pairwise | pairwise_tests | Pairwise tests.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a
Pandas method, in which case this argument is no longer needed.
dv : string
Name of column containing the dependent variable.
between : string or list with 2 elements
Name of column(s) containing the between-subject factor(s).
within : string or list with 2 elements
Name of column(s) containing the within-subject factor(s), i.e. the
repeated measurements.
subject : string
Name of column containing the subject identifier. This is mandatory
when ``within`` is specified.
parametric : boolean
If True (default), use the parametric :py:func:`ttest` function.
If False, use :py:func:`pingouin.wilcoxon` or :py:func:`pingouin.mwu`
for paired or unpaired samples, respectively.
marginal : boolean
If True (default), the between-subject pairwise T-test(s) will be calculated
after averaging across all levels of the within-subject factor in mixed
design. This is recommended to avoid violating the assumption of
independence and conflating the degrees of freedom by the
number of repeated measurements.
.. versionadded:: 0.3.2
alpha : float
Significance level
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of
"two-sided" (default), "greater" or "less". Both "greater" and "less" return one-sided
p-values. "greater" tests against the alternative hypothesis that the mean of ``x``
is greater than the mean of ``y``.
padjust : string
Method used for testing and adjustment of pvalues.
* ``'none'``: no correction
* ``'bonf'``: one-step Bonferroni correction
* ``'sidak'``: one-step Sidak correction
* ``'holm'``: step-down method using Bonferroni adjustments
* ``'fdr_bh'``: Benjamini/Hochberg FDR correction
* ``'fdr_by'``: Benjamini/Yekutieli FDR correction
effsize : string or None
Effect size type. Available methods are:
* ``'none'``: no effect size
* ``'cohen'``: Unbiased Cohen d
* ``'hedges'``: Hedges g
* ``'r'``: Pearson correlation coefficient
* ``'eta-square'``: Eta-square
* ``'odds-ratio'``: Odds ratio
* ``'AUC'``: Area Under the Curve
* ``'CLES'``: Common Language Effect Size
correction : string or boolean
For independent two sample T-tests, specify whether or not to correct for
unequal variances using Welch separate variances T-test. If `'auto'`,
it will automatically uses Welch T-test when the sample sizes are
unequal, as recommended by Zimmerman 2004.
.. versionadded:: 0.3.2
nan_policy : string
Can be `'listwise'` for listwise deletion of missing values in repeated
measures design (= complete-case analysis) or `'pairwise'` for the
more liberal pairwise deletion (= available-case analysis). The former (default) is more
appropriate for post-hoc analysis following an ANOVA, however it can drastically reduce
the power of the test: any subject with one or more missing value(s) will be
completely removed from the analysis.
.. versionadded:: 0.2.9
return_desc : boolean
If True, append group means and std to the output dataframe
interaction : boolean
If there are multiple factors and ``interaction`` is True (default),
Pingouin will also calculate T-tests for the interaction term (see Notes).
.. versionadded:: 0.2.9
within_first : boolean
Determines the order of the interaction in mixed design. Pingouin will
return within * between when this parameter is set to True (default),
and between * within otherwise.
.. versionadded:: 0.3.6
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'Contrast'``: Contrast (= independent variable or interaction)
* ``'A'``: Name of first measurement
* ``'B'``: Name of second measurement
* ``'Paired'``: indicates whether the two measurements are paired or
independent
* ``'Parametric'``: indicates if (non)-parametric tests were used
* ``'T'``: T statistic (only if parametric=True)
* ``'U-val'``: Mann-Whitney U stat (if parametric=False and unpaired
data)
* ``'W-val'``: Wilcoxon W stat (if parametric=False and paired data)
* ``'dof'``: degrees of freedom (only if parametric=True)
* ``'alternative'``: tail of the test
* ``'p-unc'``: Uncorrected p-values
* ``'p-corr'``: Corrected p-values
* ``'p-adjust'``: p-values correction method
* ``'BF10'``: Bayes Factor
* ``'hedges'``: effect size (or any effect size defined in
``effsize``)
See also
--------
ttest, mwu, wilcoxon, compute_effsize, multicomp
Notes
-----
Data are expected to be in long-format. If your data is in wide-format,
you can use the :py:func:`pandas.melt` function to convert from wide to
long format.
If ``between`` or ``within`` is a list (e.g. ['col1', 'col2']),
the function returns 1) the pairwise T-tests between each values of the
first column, 2) the pairwise T-tests between each values of the second
column and 3) the interaction between col1 and col2. The interaction is
dependent of the order of the list, so ['col1', 'col2'] will not yield the
same results as ['col2', 'col1']. Furthermore, the interaction will only be
calculated if ``interaction=True``.
If ``between`` is a list with two elements, the output
model is between1 + between2 + between1 * between2.
Similarly, if ``within`` is a list with two elements, the output model is
within1 + within2 + within1 * within2.
If both ``between`` and ``within`` are specified, the output model is
within + between + within * between (= mixed design), unless
``within_first=False`` in which case the model becomes between + within +
between * within.
Missing values in repeated measurements are automatically removed using a
listwise (default) or pairwise deletion strategy. The former is more conservative, as any
subject with one or more missing value(s) will be completely removed from the dataframe prior
to calculating the T-tests. The ``nan_policy`` parameter can therefore have a huge impact
on the results.
Examples
--------
For more examples, please refer to the `Jupyter notebooks
<https://github.com/raphaelvallat/pingouin/blob/master/notebooks/01_ANOVA.ipynb>`_
1. One between-subject factor
>>> import pandas as pd
>>> import pingouin as pg
>>> pd.set_option('display.expand_frame_repr', False)
>>> pd.set_option('display.max_columns', 20)
>>> df = pg.read_dataset('mixed_anova.csv')
>>> pg.pairwise_tests(dv='Scores', between='Group', data=df).round(3)
Contrast A B Paired Parametric T dof alternative p-unc BF10 hedges
0 Group Control Meditation False True -2.29 178.0 two-sided 0.023 1.813 -0.34
2. One within-subject factor
>>> post_hocs = pg.pairwise_tests(dv='Scores', within='Time', subject='Subject', data=df)
>>> post_hocs.round(3)
Contrast A B Paired Parametric T dof alternative p-unc BF10 hedges
0 Time August January True True -1.740 59.0 two-sided 0.087 0.582 -0.328
1 Time August June True True -2.743 59.0 two-sided 0.008 4.232 -0.483
2 Time January June True True -1.024 59.0 two-sided 0.310 0.232 -0.170
3. Non-parametric pairwise paired test (wilcoxon)
>>> pg.pairwise_tests(dv='Scores', within='Time', subject='Subject',
... data=df, parametric=False).round(3)
Contrast A B Paired Parametric W-val alternative p-unc hedges
0 Time August January True False 716.0 two-sided 0.144 -0.328
1 Time August June True False 564.0 two-sided 0.010 -0.483
2 Time January June True False 887.0 two-sided 0.840 -0.170
4. Mixed design (within and between) with bonferroni-corrected p-values
>>> posthocs = pg.pairwise_tests(dv='Scores', within='Time', subject='Subject',
... between='Group', padjust='bonf', data=df)
>>> posthocs.round(3)
Contrast Time A B Paired Parametric T dof alternative p-unc p-corr p-adjust BF10 hedges
0 Time - August January True True -1.740 59.0 two-sided 0.087 0.261 bonf 0.582 -0.328
1 Time - August June True True -2.743 59.0 two-sided 0.008 0.024 bonf 4.232 -0.483
2 Time - January June True True -1.024 59.0 two-sided 0.310 0.931 bonf 0.232 -0.170
3 Group - Control Meditation False True -2.248 58.0 two-sided 0.028 NaN NaN 2.096 -0.573
4 Time * Group August Control Meditation False True 0.316 58.0 two-sided 0.753 1.000 bonf 0.274 0.081
5 Time * Group January Control Meditation False True -1.434 58.0 two-sided 0.157 0.471 bonf 0.619 -0.365
6 Time * Group June Control Meditation False True -2.744 58.0 two-sided 0.008 0.024 bonf 5.593 -0.699
5. Two between-subject factors. The order of the ``between`` factors matters!
>>> pg.pairwise_tests(dv='Scores', between=['Group', 'Time'], data=df).round(3)
Contrast Group A B Paired Parametric T dof alternative p-unc BF10 hedges
0 Group - Control Meditation False True -2.290 178.0 two-sided 0.023 1.813 -0.340
1 Time - August January False True -1.806 118.0 two-sided 0.074 0.839 -0.328
2 Time - August June False True -2.660 118.0 two-sided 0.009 4.499 -0.483
3 Time - January June False True -0.934 118.0 two-sided 0.352 0.288 -0.170
4 Group * Time Control August January False True -0.383 58.0 two-sided 0.703 0.279 -0.098
5 Group * Time Control August June False True -0.292 58.0 two-sided 0.771 0.272 -0.074
6 Group * Time Control January June False True 0.045 58.0 two-sided 0.964 0.263 0.011
7 Group * Time Meditation August January False True -2.188 58.0 two-sided 0.033 1.884 -0.558
8 Group * Time Meditation August June False True -4.040 58.0 two-sided 0.000 148.302 -1.030
9 Group * Time Meditation January June False True -1.442 58.0 two-sided 0.155 0.625 -0.367
6. Same but without the interaction, and using a directional test
>>> df.pairwise_tests(dv='Scores', between=['Group', 'Time'], alternative="less",
... interaction=False).round(3)
Contrast A B Paired Parametric T dof alternative p-unc BF10 hedges
0 Group Control Meditation False True -2.290 178.0 less 0.012 3.626 -0.340
1 Time August January False True -1.806 118.0 less 0.037 1.679 -0.328
2 Time August June False True -2.660 118.0 less 0.004 8.998 -0.483
3 Time January June False True -0.934 118.0 less 0.176 0.577 -0.170
| @pf.register_dataframe_method
def pairwise_tests(
data=None,
dv=None,
between=None,
within=None,
subject=None,
parametric=True,
marginal=True,
alpha=0.05,
alternative="two-sided",
padjust="none",
effsize="hedges",
correction="auto",
nan_policy="listwise",
return_desc=False,
interaction=True,
within_first=True,
):
"""Pairwise tests.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a
Pandas method, in which case this argument is no longer needed.
dv : string
Name of column containing the dependent variable.
between : string or list with 2 elements
Name of column(s) containing the between-subject factor(s).
within : string or list with 2 elements
Name of column(s) containing the within-subject factor(s), i.e. the
repeated measurements.
subject : string
Name of column containing the subject identifier. This is mandatory
when ``within`` is specified.
parametric : boolean
If True (default), use the parametric :py:func:`ttest` function.
If False, use :py:func:`pingouin.wilcoxon` or :py:func:`pingouin.mwu`
for paired or unpaired samples, respectively.
marginal : boolean
If True (default), the between-subject pairwise T-test(s) will be calculated
after averaging across all levels of the within-subject factor in mixed
design. This is recommended to avoid violating the assumption of
independence and conflating the degrees of freedom by the
number of repeated measurements.
.. versionadded:: 0.3.2
alpha : float
Significance level
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of
"two-sided" (default), "greater" or "less". Both "greater" and "less" return one-sided
p-values. "greater" tests against the alternative hypothesis that the mean of ``x``
is greater than the mean of ``y``.
padjust : string
Method used for testing and adjustment of pvalues.
* ``'none'``: no correction
* ``'bonf'``: one-step Bonferroni correction
* ``'sidak'``: one-step Sidak correction
* ``'holm'``: step-down method using Bonferroni adjustments
* ``'fdr_bh'``: Benjamini/Hochberg FDR correction
* ``'fdr_by'``: Benjamini/Yekutieli FDR correction
effsize : string or None
Effect size type. Available methods are:
* ``'none'``: no effect size
* ``'cohen'``: Unbiased Cohen d
* ``'hedges'``: Hedges g
* ``'r'``: Pearson correlation coefficient
* ``'eta-square'``: Eta-square
* ``'odds-ratio'``: Odds ratio
* ``'AUC'``: Area Under the Curve
* ``'CLES'``: Common Language Effect Size
correction : string or boolean
For independent two sample T-tests, specify whether or not to correct for
unequal variances using Welch separate variances T-test. If `'auto'`,
it will automatically uses Welch T-test when the sample sizes are
unequal, as recommended by Zimmerman 2004.
.. versionadded:: 0.3.2
nan_policy : string
Can be `'listwise'` for listwise deletion of missing values in repeated
measures design (= complete-case analysis) or `'pairwise'` for the
more liberal pairwise deletion (= available-case analysis). The former (default) is more
appropriate for post-hoc analysis following an ANOVA, however it can drastically reduce
the power of the test: any subject with one or more missing value(s) will be
completely removed from the analysis.
.. versionadded:: 0.2.9
return_desc : boolean
If True, append group means and std to the output dataframe
interaction : boolean
If there are multiple factors and ``interaction`` is True (default),
Pingouin will also calculate T-tests for the interaction term (see Notes).
.. versionadded:: 0.2.9
within_first : boolean
Determines the order of the interaction in mixed design. Pingouin will
return within * between when this parameter is set to True (default),
and between * within otherwise.
.. versionadded:: 0.3.6
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'Contrast'``: Contrast (= independent variable or interaction)
* ``'A'``: Name of first measurement
* ``'B'``: Name of second measurement
* ``'Paired'``: indicates whether the two measurements are paired or
independent
* ``'Parametric'``: indicates if (non)-parametric tests were used
* ``'T'``: T statistic (only if parametric=True)
* ``'U-val'``: Mann-Whitney U stat (if parametric=False and unpaired
data)
* ``'W-val'``: Wilcoxon W stat (if parametric=False and paired data)
* ``'dof'``: degrees of freedom (only if parametric=True)
* ``'alternative'``: tail of the test
* ``'p-unc'``: Uncorrected p-values
* ``'p-corr'``: Corrected p-values
* ``'p-adjust'``: p-values correction method
* ``'BF10'``: Bayes Factor
* ``'hedges'``: effect size (or any effect size defined in
``effsize``)
See also
--------
ttest, mwu, wilcoxon, compute_effsize, multicomp
Notes
-----
Data are expected to be in long-format. If your data is in wide-format,
you can use the :py:func:`pandas.melt` function to convert from wide to
long format.
If ``between`` or ``within`` is a list (e.g. ['col1', 'col2']),
the function returns 1) the pairwise T-tests between each values of the
first column, 2) the pairwise T-tests between each values of the second
column and 3) the interaction between col1 and col2. The interaction is
dependent of the order of the list, so ['col1', 'col2'] will not yield the
same results as ['col2', 'col1']. Furthermore, the interaction will only be
calculated if ``interaction=True``.
If ``between`` is a list with two elements, the output
model is between1 + between2 + between1 * between2.
Similarly, if ``within`` is a list with two elements, the output model is
within1 + within2 + within1 * within2.
If both ``between`` and ``within`` are specified, the output model is
within + between + within * between (= mixed design), unless
``within_first=False`` in which case the model becomes between + within +
between * within.
Missing values in repeated measurements are automatically removed using a
listwise (default) or pairwise deletion strategy. The former is more conservative, as any
subject with one or more missing value(s) will be completely removed from the dataframe prior
to calculating the T-tests. The ``nan_policy`` parameter can therefore have a huge impact
on the results.
Examples
--------
For more examples, please refer to the `Jupyter notebooks
<https://github.com/raphaelvallat/pingouin/blob/master/notebooks/01_ANOVA.ipynb>`_
1. One between-subject factor
>>> import pandas as pd
>>> import pingouin as pg
>>> pd.set_option('display.expand_frame_repr', False)
>>> pd.set_option('display.max_columns', 20)
>>> df = pg.read_dataset('mixed_anova.csv')
>>> pg.pairwise_tests(dv='Scores', between='Group', data=df).round(3)
Contrast A B Paired Parametric T dof alternative p-unc BF10 hedges
0 Group Control Meditation False True -2.29 178.0 two-sided 0.023 1.813 -0.34
2. One within-subject factor
>>> post_hocs = pg.pairwise_tests(dv='Scores', within='Time', subject='Subject', data=df)
>>> post_hocs.round(3)
Contrast A B Paired Parametric T dof alternative p-unc BF10 hedges
0 Time August January True True -1.740 59.0 two-sided 0.087 0.582 -0.328
1 Time August June True True -2.743 59.0 two-sided 0.008 4.232 -0.483
2 Time | (data=None, dv=None, between=None, within=None, subject=None, parametric=True, marginal=True, alpha=0.05, alternative='two-sided', padjust='none', effsize='hedges', correction='auto', nan_policy='listwise', return_desc=False, interaction=True, within_first=True) | [
0.018556106835603714,
0.016230976209044456,
0.05283772572875023,
-0.02282446064054966,
0.021274374797940254,
-0.05166954547166824,
-0.011058405973017216,
-0.045536596328020096,
0.022566111758351326,
0.01815173588693142,
-0.03578677773475647,
0.03430408611893654,
0.04102112725377083,
0.02630653791129589,
-0.05688143149018288,
0.017736133188009262,
0.012647806666791439,
0.003322014817968011,
0.04951290413737297,
0.006941691040992737,
-0.011086487211287022,
0.00809863954782486,
-0.0336301364004612,
0.026486258953809738,
-0.009637493640184402,
0.016219744458794594,
-0.05562338978052139,
-0.08846724778413773,
0.038954343646764755,
0.03940364345908165,
0.004931071773171425,
-0.0450872965157032,
-0.07211271673440933,
0.017769830301404,
-0.0036814550403505564,
-0.04722147062420845,
-0.02596956305205822,
-0.019230056554079056,
-0.02191462740302086,
0.06950677186250687,
0.0225885771214962,
-0.057824961841106415,
0.03675277158617973,
-0.03288878872990608,
-0.025744913145899773,
0.012557946145534515,
-0.0003987541131209582,
0.04151535779237747,
0.006138566881418228,
-0.06649646162986755,
0.03322576358914375,
-0.02605942264199257,
0.027991414070129395,
0.05337688699364662,
-0.02115081623196602,
0.07121410965919495,
-0.020802607759833336,
0.03637086600065231,
0.052298568189144135,
-0.034236691892147064,
0.020600423216819763,
0.041964657604694366,
-0.004512660671025515,
0.02087000384926796,
-0.02639639936387539,
-0.061823733150959015,
0.008003163151443005,
-0.004464922938495874,
-0.02873275987803936,
-0.04573877900838852,
-0.029316851869225502,
0.0028699063695967197,
0.008435615338385105,
0.0432676300406456,
-0.019128965213894844,
0.004288010764867067,
-0.013827219605445862,
-0.06195852532982826,
0.008901763707399368,
-0.002014831406995654,
-0.001041815266944468,
0.03255181387066841,
-0.021409163251519203,
0.01114826649427414,
0.003069283440709114,
-0.037336863577365875,
0.016657812520861626,
0.006795668508857489,
0.082716204226017,
-0.004372254479676485,
-0.013759824447333813,
-0.02821606583893299,
0.05261307582259178,
-0.05032164603471756,
0.0035831707064062357,
-0.002737924223765731,
-0.009923922829329967,
0.012355760671198368,
-0.048389654606580734,
-0.0037909720558673143,
0.0030103125609457493,
0.02639639936387539,
0.03520268574357033,
0.07319103181362152,
0.010373222641646862,
0.002357423072680831,
-0.06047583371400833,
0.01878075674176216,
-0.027339929714798927,
-0.001347901183180511,
-0.07674051076173782,
0.008267126977443695,
-0.01787092350423336,
-0.04504236578941345,
0.0454467348754406,
-0.048479512333869934,
-0.0166802778840065,
0.024531802162528038,
-0.08891654759645462,
-0.03893188014626503,
0.06155415624380112,
0.05360153689980507,
-0.016837531700730324,
-0.04279586300253868,
-0.007559479214251041,
-0.04160521551966667,
0.02220667153596878,
0.00016067754768300802,
-0.04569385200738907,
0.020173588767647743,
0.011996320448815823,
-0.0030636670999228954,
0.0063351355493068695,
0.06676603853702545,
-0.02176860347390175,
0.03816806897521019,
0.07364033907651901,
0.01069896575063467,
0.044435810297727585,
-0.044053904712200165,
0.0469069629907608,
0.02095986343920231,
-0.028171135112643242,
-0.00027414344367571175,
0.04075154662132263,
0.0010713005904108286,
-0.015141423791646957,
-0.005913916509598494,
0.009513936005532742,
0.03902173787355423,
-0.02215050905942917,
-0.053107306361198425,
-0.00032135509536601603,
-0.05679157003760338,
0.06514855474233627,
-0.023431016132235527,
0.03648319095373154,
-0.029226990416646004,
-0.013894614763557911,
-0.05674663931131363,
-0.013276826590299606,
-0.040055129677057266,
-0.00053916044998914,
0.06303684413433075,
0.0431777685880661,
0.01415296271443367,
-0.016466859728097916,
-0.002174894791096449,
-0.0041476041078567505,
-0.0662718117237091,
0.005327017977833748,
0.02583477273583412,
-0.011872762814164162,
-0.005273663438856602,
-0.03374246135354042,
0.009850910864770412,
-0.00319845718331635,
-0.024913707748055458,
0.024711521342396736,
-0.08473805338144302,
-0.012681503780186176,
-0.014355148188769817,
-0.05400590971112251,
0.018601035699248314,
-0.05207391455769539,
0.0103844553232193,
0.01696109026670456,
-0.026239143684506416,
-0.02911466546356678,
0.003060858929529786,
-0.035337477922439575,
-0.0630817785859108,
-0.01991523988544941,
0.06114978343248367,
0.044772785156965256,
-0.01610741950571537,
0.005239965859800577,
0.008121104910969734,
0.06523841619491577,
0.0030636670999228954,
0.0010474316077306867,
-0.00902532134205103,
0.018758291378617287,
0.009800365194678307,
0.005113600287586451,
0.0018603844800963998,
-0.03551719710230827,
-0.000545127724763006,
-0.041200846433639526,
-0.04650259017944336,
0.01991523988544941,
-0.04423362389206886,
0.027384858578443527,
0.0511753149330616,
0.01455733273178339,
-0.02234146185219288,
0.05270293727517128,
-0.0391789935529232,
0.015096493065357208,
0.005304552614688873,
0.03668537735939026,
-0.04268353804945946,
-0.03664044663310051,
0.048434581607580185,
0.08981514722108841,
0.041582752019166946,
0.04928825423121452,
0.05733073130249977,
0.024127431213855743,
-0.02435208112001419,
0.018848150968551636,
0.010390072129666805,
0.01155825238674879,
-0.04140303283929825,
-0.05095066502690315,
-0.011693042702972889,
-0.044188693165779114,
-0.031001728028059006,
-0.03960582986474037,
-0.011052790097892284,
-0.004363830201327801,
0.026329003274440765,
0.02516082301735878,
0.023363620042800903,
0.0021987638901919127,
-0.0908934697508812,
0.023386085405945778,
0.005397221073508263,
0.019308684393763542,
-0.016500556841492653,
0.03783109411597252,
-0.047625843435525894,
0.005411261692643166,
0.0005226627108640969,
-0.03340548649430275,
-0.03001326695084572,
0.03243948891758919,
0.022026952356100082,
0.04740119352936745,
-0.03531501069664955,
0.026935558766126633,
-0.03035024181008339,
-0.02763197384774685,
0.02397017553448677,
-0.033001113682985306,
-0.011283055879175663,
-0.041672613471746445,
-0.00030433080974034965,
0.013681197538971901,
-0.0010298807173967361,
-0.071079321205616,
-0.03706728294491768,
-0.03165321424603462,
0.010743895545601845,
-0.03102419339120388,
0.0431777685880661,
0.017882155254483223,
-0.03329315781593323,
-0.012625341303646564,
-0.0449974350631237,
-0.019836612045764923,
-0.012108645401895046,
-0.008974775671958923,
-0.02435208112001419,
0.004001581575721502,
-0.01232206355780363,
-0.03129377216100693,
-0.030552426353096962,
0.04942304268479347,
-0.0074359215795993805,
-0.04892881214618683,
-0.05432041734457016,
0.021802302449941635,
-0.008317673578858376,
0.0004759776056744158,
0.03212497755885124,
-0.01422035787254572,
-0.04803021252155304,
0.020723981782794,
-0.012703969143331051,
-0.011839065700769424,
-0.02286938950419426,
0.03275400027632713,
0.052343495190143585,
-0.05822933092713356,
0.02745225466787815,
0.020667817443609238,
-0.04178493842482567,
0.014400077983736992,
-0.05485957860946655,
0.03360766917467117,
0.07548246532678604,
-0.027047883719205856,
0.03569691628217697,
0.031428564339876175,
-0.02153272181749344,
-0.03005819581449032,
-0.0275421142578125,
0.03407943621277809,
0.03549472987651825,
-0.043335024267435074,
-0.0336301364004612,
0.038100674748420715,
-0.004066168796271086,
0.06595730036497116,
0.0021187320817261934,
0.029856011271476746,
-0.027766764163970947,
0.010109258815646172,
0.017095880582928658,
-0.044390879571437836,
-0.013512709178030491,
0.05665678158402443,
0.011996320448815823,
-0.02677830308675766,
0.0332706943154335,
-0.02677830308675766,
-0.0026719332672655582,
0.04407636821269989,
0.022038184106349945,
0.03756151348352432,
-0.01987031102180481,
-0.0001657672692090273,
-0.056971289217472076,
0.03219237178564072,
-0.043424881994724274,
0.004397527780383825,
0.059307653456926346,
0.05193912610411644,
-0.02035330794751644,
0.015478398650884628,
0.06559785455465317,
0.03724700212478638,
0.05503929778933525,
0.05009699612855911,
0.023273760452866554,
-0.009356681257486343,
0.020611654967069626,
0.0410885214805603,
-0.005551667883992195,
0.02720513939857483,
-0.001173797296360135,
0.035764310508966446,
-0.0024739603977650404,
0.009356681257486343,
-0.027519648894667625,
-0.005484273191541433,
0.01834268867969513,
-0.038572438061237335,
-0.018219131976366043,
-0.0030075046233832836,
-0.06487897783517838,
0.023318691179156303,
-0.013063409365713596,
0.04794035106897354,
-0.007711118087172508,
-0.018073108047246933,
-0.010783209465444088,
0.02001633308827877,
0.008727660402655602,
0.04313283786177635,
-0.01251301635056734,
-0.016230976209044456,
0.044098835438489914,
-0.0127938287332654,
-0.03205758333206177,
0.024127431213855743,
0.01191769354045391,
0.012164807878434658,
-0.0336301364004612,
0.00638568215072155,
-0.012378226034343243,
0.014759518206119537,
0.020364539697766304,
-0.0016652195481583476,
0.022386392578482628,
-0.06240782514214516,
-0.0023321497719734907,
-0.031001728028059006,
-0.0014131901552900672,
0.016882462427020073,
-0.01782599277794361,
0.023228829726576805,
-0.012849991209805012,
-0.03115898184478283,
-0.0007827655645087361,
0.01748901791870594,
-0.021521488204598427,
-0.018702128902077675,
0.026216678321361542,
-0.04182986542582512,
0.04468292370438576,
-0.010873069986701012,
-0.004397527780383825,
-0.0076381065882742405,
0.04531194642186165,
-0.0205891914665699,
0.040661685168743134,
0.029002340510487556,
0.027609510347247124,
0.10477685183286667,
-0.07615641504526138,
-0.007070865016430616,
0.042863257229328156,
0.06878788769245148,
-0.023431016132235527,
-0.028957409784197807,
0.0014981359709054232,
-0.02230776473879814,
0.012108645401895046,
0.00548146478831768,
-0.0027266917750239372,
-0.046053290367126465,
-0.0008845601696521044,
0.046053290367126465,
0.013782289810478687,
-0.09983454644680023,
0.02677830308675766,
0.041290707886219025,
0.020274680107831955,
-0.037673838436603546,
0.023790456354618073,
0.007525781635195017,
-0.027766764163970947,
-0.035000499337911606,
0.000028103213480790146,
0.027609510347247124,
-0.05328702554106712,
-0.0903543084859848,
-0.040571827441453934,
0.07476358860731125,
0.03902173787355423,
0.03369753062725067,
0.05288265645503998,
-0.07494330406188965,
0.006363216787576675,
0.023363620042800903,
-0.03630347177386284,
-0.06730519980192184,
0.018949244171380997,
-0.006655262317508459,
-0.01624220982193947,
-0.06896761059761047,
0.006436228286474943,
-0.009575714357197285,
0.033944644033908844,
-0.008368220180273056,
-0.028193600475788116,
-0.0316307470202446,
0.01663534715771675,
-0.03239455819129944,
-0.01653425395488739,
-0.031181447207927704,
0.014804448001086712,
0.044772785156965256,
0.03697742149233818,
-0.048434581607580185,
-0.038190532475709915,
-0.030529962852597237,
0.002572244731709361,
0.029519036412239075,
-0.00919380970299244,
0.08294085413217545,
0.01088991854339838,
0.017792295664548874,
-0.037381794303655624,
-0.005492697469890118,
0.007621258031576872,
-0.002934493124485016,
-0.05764524266123772,
0.007497700396925211,
0.012108645401895046,
0.015040330588817596,
0.07512302696704865,
-0.071079321205616,
0.01953333429992199,
0.03158581629395485,
-0.04115591570734978,
0.026171747595071793,
-0.03349534422159195,
0.08060449361801147,
0.0033416717778891325,
-0.01029459573328495,
-0.026845699176192284,
0.0708097442984581,
-0.00881751999258995,
-0.00795823335647583,
-0.00309736467897892,
-0.038617368787527084,
-0.015298678539693356,
-0.0014700547326356173,
-0.041268240660429,
0.031046656891703606,
0.011591950431466103,
0.04856937378644943,
-0.026868164539337158,
0.024711521342396736,
-0.024037571623921394,
0.016882462427020073,
-0.014714588411152363,
0.015096493065357208,
-0.06896761059761047,
-0.0026705292984843254,
0.04284079372882843,
0.022846926003694534,
0.03340548649430275,
-0.005885835271328688,
0.05355660617351532,
0.009210658259689808,
0.0015809758333489299,
-0.006177880335599184,
-0.004495812114328146,
0.02367813140153885,
0.044188693165779114,
-0.0029036037158221006,
-0.003206881694495678,
-0.04569385200738907,
-0.03306850790977478,
0.05485957860946655,
0.006110485643148422,
0.029990801587700844,
-0.013355454429984093,
-0.009727353230118752,
-0.04001019895076752,
0.033001113682985306,
-0.010687733069062233,
-0.020858770236372948,
-0.01948840543627739,
0.0037179607897996902,
0.011580717749893665,
0.029384246096014977,
-0.042054519057273865,
0.04272846877574921,
0.027991414070129395,
-0.029856011271476746,
0.014197892509400845,
0.035292547196149826,
0.022318996489048004,
0.020083727315068245,
-0.007868372835218906,
-0.032147444784641266,
-0.07539260387420654,
0.05328702554106712,
-0.0662718117237091,
0.03044010140001774,
0.027654439210891724,
0.05364646762609482,
0.03284385800361633,
-0.0908036082983017,
-0.05688143149018288,
-0.0026789535768330097,
0.03893188014626503,
-0.025992028415203094,
-0.011614414863288403,
-0.039044205099344254,
-0.008255895227193832,
-0.02191462740302086,
0.007873989641666412,
-0.02626160904765129,
-0.013299291953444481,
-0.04785049334168434,
-0.0166802778840065,
0.03940364345908165,
-0.03383231908082962,
-0.028530575335025787,
0.00945777352899313,
-0.029900941997766495,
0.026216678321361542,
0.011872762814164162,
-0.013209431432187557,
-0.10019399225711823,
-0.04079647734761238,
-0.03039517253637314,
-0.03720207139849663,
0.015579490922391415,
0.06703562289476395,
-0.017747364938259125,
0.004170069471001625,
0.07736952602863312,
0.005355099216103554,
0.0005588173517026007,
0.03902173787355423,
-0.0012215354945510626,
-0.03187786415219307,
0.018095573410391808,
-0.010586640797555447,
0.0275421142578125,
0.017713667824864388,
0.0010713005904108286,
-0.02477891743183136,
0.04340241849422455,
0.04803021252155304,
0.036056358367204666,
-0.055488597601652145,
0.0863555371761322,
-0.027182674035429955,
-0.06568771600723267,
-0.01076636090874672,
0.036056358367204666,
-0.04355967417359352,
-0.005913916509598494,
0.04075154662132263,
-0.01919635944068432,
0.06339628994464874,
-0.00862656719982624,
0.0158153735101223,
0.009901457466185093,
-0.05252321809530258,
-0.030911866575479507,
-0.08981514722108841,
-0.0005138873239047825,
0.02176860347390175,
0.04337995499372482,
-0.017927085980772972,
0.016455627977848053,
-0.026531187817454338,
0.04187479615211487,
-0.008115488104522228,
0.009115181863307953,
0.02206064946949482,
-0.02158888429403305,
-0.03650565817952156,
0.06411516666412354,
0.04475031793117523,
0.0017943935235962272,
-0.006891144905239344,
-0.01019350253045559,
-0.05005206540226936,
0.006997853517532349,
0.029137130826711655,
0.032911255955696106,
0.008463696576654911,
-0.029316851869225502,
-0.03589910268783569,
0.0035691300872713327,
-0.005565708503127098,
0.03230470046401024,
0.02868783101439476,
0.027092814445495605,
0.01782599277794361,
-0.011973856016993523,
-0.003184416564181447,
-0.008710811845958233,
0.023947712033987045,
0.09525168687105179,
0.024981101974844933,
0.039381179958581924,
0.05023178458213806,
0.016511790454387665,
0.0334504134953022,
0.027519648894667625,
0.08640046417713165,
-0.0474461205303669,
0.03475338593125343,
0.05436534807085991,
-0.041335634887218475,
0.0008178671123459935,
-0.019567033275961876,
-0.05840905010700226,
-0.03751658275723457,
0.02430715225636959,
0.07224750518798828,
-0.010597873479127884,
-0.05454506725072861,
0.01143469475209713,
-0.029047271236777306,
0.05247828736901283,
-0.0391789935529232,
-0.05131010711193085,
-0.09929538518190384,
-0.049827415496110916,
-0.047625843435525894,
0.008199731819331646,
0.0056359120644629,
-0.022476252168416977,
-0.02191462740302086,
-0.027272533625364304,
-0.0097722839564085,
0.020690282806754112,
-0.031473491340875626,
-0.02711527980864048,
-0.03174307197332382,
0.019567033275961876,
0.050007134675979614,
0.03522515296936035,
0.07777389883995056,
0.0037713153287768364,
-0.023183900862932205,
0.07754924893379211,
-0.12679257988929749,
-0.040908802300691605,
0.029743686318397522,
0.0016624114941805601,
0.021982021629810333,
0.01194015797227621,
0.01948840543627739,
-0.0035607055760920048,
0.028755225241184235,
0.012052482925355434,
-0.009923922829329967,
0.03578677773475647,
0.0009035150287672877,
0.03068721666932106,
-0.019937705248594284,
-0.02220667153596878,
0.016848765313625336,
0.0078178271651268,
0.009294901974499226,
0.033472880721092224,
-0.035045430064201355,
0.031945258378982544,
0.0007553863106295466,
0.03592156618833542,
0.03324823081493378,
-0.024374546483159065,
-0.02329622581601143,
-0.0053185936994850636,
-0.027474720031023026,
0.03237209469079971,
0.04084140807390213,
-0.025947097688913345,
-0.01696109026670456,
0.014826913364231586,
-0.08087407052516937,
0.011445927433669567,
0.05113038420677185,
0.009081484749913216,
0.02430715225636959,
0.0470866821706295,
-0.09246601909399033,
0.04614315181970596,
-0.06209331378340721,
-0.03439394384622574,
-0.016500556841492653,
0.039763085544109344,
0.07341568171977997,
0.04149289056658745,
-0.046008359640836716,
-0.006469925865530968,
-0.05679157003760338,
-0.013737360015511513,
0.01853364147245884,
0.06451953947544098,
0.06977634876966476,
0.015658119693398476,
0.04749105125665665,
-0.013636266812682152,
0.0864453986287117
]
|
32,033 | pingouin.pairwise | pairwise_ttests | This function has been deprecated . Use :py:func:`pingouin.pairwise_tests` instead. | @pf.register_dataframe_method
def pairwise_ttests(*args, **kwargs):
"""This function has been deprecated . Use :py:func:`pingouin.pairwise_tests` instead."""
warnings.warn("pairwise_ttests is deprecated, use pairwise_tests instead.", UserWarning)
return pairwise_tests(*args, **kwargs)
| (*args, **kwargs) | [
-0.0285917017608881,
-0.05353919789195061,
0.0440029539167881,
0.006530623883008957,
-0.03521598502993584,
-0.03770222142338753,
-0.030550038442015648,
0.033138446509838104,
0.00899131502956152,
0.0025117783807218075,
-0.004776636138558388,
-0.0011707441881299019,
0.027689164504408836,
-0.00012405897723510861,
-0.025969235226511955,
-0.02179712802171707,
0.02779133804142475,
0.020792417228221893,
0.03163989260792732,
0.01572628691792488,
-0.031214168295264244,
0.014900380745530128,
-0.010447295382618904,
0.026377931237220764,
-0.02280183881521225,
0.08698416501283646,
-0.03742975741624832,
-0.07445081323385239,
0.05503774806857109,
0.02395981177687645,
-0.04209570214152336,
-0.019600385800004005,
-0.06273485720157623,
0.04189135506749153,
-0.0018870268249884248,
-0.03221888095140457,
-0.04591020196676254,
0.008016404695808887,
-0.06896747648715973,
0.04717034846544266,
0.01535164937376976,
-0.08371459692716599,
0.019072487950325012,
-0.03637395799160004,
-0.013078276999294758,
-0.0032653119415044785,
-0.049554407596588135,
-0.00011847133282572031,
0.0033866437152028084,
-0.037565987557172775,
0.03247431665658951,
-0.04080149903893471,
0.034466709941625595,
0.07792473584413528,
-0.019583357498049736,
0.09113924205303192,
0.02276778221130371,
0.0490775965154171,
0.03531815856695175,
0.03417721763253212,
0.007360788062214851,
0.028012715280056,
0.027280468493700027,
0.015283533371984959,
0.015300562605261803,
-0.05278991907835007,
-0.010404722765088081,
-0.0006689206347800791,
-0.028336266055703163,
0.00689674774184823,
-0.024010898545384407,
-0.0033738717902451754,
-0.0059005506336688995,
0.05943123251199722,
-0.022733723744750023,
-0.022086622193455696,
-0.029306920245289803,
-0.042572516947984695,
0.012456717900931835,
-0.008093035779893398,
-0.023057274520397186,
-0.010157802142202854,
-0.023414883762598038,
0.033104389905929565,
-0.031146053224802017,
-0.04148266091942787,
0.07622183114290237,
0.0059346086345613,
0.007986604236066341,
0.033138446509838104,
-0.03838337957859039,
-0.03359822928905487,
-0.0015038740821182728,
-0.0036591077223420143,
0.011290231719613075,
-0.015300562605261803,
-0.019072487950325012,
0.03685076907277107,
-0.0521087609231472,
-0.029800761491060257,
0.022052563726902008,
0.024998581036925316,
0.04785150662064552,
0.03685076907277107,
0.05425441637635231,
-0.04911165311932564,
-0.046625420451164246,
-0.031146053224802017,
-0.017420673742890358,
0.012218312360346317,
-0.06174717843532562,
0.02722938172519207,
-0.0020658313296735287,
-0.025151843205094337,
0.02549242228269577,
-0.04267469048500061,
0.038723960518836975,
-0.010294034145772457,
-0.05353919789195061,
-0.023908725008368492,
0.017625020816922188,
0.056876882910728455,
-0.004097604658454657,
-0.06406312435865402,
-0.0324232280254364,
0.003725095186382532,
0.049179770052433014,
0.031946416944265366,
-0.011613782495260239,
0.028830107301473618,
0.038144975900650024,
-0.0009381918353028595,
0.007892944850027561,
0.07261168211698532,
-0.0145853441208601,
0.003001362318173051,
0.12546971440315247,
0.034075040370225906,
0.04883918911218643,
-0.027144236490130424,
-0.014525742270052433,
0.025645684450864792,
-0.002275500912219286,
0.04015439748764038,
0.049179770052433014,
0.03514786809682846,
-0.0692058801651001,
0.05568484961986542,
0.013086791150271893,
0.03434750437736511,
0.030992791056632996,
-0.011596753261983395,
-0.006377363111823797,
-0.0303286612033844,
0.03926888853311539,
-0.019634444266557693,
0.04478628560900688,
-0.01572628691792488,
0.005185332614928484,
-0.0684906616806984,
0.010191860608756542,
-0.03630584105849266,
-0.03531815856695175,
0.04768121987581253,
0.007105352822691202,
0.0077056256122887135,
0.008437872864305973,
-0.0092637799680233,
-0.01053244061768055,
-0.007028722204267979,
0.007186240516602993,
0.010464324615895748,
-0.001118592917919159,
0.023414883762598038,
-0.003271697787567973,
0.013861611485481262,
0.023125391453504562,
0.003748510032892227,
0.02952829748392105,
-0.042197879403829575,
-0.01669694110751152,
0.0008275032741948962,
-0.06794573366641998,
-0.009791678749024868,
0.014074473641812801,
0.03109496645629406,
0.010081171989440918,
-0.02571379952132702,
-0.028642788529396057,
-0.006986150052398443,
-0.006773287430405617,
-0.0059175798669457436,
0.022921042516827583,
0.06389283388853073,
0.051495715975761414,
-0.052210934460163116,
-0.057489924132823944,
0.05616166442632675,
-0.006602997425943613,
0.027672136202454567,
0.011332803405821323,
0.03630584105849266,
0.014031901024281979,
0.0035633195657283068,
0.030464893206954002,
0.00767582468688488,
-0.03552250564098358,
0.03433047607541084,
-0.04727252200245857,
-0.055139921605587006,
0.0822160467505455,
-0.0386558435857296,
-0.002999233780428767,
0.0291706882417202,
-0.003869841806590557,
0.03109496645629406,
0.0567406490445137,
-0.006530623883008957,
-0.009868308901786804,
-0.005159788765013218,
0.08930011093616486,
0.001239924575202167,
-0.022665606811642647,
-0.0006529559614136815,
0.07996821403503418,
-0.004729806445538998,
0.05684282258152962,
-0.0016677783569321036,
0.010677186772227287,
-0.04996310546994209,
-0.005640858318656683,
-0.0006029332871548831,
-0.02532213181257248,
-0.01929386518895626,
-0.016262700781226158,
-0.03606743738055229,
-0.0291706882417202,
-0.01871487870812416,
-0.02702503278851509,
-0.009749106131494045,
-0.017812341451644897,
0.03572685644030571,
0.02007719874382019,
0.023806551471352577,
0.009229721501469612,
-0.08167111128568649,
0.026377931237220764,
0.00022177619393914938,
0.03012431226670742,
0.028302209451794624,
0.023874666541814804,
-0.07949139922857285,
0.0026011806912720203,
0.02375546470284462,
-0.02900039777159691,
-0.04553556442260742,
0.02339785546064377,
0.02842141129076481,
0.04505874961614609,
-0.016969405114650726,
-0.0081611517816782,
-0.038519613444805145,
-0.02009422704577446,
0.006015496328473091,
-0.044718172401189804,
-0.033104389905929565,
-0.01813589222729206,
0.024845320731401443,
0.0012484390754252672,
-0.0005592964589595795,
-0.022921042516827583,
-0.038553670048713684,
-0.05963557958602905,
0.030822502449154854,
-0.0004475435707718134,
-0.001385735347867012,
-0.013997843489050865,
-0.014329909346997738,
0.025645684450864792,
-0.061304423958063126,
0.04465005546808243,
-0.034296419471502304,
-0.014908894896507263,
-0.008880626410245895,
-0.03288301080465317,
-0.021541692316532135,
-0.00964693259447813,
0.009621388278901577,
0.04359425604343414,
-0.043968893587589264,
-0.051461655646562576,
-0.0155645115301013,
0.010694216005504131,
0.012669580988585949,
0.0002529073681216687,
0.05394789204001427,
-0.02261452004313469,
-0.046421073377132416,
0.02011125721037388,
-0.02045183628797531,
-0.036033377051353455,
-0.03916671499609947,
-0.007330987136811018,
0.0694783478975296,
-0.016015781089663506,
0.016722483560442924,
0.01168189849704504,
-0.0314866341650486,
-0.019038429483771324,
-0.05776238813996315,
0.0018157177837565541,
0.04751092940568924,
-0.014661974273622036,
-0.01856161653995514,
-0.001450658543035388,
-0.01630527339875698,
-0.05616166442632675,
0.013759437017142773,
0.03482431918382645,
0.02954532578587532,
-0.04853266850113869,
-0.013946756720542908,
0.003005619626492262,
0.0467616505920887,
0.037157293409109116,
0.05793267861008644,
0.027331555262207985,
-0.07220298796892166,
-0.012380087748169899,
0.004712777677923441,
-0.033274680376052856,
0.012907986529171467,
0.07206675410270691,
0.006117670796811581,
-0.04999716207385063,
0.029221775010228157,
-0.007927002385258675,
0.01091559324413538,
0.029085543006658554,
0.05541238561272621,
0.01914060302078724,
-0.0421297624707222,
-0.00819946639239788,
-0.027569960802793503,
0.028285179287195206,
-0.013980814255774021,
-0.04962252452969551,
0.05445876345038414,
0.07520009577274323,
-0.0006295410566963255,
0.049724698066711426,
0.01605835370719433,
-0.023687347769737244,
0.07806096225976944,
0.08419140428304672,
0.043355848640203476,
-0.029885906726121902,
0.031043879687786102,
0.0016028552781790495,
0.002667168155312538,
0.04093773290514946,
-0.05217687413096428,
0.03398989513516426,
-0.0030545780900865793,
0.04846455156803131,
-0.0020051654428243637,
-0.01438951026648283,
0.018255094066262245,
-0.05350513756275177,
-0.002518164226785302,
-0.04751092940568924,
-0.03610149398446083,
0.031946416944265366,
0.007820570841431618,
0.03203156217932701,
0.004602089058607817,
-0.010677186772227287,
0.01314639300107956,
-0.043560199439525604,
0.03250837326049805,
0.009221207350492477,
-0.0405290350317955,
0.019651472568511963,
0.011928819119930267,
0.017710166051983833,
-0.009978997521102428,
-0.01987284980714321,
0.018765965476632118,
0.03627178445458412,
-0.05541238561272621,
-0.019583357498049736,
-0.02704206295311451,
-0.03725946694612503,
-0.0017476017819717526,
-0.012337515130639076,
-0.020962707698345184,
-0.06007833406329155,
0.012030992656946182,
0.005036328453570604,
-0.04056309163570404,
0.01948118396103382,
-0.05214281752705574,
-0.03221888095140457,
-0.010072656907141209,
-0.017301470041275024,
0.04172106459736824,
0.03824714943766594,
-0.017131179571151733,
0.022273940965533257,
-0.006845660507678986,
-0.01630527339875698,
0.026411989703774452,
-0.03145257383584976,
-0.009178634732961655,
0.008586876094341278,
0.03828120604157448,
-0.02430039271712303,
0.03606743738055229,
0.02200147695839405,
0.03259351849555969,
0.09590736776590347,
-0.04458193853497505,
-0.030822502449154854,
0.03824714943766594,
0.07206675410270691,
-0.0351819284260273,
-0.0248964074999094,
-0.006151728797703981,
-0.010302549228072166,
0.04826020449399948,
-0.022699665278196335,
-0.007382074370980263,
-0.07806096225976944,
0.0021924846805632114,
0.03886019438505173,
-0.007250099442899227,
-0.062087759375572205,
-0.012652551755309105,
0.03163989260792732,
0.07540444284677505,
0.0268547423183918,
-0.020332634449005127,
0.009391496889293194,
-0.051495715975761414,
-0.0022967872209846973,
-0.05483340099453926,
-0.025645684450864792,
-0.043560199439525604,
-0.02183118648827076,
-0.04465005546808243,
0.05568484961986542,
0.0312652550637722,
0.03613555058836937,
0.012116137892007828,
-0.03203156217932701,
0.0009296773350797594,
-0.01226088497787714,
-0.04788556694984436,
-0.01951524056494236,
0.03647613152861595,
0.004103990737348795,
-0.005632343702018261,
-0.049316003918647766,
0.014185162261128426,
0.02799568697810173,
0.02241017296910286,
-0.03238917142152786,
-0.039677586406469345,
-0.022273940965533257,
0.02063915506005287,
0.021320316940546036,
-0.05330079048871994,
-0.007854629307985306,
-0.03742975741624832,
0.026411989703774452,
0.030822502449154854,
-0.08964069187641144,
-0.0060538118705153465,
0.012303457595407963,
-0.003318527713418007,
-0.04420730099081993,
-0.021388432011008263,
0.09093489497900009,
0.028523586690425873,
-0.016569223254919052,
-0.042606573551893234,
0.00014035626372788101,
-0.02372140623629093,
-0.0018231680151075125,
-0.0784696638584137,
0.013657263480126858,
0.033325765281915665,
0.04192541539669037,
0.008761423639953136,
-0.022733723744750023,
0.02860873006284237,
0.06678776443004608,
0.0021541693713515997,
-0.001474073389545083,
0.002564994152635336,
0.04206164553761482,
0.024981552734971046,
0.006458250805735588,
-0.03068627044558525,
0.07465516775846481,
-0.030839530751109123,
0.04655730351805687,
-0.0014495941577479243,
-0.06334790587425232,
-0.007471476681530476,
-0.027876483276486397,
-0.016279730945825577,
0.00657319650053978,
0.0625305101275444,
0.05347108095884323,
-0.012703638523817062,
-0.023261623457074165,
-0.03012431226670742,
0.020996764302253723,
0.0075523643754422665,
0.011315775103867054,
-0.028693875297904015,
0.03426235914230347,
-0.030022138729691505,
0.050916727632284164,
-0.0038272691890597343,
0.01871487870812416,
0.05428847298026085,
0.021524664014577866,
0.02067321352660656,
-0.014568314887583256,
-0.012439689598977566,
0.015462337993085384,
0.028506556525826454,
-0.005653630010783672,
0.02201850526034832,
-0.03964352607727051,
-0.012422660365700722,
0.09161605685949326,
-0.009680990129709244,
0.033087357878685,
-0.03012431226670742,
-0.012873928993940353,
-0.016143498942255974,
0.0020232589449733496,
-0.026411989703774452,
-0.04672759398818016,
0.03610149398446083,
0.024249305948615074,
-0.0035973775666207075,
0.024589885026216507,
-0.017437702044844627,
0.03279786556959152,
-0.007462962064892054,
-0.03189532831311226,
0.01690128818154335,
0.01496849674731493,
0.0448884591460228,
0.01970256119966507,
-0.03482431918382645,
-0.08412329107522964,
-0.05810296908020973,
0.062292106449604034,
-0.06627689301967621,
-0.026922859251499176,
0.019430097192525864,
0.03943917900323868,
0.02952829748392105,
-0.09795084595680237,
-0.062462396919727325,
0.0537094846367836,
-0.04291309788823128,
0.009791678749024868,
-0.046080492436885834,
-0.021286258473992348,
-0.023483000695705414,
0.020349662750959396,
-0.003173781093209982,
-0.02142249047756195,
-0.04996310546994209,
-0.09311460703611374,
0.03269569203257561,
0.02842141129076481,
-0.02528807520866394,
-0.06351819634437561,
-0.01815292052924633,
-0.0043317535892128944,
-0.004414769820868969,
0.05285803601145744,
-0.033683374524116516,
-0.06634500622749329,
-0.05374354496598244,
-0.008097292855381966,
-0.059771813452243805,
0.01379349548369646,
0.035045694559812546,
-0.09277402609586716,
0.0025479651521891356,
0.06941022723913193,
-0.006215587258338928,
0.006402906496077776,
0.09488562494516373,
0.011639325879514217,
-0.07172617316246033,
0.03531815856695175,
-0.01973661780357361,
-0.014185162261128426,
-0.0013463557697832584,
-0.03766816109418869,
0.013095306232571602,
0.01951524056494236,
0.0636884868144989,
0.05098484456539154,
-0.026786627247929573,
0.06654936075210571,
-0.03511381149291992,
-0.04890730604529381,
-0.018425384536385536,
0.03845149651169777,
-0.023687347769737244,
-0.06532327085733414,
0.05837543308734894,
0.008093035779893398,
0.027859454974532127,
-0.029664529487490654,
-0.012942044995725155,
0.008493216708302498,
-0.06147471442818642,
0.018016688525676727,
-0.04655730351805687,
-0.013895669020712376,
-0.04911165311932564,
0.08555372804403305,
-0.07281602919101715,
0.02625872753560543,
-0.07860589027404785,
0.010583527386188507,
-0.024283362552523613,
-0.0274337287992239,
0.01914060302078724,
-0.026939887553453445,
-0.005317307077348232,
0.01371686439961195,
-0.007037236820906401,
0.002809786004945636,
-0.005913322325795889,
-0.04386672005057335,
-0.04185729846358299,
0.04941817745566368,
-0.015215417370200157,
0.0038591986522078514,
0.041618891060352325,
-0.015615599229931831,
0.018578646704554558,
-0.0015336748911067843,
0.012558892369270325,
-0.010208888910710812,
0.03691888600587845,
0.0627008005976677,
-0.04042686149477959,
-0.014406539499759674,
0.0026373674627393484,
0.0051087019965052605,
0.050916727632284164,
0.04454788193106651,
0.040290627628564835,
0.029988080263137817,
0.0363399013876915,
-0.016143498942255974,
0.0002342818770557642,
0.05619572103023529,
0.0926377922296524,
-0.034483738243579865,
0.016943860799074173,
0.06593631207942963,
-0.02067321352660656,
-0.04148266091942787,
-0.019038429483771324,
-0.03531815856695175,
-0.040256571024656296,
0.00026301832986064255,
0.038349322974681854,
-0.03903048112988472,
-0.037736278027296066,
-0.04243628308176994,
0.03606743738055229,
0.049520350992679596,
-0.007352273445576429,
-0.03845149651169777,
-0.0969972237944603,
-0.007296929135918617,
-0.017829369753599167,
0.03507975488901138,
0.05026962608098984,
-0.008420843631029129,
0.03162286430597305,
-0.026939887553453445,
-0.04468411207199097,
0.00827183946967125,
-0.020911619067192078,
-0.02487937919795513,
0.01255037821829319,
-0.0021499120630323887,
0.04696600139141083,
0.0326446071267128,
0.04539933055639267,
0.025458363816142082,
-0.039302945137023926,
0.01914060302078724,
-0.09325084090232849,
-0.014994040131568909,
-0.0017199296271428466,
0.022478288039565086,
0.0038485554978251457,
0.014210705645382404,
0.012201283127069473,
-0.03211670741438866,
-0.02993699349462986,
0.016679910942912102,
-0.0002799142966978252,
0.011750014498829842,
-0.013495487160980701,
0.010660158470273018,
0.00925526488572359,
-0.04485440254211426,
0.03203156217932701,
-0.016654368489980698,
0.015096214599907398,
-0.0004760139563586563,
-0.005666401702910662,
0.03090764582157135,
-0.013555089011788368,
0.01079639047384262,
0.0655616745352745,
0.0021541693713515997,
-0.008310155011713505,
-0.0037655390333384275,
0.010787875391542912,
0.04570585489273071,
0.01227791327983141,
-0.00003018324787262827,
0.009774649515748024,
0.007437418680638075,
-0.019174661487340927,
0.03366634622216225,
0.02896633930504322,
0.01487483736127615,
0.021933360025286674,
0.033717431128025055,
-0.06345007568597794,
0.06317761540412903,
-0.007139410823583603,
-0.04063120856881142,
-0.016662882640957832,
0.025798944756388664,
0.036033377051353455,
0.0671624019742012,
-0.006390134803950787,
-0.035454392433166504,
-0.05943123251199722,
-0.04870295897126198,
0.05820514261722565,
0.037565987557172775,
0.04485440254211426,
0.026020321995019913,
0.008812510408461094,
-0.0000011266749879723648,
0.07104501128196716
]
|
32,034 | pingouin.pairwise | pairwise_tukey | Pairwise Tukey-HSD post-hoc test.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a Pandas method, in which
case this argument is no longer needed.
dv : string
Name of column containing the dependent variable.
between: string
Name of column containing the between factor.
effsize : string or None
Effect size type. Available methods are:
* ``'none'``: no effect size
* ``'cohen'``: Unbiased Cohen d
* ``'hedges'``: Hedges g
* ``'r'``: Pearson correlation coefficient
* ``'eta-square'``: Eta-square
* ``'odds-ratio'``: Odds ratio
* ``'AUC'``: Area Under the Curve
* ``'CLES'``: Common Language Effect Size
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'A'``: Name of first measurement
* ``'B'``: Name of second measurement
* ``'mean(A)'``: Mean of first measurement
* ``'mean(B)'``: Mean of second measurement
* ``'diff'``: Mean difference (= mean(A) - mean(B))
* ``'se'``: Standard error
* ``'T'``: T-values
* ``'p-tukey'``: Tukey-HSD corrected p-values
* ``'hedges'``: Hedges effect size (or any effect size defined in
``effsize``)
See also
--------
pairwise_tests, pairwise_gameshowell
Notes
-----
Tukey HSD post-hoc [1]_ is best for balanced one-way ANOVA.
It has been proven to be conservative for one-way ANOVA with unequal sample sizes. However, it
is not robust if the groups have unequal variances, in which case the Games-Howell test is
more adequate. Tukey HSD is not valid for repeated measures ANOVA. Only one-way ANOVA design
are supported.
The T-values are defined as:
.. math::
t = \frac{\overline{x}_i - \overline{x}_j}
{\sqrt{2 \cdot \text{MS}_w / n}}
where :math:`\overline{x}_i` and :math:`\overline{x}_j` are the means of the first and
second group, respectively, :math:`\text{MS}_w` the mean squares of the error (computed using
ANOVA) and :math:`n` the sample size.
If the sample sizes are unequal, the Tukey-Kramer procedure is automatically used:
.. math::
t = \frac{\overline{x}_i - \overline{x}_j}{\sqrt{\frac{MS_w}{n_i}
+ \frac{\text{MS}_w}{n_j}}}
where :math:`n_i` and :math:`n_j` are the sample sizes of the first and second group,
respectively.
The p-values are then approximated using the Studentized range distribution
:math:`Q(\sqrt2|t_i|, r, N - r)` where :math:`r` is the total number of groups and
:math:`N` is the total sample size.
References
----------
.. [1] Tukey, John W. "Comparing individual means in the analysis of
variance." Biometrics (1949): 99-114.
.. [2] Gleason, John R. "An accurate, non-iterative approximation for
studentized range quantiles." Computational statistics & data
analysis 31.2 (1999): 147-158.
Examples
--------
Pairwise Tukey post-hocs on the Penguins dataset.
>>> import pingouin as pg
>>> df = pg.read_dataset('penguins')
>>> df.pairwise_tukey(dv='body_mass_g', between='species').round(3)
A B mean(A) mean(B) diff se T p-tukey hedges
0 Adelie Chinstrap 3700.662 3733.088 -32.426 67.512 -0.480 0.881 -0.074
1 Adelie Gentoo 3700.662 5076.016 -1375.354 56.148 -24.495 0.000 -2.860
2 Chinstrap Gentoo 3733.088 5076.016 -1342.928 69.857 -19.224 0.000 -2.875
| @pf.register_dataframe_method
def pairwise_tukey(data=None, dv=None, between=None, effsize="hedges"):
"""Pairwise Tukey-HSD post-hoc test.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a Pandas method, in which
case this argument is no longer needed.
dv : string
Name of column containing the dependent variable.
between: string
Name of column containing the between factor.
effsize : string or None
Effect size type. Available methods are:
* ``'none'``: no effect size
* ``'cohen'``: Unbiased Cohen d
* ``'hedges'``: Hedges g
* ``'r'``: Pearson correlation coefficient
* ``'eta-square'``: Eta-square
* ``'odds-ratio'``: Odds ratio
* ``'AUC'``: Area Under the Curve
* ``'CLES'``: Common Language Effect Size
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'A'``: Name of first measurement
* ``'B'``: Name of second measurement
* ``'mean(A)'``: Mean of first measurement
* ``'mean(B)'``: Mean of second measurement
* ``'diff'``: Mean difference (= mean(A) - mean(B))
* ``'se'``: Standard error
* ``'T'``: T-values
* ``'p-tukey'``: Tukey-HSD corrected p-values
* ``'hedges'``: Hedges effect size (or any effect size defined in
``effsize``)
See also
--------
pairwise_tests, pairwise_gameshowell
Notes
-----
Tukey HSD post-hoc [1]_ is best for balanced one-way ANOVA.
It has been proven to be conservative for one-way ANOVA with unequal sample sizes. However, it
is not robust if the groups have unequal variances, in which case the Games-Howell test is
more adequate. Tukey HSD is not valid for repeated measures ANOVA. Only one-way ANOVA design
are supported.
The T-values are defined as:
.. math::
t = \\frac{\\overline{x}_i - \\overline{x}_j}
{\\sqrt{2 \\cdot \\text{MS}_w / n}}
where :math:`\\overline{x}_i` and :math:`\\overline{x}_j` are the means of the first and
second group, respectively, :math:`\\text{MS}_w` the mean squares of the error (computed using
ANOVA) and :math:`n` the sample size.
If the sample sizes are unequal, the Tukey-Kramer procedure is automatically used:
.. math::
t = \\frac{\\overline{x}_i - \\overline{x}_j}{\\sqrt{\\frac{MS_w}{n_i}
+ \\frac{\\text{MS}_w}{n_j}}}
where :math:`n_i` and :math:`n_j` are the sample sizes of the first and second group,
respectively.
The p-values are then approximated using the Studentized range distribution
:math:`Q(\\sqrt2|t_i|, r, N - r)` where :math:`r` is the total number of groups and
:math:`N` is the total sample size.
References
----------
.. [1] Tukey, John W. "Comparing individual means in the analysis of
variance." Biometrics (1949): 99-114.
.. [2] Gleason, John R. "An accurate, non-iterative approximation for
studentized range quantiles." Computational statistics & data
analysis 31.2 (1999): 147-158.
Examples
--------
Pairwise Tukey post-hocs on the Penguins dataset.
>>> import pingouin as pg
>>> df = pg.read_dataset('penguins')
>>> df.pairwise_tukey(dv='body_mass_g', between='species').round(3)
A B mean(A) mean(B) diff se T p-tukey hedges
0 Adelie Chinstrap 3700.662 3733.088 -32.426 67.512 -0.480 0.881 -0.074
1 Adelie Gentoo 3700.662 5076.016 -1375.354 56.148 -24.495 0.000 -2.860
2 Chinstrap Gentoo 3733.088 5076.016 -1342.928 69.857 -19.224 0.000 -2.875
"""
# First compute the ANOVA
# For max precision, make sure rounding is disabled
old_options = options.copy()
options["round"] = None
aov = anova(dv=dv, data=data, between=between, detailed=True)
options.update(old_options) # Restore original options
df = aov.at[1, "DF"]
ng = aov.at[0, "DF"] + 1
grp = data.groupby(between, observed=True)[dv] # default is sort=True
# Careful: pd.unique does NOT sort whereas numpy does
# The line below should be equal to labels = np.unique(data[between])
# However, this does not work if between is a Categorical column, because
# Pandas applies a custom, not alphabetical, sorting.
# See https://github.com/raphaelvallat/pingouin/issues/111
labels = np.array(list(grp.groups.keys()))
n = grp.count().to_numpy()
gmeans = grp.mean(numeric_only=True).to_numpy()
gvar = aov.at[1, "MS"] / n
# Pairwise combinations
g1, g2 = np.array(list(combinations(np.arange(ng), 2))).T
mn = gmeans[g1] - gmeans[g2]
se = np.sqrt(gvar[g1] + gvar[g2])
tval = mn / se
# Critical values and p-values
# crit = studentized_range.ppf(1 - alpha, ng, df) / np.sqrt(2)
pval = studentized_range.sf(np.sqrt(2) * np.abs(tval), ng, df)
pval = np.clip(pval, 0, 1)
# Uncorrected p-values
# from scipy.stats import t
# punc = t.sf(np.abs(tval), n[g1].size + n[g2].size - 2) * 2
# Effect size
# Method 1: Approximation
# d = tval * np.sqrt(1 / n[g1] + 1 / n[g2])
# ef = convert_effsize(d, "cohen", effsize, n[g1], n[g2])
# Method 2: Exact
ef = []
for idx_a, idx_b in zip(g1, g2):
ef.append(
compute_effsize(
grp.get_group(labels[idx_a]),
grp.get_group(labels[idx_b]),
paired=False,
eftype=effsize,
)
)
# Create dataframe
stats = pd.DataFrame(
{
"A": labels[g1],
"B": labels[g2],
"mean(A)": gmeans[g1],
"mean(B)": gmeans[g2],
"diff": mn,
"se": se,
"T": tval,
"p-tukey": pval,
effsize: ef,
}
)
return _postprocess_dataframe(stats)
| (data=None, dv=None, between=None, effsize='hedges') | [
0.029913434758782387,
-0.026878738775849342,
-0.016633786261081696,
-0.009258105419576168,
0.011842160485684872,
-0.02317093312740326,
0.0041213687509298325,
-0.06658077985048294,
0.0042183417826890945,
0.014386286027729511,
-0.03224079683423042,
0.004500705748796463,
0.04246293008327484,
0.02379840798676014,
-0.05955306440591812,
0.021345552057027817,
0.037853844463825226,
0.015173481777310371,
0.051201943308115005,
-0.01301725022494793,
-0.006291861180216074,
-0.012766259722411633,
-0.030232876539230347,
-0.006748206447809935,
-0.03144219145178795,
0.027084093540906906,
-0.025897596031427383,
-0.05298168957233429,
0.04374069720506668,
-0.005287901498377323,
-0.0036022758577018976,
-0.0234561488032341,
-0.05129321292042732,
0.016314344480633736,
0.0063546085730195045,
-0.05489834025502205,
0.01063854992389679,
-0.0004438671167008579,
-0.008835986256599426,
0.05115630850195885,
0.005784176755696535,
-0.045474808663129807,
0.03901752457022667,
-0.046775393187999725,
-0.0028008194640278816,
0.04059191420674324,
-0.007449837401509285,
0.06968393176794052,
0.0022289615590125322,
-0.05334676802158356,
0.028635667636990547,
-0.040751636028289795,
-0.005978123750537634,
0.036005645990371704,
-0.028316225856542587,
0.05927925556898117,
-0.0020449974108487368,
-0.0013369491789489985,
0.014009800739586353,
-0.05485270544886589,
0.015184890478849411,
0.04469902440905571,
0.036005645990371704,
0.029251733794808388,
-0.05841220170259476,
-0.03680424764752388,
-0.00859070010483265,
-0.01139151956886053,
-0.022657545283436775,
-0.01187638659030199,
-0.009395008906722069,
0.00034921112819574773,
-0.008185693994164467,
0.02596604824066162,
-0.0005009102751500905,
0.01111771259456873,
-0.00981712806969881,
-0.06124154105782509,
-0.0014574528904631734,
-0.0011622544843703508,
0.007364272605627775,
0.00998825766146183,
0.01140292827039957,
-0.03618818148970604,
0.0001989380398299545,
0.012652173638343811,
0.023866860195994377,
0.02667338401079178,
0.03856118023395538,
-0.035366762429475784,
-0.01991947367787361,
-0.0253271646797657,
0.045520443469285965,
-0.004629052709788084,
0.02922891639173031,
0.010501646436750889,
-0.04723174124956131,
-0.014158112928271294,
-0.07401920855045319,
-0.022737404331564903,
0.040112752467393875,
0.0291832834482193,
0.08866789191961288,
0.05886854603886604,
-0.001675642910413444,
0.005213745404034853,
-0.0533011332154274,
0.0455888956785202,
-0.020455678924918175,
0.0020464234985411167,
-0.07023154199123383,
0.008151467889547348,
0.004937085788697004,
-0.022417962551116943,
0.009452052414417267,
-0.06434468924999237,
0.01675928197801113,
0.05581103265285492,
-0.06051138788461685,
-0.020432861521840096,
0.031259652227163315,
0.017192808911204338,
-0.03454533964395523,
-0.03609691560268402,
-0.0278598815202713,
-0.06055702269077301,
0.036576077342033386,
0.034043360501527786,
-0.03559493273496628,
0.006679754704236984,
-0.010552985593676567,
0.0215280894190073,
0.015549966134130955,
0.05179519206285477,
-0.006805249489843845,
-0.02002215012907982,
0.06890814006328583,
0.018276629969477654,
0.0756620541214943,
-0.008436683565378189,
0.04850950837135315,
0.015333202667534351,
-0.030689222738146782,
-0.018253812566399574,
0.06521174311637878,
-0.016896184533834457,
0.012720625847578049,
-0.01044460292905569,
0.014660093002021313,
0.03194417059421539,
-0.02884102426469326,
0.0077692787162959576,
0.059142351150512695,
-0.008733308874070644,
0.08620362728834152,
-0.04978727176785469,
0.03525267541408539,
-0.05298168957233429,
-0.027152545750141144,
-0.059781234711408615,
-0.0029776531737297773,
-0.055993568152189255,
-0.0023002654779702425,
0.053757477551698685,
0.017614929005503654,
0.02375277318060398,
0.0058526284992694855,
0.028453130275011063,
0.01653110980987549,
-0.026764651760458946,
-0.012880346737802029,
0.030050339177250862,
-0.04574861750006676,
0.02977653220295906,
0.011642510071396828,
-0.007489767391234636,
-0.0026895850896835327,
-0.04609087482094765,
0.0394282341003418,
-0.08620362728834152,
-0.037237778306007385,
-0.0013661837438121438,
-0.030826125293970108,
0.013074292801320553,
-0.0469122976064682,
0.023547418415546417,
0.06712839752435684,
-0.01679350808262825,
-0.02091202326118946,
-0.02025032415986061,
-0.07442992180585861,
-0.06516610831022263,
-0.02091202326118946,
0.06151534989476204,
0.05777331814169884,
0.015116438269615173,
0.010359038598835468,
0.011819344013929367,
0.0057727680541574955,
0.019851021468639374,
-0.0067995451390743256,
-0.0003914587141480297,
-0.0011722369818016887,
0.007455541752278805,
0.028019601479172707,
-0.0002139118587365374,
-0.022452188655734062,
0.003431146265938878,
0.002783706411719322,
-0.01156264916062355,
0.019805386662483215,
-0.05644991621375084,
0.004489297047257423,
0.060739561915397644,
0.02952554263174534,
-0.04241729527711868,
0.034682244062423706,
-0.005995236337184906,
0.0015387393068522215,
0.0011251764371991158,
0.017911553382873535,
-0.022349512204527855,
-0.007774983067065477,
0.07424738258123398,
0.06142408028244972,
0.008402458392083645,
0.045155368745326996,
0.09259246289730072,
0.011636805720627308,
-0.032172344624996185,
0.026217037811875343,
0.015184890478849411,
-0.0035651978105306625,
-0.009440643712878227,
-0.04860077425837517,
-0.01679350808262825,
-0.055172149091959,
-0.04034092649817467,
-0.0218589399009943,
0.0011864978587254882,
-0.010244952514767647,
-0.022463597357273102,
0.033450111746788025,
0.017329713329672813,
-0.07214819639921188,
-0.06790418177843094,
0.04983290657401085,
0.014329242520034313,
0.009018524549901485,
-0.00035687629133462906,
0.007529697846621275,
-0.07287834584712982,
-0.005712872836738825,
0.03707805648446083,
-0.04556607827544212,
-0.04109389707446098,
0.05603920295834541,
0.02817932330071926,
0.03655325993895531,
-0.04346689209342003,
0.0215851329267025,
-0.027517622336745262,
-0.026217037811875343,
0.04755118116736412,
-0.03463660925626755,
0.003342729527503252,
0.008813168853521347,
-0.011967656202614307,
-0.040751636028289795,
-0.024870820343494415,
-0.03828737139701843,
0.03586874157190323,
-0.05731697008013725,
-0.0020293104462325573,
-0.06516610831022263,
0.06484667211771011,
0.022999804466962814,
0.0020892058964818716,
-0.009315148927271366,
-0.03511577099561691,
-0.017683381214737892,
-0.04088854044675827,
-0.00951479934155941,
-0.002826488809660077,
-0.04082008823752403,
0.0024072215892374516,
-0.029023561626672745,
-0.04465338960289955,
0.08702505379915237,
-0.004688947927206755,
-0.06676331907510757,
-0.053438037633895874,
-0.011864977888762951,
-0.006662641651928425,
0.03452252224087715,
0.05366620793938637,
-0.021505272015929222,
-0.028407495468854904,
0.004811591003090143,
-0.0022617613431066275,
-0.007929000072181225,
0.019086642190814018,
0.0342487171292305,
0.045178186148405075,
-0.04654722288250923,
0.04132206737995148,
0.09199921786785126,
-0.058822911232709885,
0.03319912031292915,
-0.07096169888973236,
-0.00042532809311524034,
0.046821027994155884,
-0.025235895067453384,
0.0533011332154274,
0.01299443282186985,
-0.031875718384981155,
-0.028270592913031578,
-0.017512250691652298,
0.05179519206285477,
0.05047179013490677,
-0.05480707064270973,
-0.04714047163724899,
0.042942095547914505,
-0.0177860576659441,
0.06000940874218941,
-0.005521778482943773,
0.03461379185318947,
-0.051886461675167084,
0.017033088952302933,
-0.009754381142556667,
-0.0607851967215538,
-0.010524463839828968,
0.04513255134224892,
0.04732300713658333,
-0.07415611296892166,
-0.0000807517280918546,
0.009132610633969307,
0.002923462074249983,
0.02222401648759842,
0.019896656274795532,
0.03605128079652786,
0.021619359031319618,
-0.026239855214953423,
-0.025190262123942375,
0.0373290479183197,
-0.06534864753484726,
-0.012446817941963673,
0.016325753182172775,
0.05101940408349037,
0.012709217146039009,
0.019862430170178413,
0.040774453431367874,
0.035024501383304596,
0.040728818625211716,
0.09373332560062408,
0.004161298740655184,
0.013256831094622612,
-0.01205892488360405,
0.006605598609894514,
0.0437178798019886,
0.050243619829416275,
-0.01654251664876938,
0.002477099420502782,
-0.017352530732750893,
0.00983994547277689,
-0.03776257485151291,
-0.00037006751517765224,
-0.025190262123942375,
0.0012100280728191137,
0.019520170986652374,
0.004928529262542725,
-0.044539302587509155,
0.035709019750356674,
0.030232876539230347,
0.04351252689957619,
0.03700960427522659,
-0.0398617647588253,
-0.012138784863054752,
-0.025144627317786217,
0.0073243421502411366,
0.04987854138016701,
0.0029348707757890224,
-0.008197102695703506,
0.06945575773715973,
0.01109489519149065,
-0.03137373924255371,
0.020809346809983253,
-0.0034225897397845984,
0.0202617309987545,
-0.0250533577054739,
0.03246896713972092,
-0.01617744192481041,
0.059781234711408615,
0.019155094400048256,
0.01680491678416729,
0.02822495810687542,
-0.08789210766553879,
-0.022383738309144974,
-0.03132810443639755,
0.01412388775497675,
-0.012287097983062267,
-0.03935978189110756,
0.0020692406687885523,
-0.003548084758222103,
-0.01675928197801113,
-0.040523461997509,
0.02382122538983822,
-0.004483592696487904,
-0.0285215824842453,
0.027951151132583618,
-0.060100678354501724,
0.05348367244005203,
-0.02728945016860962,
-0.00027273764135316014,
-0.004363802261650562,
0.001716999220661819,
-0.034043360501527786,
0.004731730557978153,
0.015470106154680252,
0.05289041996002197,
0.06808672100305557,
-0.05749950930476189,
-0.046821027994155884,
0.008003155700862408,
0.04846387356519699,
-0.019234955310821533,
-0.05069996416568756,
-0.003106000367552042,
0.00025366380577906966,
0.014146704226732254,
0.029662445187568665,
0.02314811572432518,
-0.04109389707446098,
-0.0055160741321742535,
-0.0023872563615441322,
0.02473391592502594,
-0.05512651428580284,
0.0487833134829998,
0.0917254090309143,
0.019463127478957176,
-0.04923965781927109,
0.021984435617923737,
0.018881287425756454,
0.0023002654779702425,
0.010672776028513908,
-0.02471109852194786,
-0.01643984019756317,
-0.01807127520442009,
-0.03780820965766907,
-0.05864037200808525,
0.09446348249912262,
0.03673579916357994,
0.03803637996315956,
0.013188379816710949,
-0.03459097445011139,
0.019896656274795532,
-0.0034853373654186726,
-0.03655325993895531,
-0.05804712325334549,
0.018778609111905098,
0.002313100267201662,
0.006029462441802025,
-0.0323777012526989,
0.053711842745542526,
-0.0001550861052237451,
0.02856721729040146,
0.018185360357165337,
-0.03970204293727875,
0.004820147529244423,
0.007923295721411705,
-0.0361197330057621,
-0.024163484573364258,
-0.012469635345041752,
0.02343333140015602,
0.0187215656042099,
0.02537279948592186,
-0.01031340379267931,
0.0009854206582531333,
-0.03383800387382507,
-0.011967656202614307,
0.03205825760960579,
-0.03673579916357994,
0.07251326739788055,
0.015025169588625431,
0.022075705230236053,
0.016245892271399498,
0.012013290077447891,
-0.005510369781404734,
-0.014374877326190472,
-0.0589141808450222,
-0.010205022059381008,
-0.040751636028289795,
0.010279178619384766,
0.053757477551698685,
-0.046478770673274994,
0.018596071749925613,
0.047459911555051804,
-0.02062680758535862,
0.020524131134152412,
-0.042326029390096664,
0.06407088041305542,
0.01770619861781597,
-0.002003641100600362,
-0.06991209834814072,
0.06858870387077332,
0.006867996882647276,
0.031533461064100266,
0.030917394906282425,
-0.03210389241576195,
0.001478843973018229,
0.00032960253884084523,
-0.05489834025502205,
0.05298168957233429,
-0.003955943509936333,
0.05042615532875061,
0.00875042099505663,
-0.010849609971046448,
-0.014933899976313114,
0.008875916711986065,
-0.021368369460105896,
0.012606538832187653,
-0.03529831022024155,
0.022760221734642982,
0.0379907488822937,
0.021425412967801094,
0.037899479269981384,
-0.0008014564518816769,
0.05763641372323036,
0.01268639974296093,
0.01000537071377039,
-0.027814246714115143,
-0.022269651293754578,
0.039131611585617065,
0.03812764957547188,
-0.016268709674477577,
-0.01455741561949253,
-0.05644991621375084,
-0.052114635705947876,
0.01111200824379921,
0.004018690902739763,
0.022281059995293617,
-0.021334143355488777,
-0.013599090278148651,
-0.09012819826602936,
0.025190262123942375,
0.04006711766123772,
-0.001354062114842236,
-0.04036374390125275,
-0.01139722391963005,
-0.027061276137828827,
0.02375277318060398,
-0.00006586702511413023,
0.06881687045097351,
0.04666130989789963,
-0.0015815217047929764,
0.006006645038723946,
0.026239855214953423,
0.0016856255242601037,
0.009092680178582668,
-0.025829143822193146,
-0.027951151132583618,
-0.08150327205657959,
0.019873838871717453,
-0.06521174311637878,
0.01014227420091629,
-0.004346689209342003,
-0.018208177760243416,
0.05672372132539749,
-0.08209652453660965,
-0.04287364333868027,
-0.04563453048467636,
0.026057317852973938,
-0.0010823940392583609,
-0.03584592416882515,
-0.06251930445432663,
-0.00953761674463749,
-0.008887325413525105,
-0.00890443753451109,
-0.004047212656587362,
-0.04314744845032692,
-0.04127643257379532,
0.0294570904225111,
0.04819006472826004,
0.01045030727982521,
-0.012435410171747208,
0.041025444865226746,
0.005995236337184906,
0.04431112855672836,
0.0038846393581479788,
0.006132140289992094,
-0.08405880630016327,
-0.04620496183633804,
-0.052525345236063004,
-0.04193813353776932,
0.012298505753278732,
0.0379907488822937,
-0.0035651978105306625,
0.000835682381875813,
0.0825984999537468,
0.002140544820576906,
0.006086505483835936,
0.014397694729268551,
-0.0070391264744102955,
0.004894303623586893,
0.022771630436182022,
-0.008499431423842907,
0.03518422320485115,
0.007409906946122646,
-0.003713509999215603,
-0.03525267541408539,
0.0487833134829998,
0.03924569860100746,
0.028749754652380943,
-0.024574195966124535,
0.030187241733074188,
-0.005498961079865694,
-0.011368702165782452,
-0.04177841171622276,
0.02033018320798874,
-0.039747677743434906,
-0.03926851227879524,
0.0663982406258583,
0.008214215748012066,
0.0393141470849514,
-0.022965578362345695,
-0.03046104870736599,
0.028156505897641182,
-0.021950209513306618,
-0.04536072537302971,
-0.08542784303426743,
-0.006189183332026005,
0.011015035212039948,
0.027175363153219223,
-0.012925980612635612,
0.01743239164352417,
0.00024974209372885525,
0.03299376741051674,
-0.00009091254469240084,
-0.013234013691544533,
0.026399577036499977,
-0.027175363153219223,
-0.02790551632642746,
0.02603450044989586,
0.0589141808450222,
0.028339043259620667,
-0.0018966852221637964,
-0.006411651615053415,
-0.03228643164038658,
-0.03751158341765404,
0.04180122911930084,
0.03869808092713356,
-0.01771760731935501,
-0.030848942697048187,
-0.06658077985048294,
-0.0273122675716877,
0.0253271646797657,
0.03529831022024155,
-0.005798437632620335,
0.006976379081606865,
-0.005073989275842905,
-0.016268709674477577,
0.014295017346739769,
-0.028590034693479538,
-0.005667238496243954,
0.06388834118843079,
0.02350178360939026,
0.04111671447753906,
0.03228643164038658,
-0.006360312923789024,
0.04447085037827492,
0.03073485754430294,
0.039108794182538986,
-0.05097377300262451,
0.014044026844203472,
0.02788269892334938,
-0.029981886968016624,
0.01841353252530098,
0.010028188116848469,
-0.04465338960289955,
-0.04860077425837517,
0.06571372598409653,
0.08154890686273575,
0.009623182006180286,
-0.06375143676996231,
0.004246863536536694,
-0.027951151132583618,
0.06954702734947205,
-0.030963029712438583,
-0.03625663369894028,
-0.12029262632131577,
-0.03308503329753876,
-0.05749950930476189,
-0.023364879190921783,
0.025418434292078018,
-0.029343003407120705,
-0.03276559337973595,
0.010821088217198849,
0.0019195025088265538,
0.006280452478677034,
-0.015937859192490578,
-0.041846863925457,
-0.04663849249482155,
0.03735186532139778,
0.015184890478849411,
-0.019816795364022255,
0.0938245952129364,
-0.014488963410258293,
-0.018641706556081772,
0.04568016529083252,
-0.08319175243377686,
-0.014397694729268551,
-0.006662641651928425,
0.0019009634852409363,
-0.009771494194865227,
0.03265150636434555,
-0.003003322519361973,
-0.05676935613155365,
0.03306221961975098,
0.009617477655410767,
0.020718077197670937,
0.02377559058368206,
0.008322597481310368,
0.04506409913301468,
-0.028932292014360428,
-0.07032281160354614,
0.027677342295646667,
0.021995844319462776,
0.016006311401724815,
0.015150664374232292,
-0.0457029826939106,
0.007501176092773676,
0.006867996882647276,
-0.010279178619384766,
0.00010677767568267882,
-0.01581236533820629,
-0.015698278322815895,
-0.014386286027729511,
-0.061059001833200455,
0.051886461675167084,
0.08497149497270584,
-0.021311325952410698,
0.0037334749940782785,
-0.05133884772658348,
-0.110344298183918,
0.03372391685843468,
0.03637072071433067,
-0.0004085716500412673,
0.011140529997646809,
0.04686666280031204,
-0.06954702734947205,
0.05161265656352043,
-0.03210389241576195,
-0.04376351460814476,
-0.010410377755761147,
0.0834655612707138,
0.041048262268304825,
0.04668412730097771,
-0.04337562248110771,
-0.012948798015713692,
-0.0546245351433754,
-0.03201262280344963,
-0.02127709984779358,
0.03801356628537178,
0.06219986453652382,
0.016337161883711815,
0.017831692472100258,
-0.013872897252440453,
0.05480707064270973
]
|
32,036 | pingouin.correlation | partial_corr | Partial and semi-partial correlation.
Parameters
----------
data : :py:class:`pandas.DataFrame`
Pandas Dataframe. Note that this function can also directly be used
as a :py:class:`pandas.DataFrame` method, in which case this argument
is no longer needed.
x, y : string
x and y. Must be names of columns in ``data``.
covar : string or list
Covariate(s). Must be a names of columns in ``data``. Use a list if
there are two or more covariates.
x_covar : string or list
Covariate(s) for the ``x`` variable. This is used to compute
semi-partial correlation (i.e. the effect of ``x_covar`` is removed
from ``x`` but not from ``y``). Only one of ``covar``, ``x_covar`` and
``y_covar`` can be specified.
y_covar : string or list
Covariate(s) for the ``y`` variable. This is used to compute
semi-partial correlation (i.e. the effect of ``y_covar`` is removed
from ``y`` but not from ``x``). Only one of ``covar``, ``x_covar`` and
``y_covar`` can be specified.
alternative : string
Defines the alternative hypothesis, or tail of the partial correlation. Must be one of
"two-sided" (default), "greater" or "less". Both "greater" and "less" return a one-sided
p-value. "greater" tests against the alternative hypothesis that the partial correlation is
positive (greater than zero), "less" tests against the hypothesis that the partial
correlation is negative.
method : string
Correlation type:
* ``'pearson'``: Pearson :math:`r` product-moment correlation
* ``'spearman'``: Spearman :math:`\rho` rank-order correlation
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'n'``: Sample size (after removal of missing values)
* ``'r'``: Partial correlation coefficient
* ``'CI95'``: 95% parametric confidence intervals around :math:`r`
* ``'p-val'``: p-value
See also
--------
corr, pcorr, pairwise_corr, rm_corr
Notes
-----
Partial correlation [1]_ measures the degree of association between ``x``
and ``y``, after removing the effect of one or more controlling variables
(``covar``, or :math:`Z`). Practically, this is achieved by calculating the
correlation coefficient between the residuals of two linear regressions:
.. math:: x \sim Z, y \sim Z
Like the correlation coefficient, the partial correlation
coefficient takes on a value in the range from –1 to 1, where 1 indicates a
perfect positive association.
The semipartial correlation is similar to the partial correlation,
with the exception that the set of controlling variables is only
removed for either ``x`` or ``y``, but not both.
Pingouin uses the method described in [2]_ to calculate the (semi)partial
correlation coefficients and associated p-values. This method is based on
the inverse covariance matrix and is significantly faster than the
traditional regression-based method. Results have been tested against the
`ppcor <https://cran.r-project.org/web/packages/ppcor/index.html>`_
R package.
.. important:: Rows with missing values are automatically removed from
data.
References
----------
.. [1] https://en.wikipedia.org/wiki/Partial_correlation
.. [2] https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4681537/
Examples
--------
1. Partial correlation with one covariate
>>> import pingouin as pg
>>> df = pg.read_dataset('partial_corr')
>>> pg.partial_corr(data=df, x='x', y='y', covar='cv1').round(3)
n r CI95% p-val
pearson 30 0.568 [0.25, 0.77] 0.001
2. Spearman partial correlation with several covariates
>>> # Partial correlation of x and y controlling for cv1, cv2 and cv3
>>> pg.partial_corr(data=df, x='x', y='y', covar=['cv1', 'cv2', 'cv3'],
... method='spearman').round(3)
n r CI95% p-val
spearman 30 0.521 [0.18, 0.75] 0.005
3. Same but one-sided test
>>> pg.partial_corr(data=df, x='x', y='y', covar=['cv1', 'cv2', 'cv3'],
... alternative="greater", method='spearman').round(3)
n r CI95% p-val
spearman 30 0.521 [0.24, 1.0] 0.003
>>> pg.partial_corr(data=df, x='x', y='y', covar=['cv1', 'cv2', 'cv3'],
... alternative="less", method='spearman').round(3)
n r CI95% p-val
spearman 30 0.521 [-1.0, 0.72] 0.997
4. As a pandas method
>>> df.partial_corr(x='x', y='y', covar=['cv1'], method='spearman').round(3)
n r CI95% p-val
spearman 30 0.578 [0.27, 0.78] 0.001
5. Partial correlation matrix (returns only the correlation coefficients)
>>> df.pcorr().round(3)
x y cv1 cv2 cv3
x 1.000 0.493 -0.095 0.130 -0.385
y 0.493 1.000 -0.007 0.104 -0.002
cv1 -0.095 -0.007 1.000 -0.241 -0.470
cv2 0.130 0.104 -0.241 1.000 -0.118
cv3 -0.385 -0.002 -0.470 -0.118 1.000
6. Semi-partial correlation on x
>>> pg.partial_corr(data=df, x='x', y='y', x_covar=['cv1', 'cv2', 'cv3']).round(3)
n r CI95% p-val
pearson 30 0.463 [0.1, 0.72] 0.015
| @pf.register_dataframe_method
def partial_corr(
data=None,
x=None,
y=None,
covar=None,
x_covar=None,
y_covar=None,
alternative="two-sided",
method="pearson",
):
"""Partial and semi-partial correlation.
Parameters
----------
data : :py:class:`pandas.DataFrame`
Pandas Dataframe. Note that this function can also directly be used
as a :py:class:`pandas.DataFrame` method, in which case this argument
is no longer needed.
x, y : string
x and y. Must be names of columns in ``data``.
covar : string or list
Covariate(s). Must be a names of columns in ``data``. Use a list if
there are two or more covariates.
x_covar : string or list
Covariate(s) for the ``x`` variable. This is used to compute
semi-partial correlation (i.e. the effect of ``x_covar`` is removed
from ``x`` but not from ``y``). Only one of ``covar``, ``x_covar`` and
``y_covar`` can be specified.
y_covar : string or list
Covariate(s) for the ``y`` variable. This is used to compute
semi-partial correlation (i.e. the effect of ``y_covar`` is removed
from ``y`` but not from ``x``). Only one of ``covar``, ``x_covar`` and
``y_covar`` can be specified.
alternative : string
Defines the alternative hypothesis, or tail of the partial correlation. Must be one of
"two-sided" (default), "greater" or "less". Both "greater" and "less" return a one-sided
p-value. "greater" tests against the alternative hypothesis that the partial correlation is
positive (greater than zero), "less" tests against the hypothesis that the partial
correlation is negative.
method : string
Correlation type:
* ``'pearson'``: Pearson :math:`r` product-moment correlation
* ``'spearman'``: Spearman :math:`\\rho` rank-order correlation
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'n'``: Sample size (after removal of missing values)
* ``'r'``: Partial correlation coefficient
* ``'CI95'``: 95% parametric confidence intervals around :math:`r`
* ``'p-val'``: p-value
See also
--------
corr, pcorr, pairwise_corr, rm_corr
Notes
-----
Partial correlation [1]_ measures the degree of association between ``x``
and ``y``, after removing the effect of one or more controlling variables
(``covar``, or :math:`Z`). Practically, this is achieved by calculating the
correlation coefficient between the residuals of two linear regressions:
.. math:: x \\sim Z, y \\sim Z
Like the correlation coefficient, the partial correlation
coefficient takes on a value in the range from –1 to 1, where 1 indicates a
perfect positive association.
The semipartial correlation is similar to the partial correlation,
with the exception that the set of controlling variables is only
removed for either ``x`` or ``y``, but not both.
Pingouin uses the method described in [2]_ to calculate the (semi)partial
correlation coefficients and associated p-values. This method is based on
the inverse covariance matrix and is significantly faster than the
traditional regression-based method. Results have been tested against the
`ppcor <https://cran.r-project.org/web/packages/ppcor/index.html>`_
R package.
.. important:: Rows with missing values are automatically removed from
data.
References
----------
.. [1] https://en.wikipedia.org/wiki/Partial_correlation
.. [2] https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4681537/
Examples
--------
1. Partial correlation with one covariate
>>> import pingouin as pg
>>> df = pg.read_dataset('partial_corr')
>>> pg.partial_corr(data=df, x='x', y='y', covar='cv1').round(3)
n r CI95% p-val
pearson 30 0.568 [0.25, 0.77] 0.001
2. Spearman partial correlation with several covariates
>>> # Partial correlation of x and y controlling for cv1, cv2 and cv3
>>> pg.partial_corr(data=df, x='x', y='y', covar=['cv1', 'cv2', 'cv3'],
... method='spearman').round(3)
n r CI95% p-val
spearman 30 0.521 [0.18, 0.75] 0.005
3. Same but one-sided test
>>> pg.partial_corr(data=df, x='x', y='y', covar=['cv1', 'cv2', 'cv3'],
... alternative="greater", method='spearman').round(3)
n r CI95% p-val
spearman 30 0.521 [0.24, 1.0] 0.003
>>> pg.partial_corr(data=df, x='x', y='y', covar=['cv1', 'cv2', 'cv3'],
... alternative="less", method='spearman').round(3)
n r CI95% p-val
spearman 30 0.521 [-1.0, 0.72] 0.997
4. As a pandas method
>>> df.partial_corr(x='x', y='y', covar=['cv1'], method='spearman').round(3)
n r CI95% p-val
spearman 30 0.578 [0.27, 0.78] 0.001
5. Partial correlation matrix (returns only the correlation coefficients)
>>> df.pcorr().round(3)
x y cv1 cv2 cv3
x 1.000 0.493 -0.095 0.130 -0.385
y 0.493 1.000 -0.007 0.104 -0.002
cv1 -0.095 -0.007 1.000 -0.241 -0.470
cv2 0.130 0.104 -0.241 1.000 -0.118
cv3 -0.385 -0.002 -0.470 -0.118 1.000
6. Semi-partial correlation on x
>>> pg.partial_corr(data=df, x='x', y='y', x_covar=['cv1', 'cv2', 'cv3']).round(3)
n r CI95% p-val
pearson 30 0.463 [0.1, 0.72] 0.015
"""
from pingouin.utils import _flatten_list
# Safety check
assert alternative in [
"two-sided",
"greater",
"less",
], "Alternative must be one of 'two-sided' (default), 'greater' or 'less'."
assert method in [
"pearson",
"spearman",
], 'only "pearson" and "spearman" are supported for partial correlation.'
assert isinstance(data, pd.DataFrame), "data must be a pandas DataFrame."
assert data.shape[0] > 2, "Data must have at least 3 samples."
if covar is not None and (x_covar is not None or y_covar is not None):
raise ValueError("Cannot specify both covar and {x,y}_covar.")
if x_covar is not None and y_covar is not None:
raise ValueError("Cannot specify both x_covar and y_covar.")
assert x != y, "x and y must be independent"
if isinstance(covar, list):
assert x not in covar, "x and covar must be independent"
assert y not in covar, "y and covar must be independent"
else:
assert x != covar, "x and covar must be independent"
assert y != covar, "y and covar must be independent"
# Check that columns exist
col = _flatten_list([x, y, covar, x_covar, y_covar])
assert all([c in data for c in col]), "columns are not in dataframe."
# Check that columns are numeric
assert all([data[c].dtype.kind in "bfiu" for c in col])
# Drop rows with NaN
data = data[col].dropna()
n = data.shape[0] # Number of samples
k = data.shape[1] - 2 # Number of covariates
assert n > 2, "Data must have at least 3 non-NAN samples."
# Calculate the partial corrrelation matrix - similar to pingouin.pcorr()
if method == "spearman":
# Convert the data to rank, similar to R cov()
V = data.rank(na_option="keep").cov(numeric_only=True)
else:
V = data.cov(numeric_only=True)
Vi = np.linalg.pinv(V, hermitian=True) # Inverse covariance matrix
Vi_diag = Vi.diagonal()
D = np.diag(np.sqrt(1 / Vi_diag))
pcor = -1 * (D @ Vi @ D) # Partial correlation matrix
if covar is not None:
r = pcor[0, 1]
else:
# Semi-partial correlation matrix
with np.errstate(divide="ignore"):
spcor = (
pcor
/ np.sqrt(np.diag(V))[..., None]
/ np.sqrt(np.abs(Vi_diag - Vi**2 / Vi_diag[..., None])).T
)
if y_covar is not None:
r = spcor[0, 1] # y_covar is removed from y
else:
r = spcor[1, 0] # x_covar is removed from x
if np.isnan(r):
| (data=None, x=None, y=None, covar=None, x_covar=None, y_covar=None, alternative='two-sided', method='pearson') | [
-0.011604144237935543,
-0.037738870829343796,
0.06299973279237747,
-0.015567030757665634,
0.01566864363849163,
-0.028593748807907104,
-0.008393189869821072,
-0.015069129876792431,
0.07917644083499908,
-0.04324626922607422,
-0.015180903486907482,
-0.013209621421992779,
-0.029691163450479507,
0.022883128374814987,
-0.0449533574283123,
0.0037266374565660954,
-0.030707288533449173,
-0.010913179256021976,
-0.02158248797059059,
-0.04206756129860878,
0.020779749378561974,
0.05365138500928879,
-0.041274987161159515,
0.04174240306019783,
0.012457689270377159,
-0.009312783367931843,
-0.011451725848019123,
-0.026480209082365036,
0.03355243802070618,
0.035686299204826355,
0.027963751927018166,
-0.0001854427537182346,
-0.029731808230280876,
-0.016115738078951836,
-0.006315215025097132,
-0.030605675652623177,
0.06275586038827896,
-0.018341051414608955,
-0.05422041565179825,
0.017975246533751488,
-0.03822661191225052,
-0.0338166318833828,
-0.07210420817136765,
-0.020058302208781242,
-0.01289462298154831,
0.005624250043183565,
0.0022443654015660286,
0.08868736773729324,
0.017396055161952972,
0.029081489890813828,
0.032475344836711884,
-0.06722681224346161,
-0.05121268704533577,
-0.0031474463175982237,
-0.005263525992631912,
0.0521475188434124,
-0.044303037226200104,
0.07791644334793091,
0.004206756129860878,
-0.015739772468805313,
0.02371635101735592,
-0.013504297472536564,
-0.007067147176712751,
0.004707197658717632,
0.035361140966415405,
-0.01554670836776495,
0.03375566378235817,
0.00853036716580391,
0.022679902613162994,
-0.06779584288597107,
-0.05263525992631912,
0.06255263835191727,
0.01867637224495411,
0.0061272322200238705,
-0.007737789768725634,
-0.033288244158029556,
0.0009449959616176784,
-0.0608861930668354,
0.031845349818468094,
0.00255809398368001,
-0.050481077283620834,
-0.034507595002651215,
-0.0017528150929138064,
-0.03347114846110344,
-0.0016766057815402746,
-0.013189299032092094,
-0.0030178904999047518,
0.008118836209177971,
0.05917910486459732,
-0.004028934519737959,
-0.031479544937610626,
0.010237456299364567,
0.04893656447529793,
0.02546408586204052,
0.03779983893036842,
-0.012386560440063477,
0.03562533110380173,
0.03958822041749954,
0.050806235522031784,
-0.03613339364528656,
-0.03499533608555794,
0.02249700017273426,
-0.007778434548527002,
0.05056236684322357,
0.04405916854739189,
0.046944960951805115,
0.011644789017736912,
0.035950493067502975,
-0.03590984642505646,
-0.019651852548122406,
-0.04881463199853897,
-0.038185965269804,
0.03019922599196434,
0.028878264129161835,
0.021196361631155014,
-0.02572827786207199,
-0.052838485687971115,
0.03292243927717209,
-0.006477795075625181,
0.02186700329184532,
0.02544376254081726,
-0.0036301054060459137,
-0.018950724974274635,
-0.05121268704533577,
0.02044442854821682,
0.0018544276244938374,
0.00657940749078989,
0.015170741826295853,
-0.019621368497610092,
0.02580956742167473,
0.016898153349757195,
0.0027155932039022446,
-0.013768489472568035,
-0.004879938904196024,
-0.03916144743561745,
0.041234340518713,
0.040705956518650055,
-0.02278151549398899,
0.046619802713394165,
-0.032739538699388504,
0.03168276697397232,
0.026805369183421135,
-0.02033265493810177,
0.03662113472819328,
0.0357879139482975,
0.026561500504612923,
0.041620466858148575,
-0.01981443166732788,
-0.014439132064580917,
0.0021960996091365814,
-0.00947028212249279,
-0.01894056424498558,
0.005238122772425413,
-0.026561500504612923,
0.020891524851322174,
-0.039242736995220184,
0.004882479086518288,
-0.05117204040288925,
-0.02985374443233013,
-0.040746599435806274,
0.014977678656578064,
-0.038043707609176636,
0.018777985125780106,
0.02188732661306858,
0.023452159017324448,
-0.012711720541119576,
0.0147846145555377,
-0.09779184311628342,
0.0030051888898015022,
-0.022131195291876793,
-0.026256661862134933,
-0.00717892125248909,
-0.008423673920333385,
-0.009617620147764683,
-0.021745068952441216,
0.04771721735596657,
-0.033003728836774826,
-0.12169109284877777,
-0.04324626922607422,
-0.01865604892373085,
0.015485740266740322,
-0.03473114222288132,
-0.0003902553871739656,
-0.02339119091629982,
-0.02572827786207199,
0.07181969285011292,
0.04995268955826759,
-0.05182236060500145,
0.06612939387559891,
-0.009536330588161945,
-0.047798506915569305,
-0.0018214035080745816,
0.01125866174697876,
0.08100546151399612,
0.053732674568891525,
-0.0787699893116951,
0.08189965039491653,
-0.007544726133346558,
0.026785047724843025,
-0.05808168649673462,
-0.0029340600594878197,
-0.03320695459842682,
0.02808568626642227,
0.001439086627215147,
-0.01407332718372345,
-0.00040105171501636505,
-0.002654625801369548,
0.04470948874950409,
0.013829457573592663,
-0.03619436174631119,
0.02688666060566902,
-0.008774236775934696,
0.05775652825832367,
-0.03188599273562431,
-0.02841084636747837,
0.018127664923667908,
0.03143889829516411,
-0.07771322131156921,
-0.008946978487074375,
0.043408848345279694,
0.0521475188434124,
-0.012762526050209999,
-0.005542960483580828,
0.022862805053591728,
-0.03255663439631462,
0.006025619339197874,
-0.044262390583753586,
0.056699760258197784,
0.054586220532655716,
-0.08933768421411514,
-0.004783406853675842,
0.017142023891210556,
0.00955665297806263,
-0.061170708388090134,
-0.019621368497610092,
-0.0604390986263752,
-0.014611872844398022,
0.04470948874950409,
-0.004437924828380346,
0.03751532360911369,
-0.017182668671011925,
0.02097281441092491,
0.027415044605731964,
0.025870535522699356,
0.0005213989643380046,
0.012183335609734058,
0.044546905905008316,
0.022131195291876793,
0.05987006798386574,
-0.01981443166732788,
-0.029813099652528763,
-0.034792110323905945,
-0.01920475624501705,
0.008560850284993649,
0.029772454872727394,
-0.04357142746448517,
-0.0005042518605478108,
0.022070229053497314,
0.03401985391974449,
0.03910047933459282,
0.004257562570273876,
-0.009134961292147636,
0.009592217393219471,
0.05072494596242905,
-0.009160364046692848,
-0.03842983767390251,
-0.08080223947763443,
0.008088353089988232,
0.019763626158237457,
0.0011215476552024484,
0.02668343484401703,
0.011949626728892326,
0.031012125313282013,
-0.010811567306518555,
-0.0029721646569669247,
-0.007138276007026434,
-0.012864138931035995,
-0.0011374246096238494,
0.05422041565179825,
-0.038998864591121674,
0.018706856295466423,
-0.027435367926955223,
0.019956689327955246,
-0.04060434177517891,
0.013341717422008514,
-0.010359391570091248,
-0.03977112099528313,
-0.016288479790091515,
0.02605343796312809,
0.020281849429011345,
-0.025240538641810417,
-0.07531516253948212,
-0.003932402469217777,
0.054952025413513184,
0.01201059389859438,
0.03812500089406967,
0.013240104541182518,
-0.06299973279237747,
-0.013219782151281834,
-0.018889758735895157,
0.007250049617141485,
-0.023005062714219093,
0.027435367926955223,
-0.022273452952504158,
0.021135393530130386,
-0.046619802713394165,
0.05633395537734032,
-0.033593084663152695,
-0.05031849443912506,
-0.0020728944800794125,
0.004384578205645084,
-0.013819295912981033,
0.002246905816718936,
-0.016613639891147614,
0.010567696765065193,
-0.033003728836774826,
0.023756995797157288,
-0.02188732661306858,
0.049017857760190964,
-0.003381154965609312,
-0.03462953120470047,
-0.04466884210705757,
0.046091414988040924,
0.06645455956459045,
0.011827691458165646,
0.028593748807907104,
0.024732476100325584,
0.012945428490638733,
-0.0508468821644783,
0.0078038377687335014,
-0.015394289046525955,
-0.01541461143642664,
-0.032780181616544724,
0.03497501090168953,
0.0053752996027469635,
-0.03235341235995293,
0.013219782151281834,
-0.047798506915569305,
0.06803970783948898,
-0.0031525269150733948,
0.07722547650337219,
-0.021135393530130386,
0.044262390583753586,
-0.013087686151266098,
-0.04025886207818985,
-0.01419526245445013,
0.03176405653357506,
0.008398271165788174,
0.04054337739944458,
-0.03574726730585098,
0.015069129876792431,
-0.011939465068280697,
0.022883128374814987,
0.02517957054078579,
0.00931786373257637,
0.03940531611442566,
-0.012803171761333942,
0.025362472981214523,
0.032414376735687256,
0.01804637536406517,
0.013240104541182518,
0.001782028703019023,
-0.010405116714537144,
0.018584920093417168,
-0.010801405645906925,
0.054057832807302475,
-0.09258928149938583,
0.09006929397583008,
-0.04147820919752121,
-0.03137793019413948,
-0.03188599273562431,
-0.045481741428375244,
-0.01610557734966278,
-0.004498891998082399,
-0.005111107137054205,
0.0033963967580348253,
-0.0018874516244977713,
-0.028553104028105736,
0.004676714073866606,
-0.04377465322613716,
0.00923149287700653,
-0.061089418828487396,
-0.051050104200839996,
-0.02550473064184189,
-0.07755063474178314,
-0.003012809669598937,
-0.0027994236443191767,
-0.014215584844350815,
-0.032089218497276306,
-0.010405116714537144,
-0.008515125140547752,
-0.05056236684322357,
0.016227511689066887,
-0.020302170887589455,
-0.006386343855410814,
-0.0008910143515095115,
0.03395888954401016,
0.003439582185819745,
-0.008078191429376602,
0.005934168118983507,
0.04296175390481949,
-0.05369202792644501,
-0.0006322200642898679,
0.01660347729921341,
0.012061400339007378,
-0.018412180244922638,
0.07779450714588165,
-0.03765758126974106,
0.02400086633861065,
0.006254247389733791,
-0.050806235522031784,
0.0835660994052887,
0.024082155898213387,
-0.000931024260353297,
-0.031479544937610626,
0.05531783029437065,
-0.028024720028042793,
-0.029691163450479507,
0.05466751009225845,
0.02664279006421566,
0.050196561962366104,
-0.04174240306019783,
0.014916710555553436,
0.04263659194111824,
0.001872209832072258,
-0.0008046437287703156,
0.006675939541310072,
-0.039242736995220184,
0.02186700329184532,
0.03174373507499695,
-0.04141724482178688,
-0.01708105579018593,
-0.06389392167329788,
0.02341151237487793,
-0.0005944329313933849,
-0.0298943892121315,
-0.019092982634902,
0.03546275198459625,
-0.015475579537451267,
0.023309901356697083,
0.027760526165366173,
0.028878264129161835,
-0.024508928880095482,
-0.0905570313334465,
-0.08303771167993546,
0.031845349818468094,
-0.015871867537498474,
-0.08023320883512497,
-0.04828624799847603,
0.008276335895061493,
0.08372867852449417,
0.0033024053554981947,
0.039547573775053024,
0.03133728727698326,
-0.015231708995997906,
-0.005100945942103863,
-0.03158115595579147,
0.022436033934354782,
-0.03113406151533127,
-0.08632995188236237,
-0.025281183421611786,
0.04861140623688698,
-0.0007347851642407477,
-0.0005677596782334149,
0.013666877523064613,
0.04194562882184982,
-0.02572827786207199,
0.026744402945041656,
-0.05092817172408104,
0.031804703176021576,
-0.03456856310367584,
-0.02517957054078579,
-0.05202558636665344,
-0.02033265493810177,
0.056130729615688324,
0.05633395537734032,
-0.0652352049946785,
0.02276119403541088,
0.03158115595579147,
-0.035401783883571625,
-0.057634592056274414,
-0.011837853118777275,
-0.024956023320555687,
-0.008789478801190853,
0.05987006798386574,
-0.06450359523296356,
-0.022415710613131523,
0.03412146866321564,
-0.01889991946518421,
-0.039242736995220184,
0.026805369183421135,
0.08958155661821365,
-0.03111373819410801,
0.07279517501592636,
-0.03428404778242111,
0.05092817172408104,
0.01554670836776495,
-0.03517823666334152,
0.07230743765830994,
0.00457764184102416,
0.04060434177517891,
0.021704424172639847,
0.001096779596991837,
0.003467525588348508,
-0.008022304624319077,
-0.08177771419286728,
-0.02725246548652649,
0.02515924721956253,
-0.02040378376841545,
0.016075093299150467,
-0.020200559869408607,
-0.04251465946435928,
0.052594613283872604,
-0.0017464642878621817,
0.009388992562890053,
0.029792776331305504,
0.026419242843985558,
0.015699125826358795,
-0.01937749795615673,
-0.03158115595579147,
0.007138276007026434,
0.021846681833267212,
0.0012809522449970245,
0.05117204040288925,
0.004435384180396795,
0.07673773914575577,
0.03755597025156021,
-0.06214618682861328,
-0.01229510921984911,
0.0031372851226478815,
-0.04438432678580284,
-0.0017947303131222725,
0.015922674909234047,
0.023187965154647827,
-0.014215584844350815,
-0.011309468187391758,
-0.05385461077094078,
-0.08035514503717422,
0.02310667559504509,
-0.016786379739642143,
-0.014530583284795284,
0.026561500504612923,
0.04596948251128197,
0.0072094048373401165,
0.025646988302469254,
-0.017558634281158447,
0.03590984642505646,
-0.03074793331325054,
-0.018869435414671898,
0.04771721735596657,
0.054342348128557205,
-0.057634592056274414,
-0.004542077425867319,
-0.0005220340681262314,
-0.05365138500928879,
-0.011126565746963024,
0.012427205219864845,
-0.004984091501682997,
-0.004288046155124903,
-0.001407332718372345,
0.027435367926955223,
-0.03542210906744003,
0.06661713868379593,
-0.053895253688097,
0.0027257546316832304,
0.06592617183923721,
0.053732674568891525,
0.03794209659099579,
-0.03485307842493057,
-0.042189497500658035,
0.012528818100690842,
0.07730676978826523,
-0.02367570623755455,
0.008698027580976486,
0.007681902963668108,
-0.005050139967352152,
0.035950493067502975,
-0.04674173519015312,
-0.046944960951805115,
-0.055236540734767914,
-0.028675038367509842,
-0.052838485687971115,
0.0752745196223259,
-0.04446561634540558,
-0.03133728727698326,
0.04702625051140785,
-0.03672274574637413,
0.06287779659032822,
0.043083686381578445,
-0.044221747666597366,
-0.037982743233442307,
0.015211386606097221,
-0.002781641436740756,
-0.08340351283550262,
0.022334421053528786,
0.10413245856761932,
-0.036824360489845276,
0.03639758750796318,
0.0608861930668354,
0.009922457858920097,
-0.017975246533751488,
0.002192289102822542,
-0.006716584321111441,
0.024346347898244858,
-0.05409847944974899,
-0.00998342502862215,
-0.008078191429376602,
0.016349446028470993,
0.062064897269010544,
-0.04621335119009018,
-0.003660589223727584,
0.0027943430468440056,
0.0004940906655974686,
-0.021806037053465843,
-0.01537396665662527,
-0.024468282237648964,
-0.059788778424263,
-0.019519755616784096,
-0.03934434801340103,
0.005344816017895937,
-0.0573907233774662,
0.00517715560272336,
-0.0038561932742595673,
0.05543976277112961,
-0.02371635101735592,
0.08080223947763443,
-0.02483408711850643,
-0.06551972031593323,
-0.03881596401333809,
-0.006889325566589832,
0.00793085340410471,
-0.02572827786207199,
-0.008276335895061493,
0.03997434675693512,
0.0025923880748450756,
-0.01049656793475151,
0.036255329847335815,
0.0078038377687335014,
-0.05068429931998253,
0.04373400658369064,
-0.03877531737089157,
-0.0197433028370142,
0.011787046678364277,
0.030910514295101166,
-0.0074024684727191925,
0.02162313461303711,
-0.032983407378196716,
-0.07080356776714325,
0.0549926683306694,
-0.0373120978474617,
-0.011461886577308178,
0.025667309761047363,
0.02192797139286995,
0.0008783127996139228,
0.02633795328438282,
-0.03885661065578461,
0.04796108603477478,
-0.000668737047817558,
0.039242736995220184,
0.021074427291750908,
0.026297306641936302,
-0.018259761855006218,
0.026520855724811554,
-0.04174240306019783,
0.05243203416466713,
0.001707089482806623,
0.05096881464123726,
-0.057593949139118195,
-0.009531250223517418,
-0.0034954689908772707,
0.044018521904945374,
0.032983407378196716,
-0.04389658570289612,
0.012213818728923798,
0.04283981770277023,
-0.014804936945438385,
-0.0781196653842926,
-0.011329790577292442,
-0.028553104028105736,
0.032089218497276306,
0.09657249599695206,
-0.0064981174655258656,
-0.01094366330653429,
-0.04003531485795975,
0.022293776273727417,
0.010054553858935833,
0.051090750843286514,
-0.011553337797522545,
-0.042799171060323715,
-0.054057832807302475,
0.033654049038887024,
0.015810901299118996,
0.019692497327923775,
0.01911330595612526,
0.010791243985295296,
0.008875849656760693,
-0.030727611854672432,
-0.016064932569861412,
0.03399953246116638,
0.01316897664219141,
-0.0061627961695194244,
0.01196994911879301,
0.02786213904619217,
0.02698827162384987,
-0.02103378064930439,
0.08092416822910309,
0.03416211158037186,
-0.02400086633861065,
-0.015831222757697105,
-0.023289578035473824,
0.0028705522418022156,
0.06421907991170883,
0.018889758735895157,
-0.009160364046692848,
-0.021806037053465843,
0.04889592155814171,
-0.03501565754413605,
-0.018777985125780106,
-0.0034268805757164955,
-0.03050406463444233,
0.04718882963061333,
0.043977878987789154,
-0.03192663937807083,
0.026236340403556824,
0.0586913637816906,
-0.0147846145555377,
0.05800039693713188,
-0.0056852176785469055,
-0.024143123999238014,
-0.010842050425708294,
0.04629464074969292,
0.005974813364446163,
0.02249700017273426,
0.03572694584727287,
0.02398054301738739,
-0.034832753241062164,
0.03158115595579147,
-0.040462084114551544,
-0.04857075959444046,
0.010074876248836517,
-0.050521720200777054,
-0.01554670836776495,
0.026764724403619766,
-0.032089218497276306,
0.0026673274114727974,
0.051984939724206924,
0.01407332718372345,
-0.02580956742167473,
0.037454355508089066,
-0.038287580013275146,
0.0021478335838764906,
0.025037312880158424,
-0.016268156468868256,
0.003076317487284541,
-0.04966817423701286,
-0.0011748941615223885,
0.0004607490554917604,
0.016227511689066887,
-0.00994786061346531,
-0.038328222930431366,
-0.08413512259721756,
-0.01957056112587452,
0.035665977746248245,
0.08043643087148666,
0.026175372302532196,
0.03847048059105873,
0.0286953616887331,
0.05275719612836838
]
|
32,037 | pingouin.correlation | pcorr | Partial correlation matrix (:py:class:`pandas.DataFrame` method).
Returns
-------
pcormat : :py:class:`pandas.DataFrame`
Partial correlation matrix.
Notes
-----
This function calculates the pairwise partial correlations for each pair of
variables in a :py:class:`pandas.DataFrame` given all the others. It has
the same behavior as the pcor function in the
`ppcor <https://cran.r-project.org/web/packages/ppcor/index.html>`_
R package.
Note that this function only returns the raw Pearson correlation
coefficient. If you want to calculate the test statistic and p-values, or
use more robust estimates of the correlation coefficient, please refer to
the :py:func:`pingouin.pairwise_corr` or :py:func:`pingouin.partial_corr`
functions.
Examples
--------
>>> import pingouin as pg
>>> data = pg.read_dataset('mediation')
>>> data.pcorr().round(3)
X M Y Mbin Ybin W1 W2
X 1.000 0.359 0.074 -0.019 -0.147 -0.148 -0.067
M 0.359 1.000 0.555 -0.024 -0.112 -0.138 -0.176
Y 0.074 0.555 1.000 -0.001 0.169 0.101 0.108
Mbin -0.019 -0.024 -0.001 1.000 -0.080 -0.032 -0.040
Ybin -0.147 -0.112 0.169 -0.080 1.000 -0.000 -0.140
W1 -0.148 -0.138 0.101 -0.032 -0.000 1.000 -0.394
W2 -0.067 -0.176 0.108 -0.040 -0.140 -0.394 1.000
On a subset of columns
>>> data[['X', 'Y', 'M']].pcorr()
X Y M
X 1.000000 0.036649 0.412804
Y 0.036649 1.000000 0.540140
M 0.412804 0.540140 1.000000
| @pf.register_dataframe_method
def pcorr(self):
"""Partial correlation matrix (:py:class:`pandas.DataFrame` method).
Returns
-------
pcormat : :py:class:`pandas.DataFrame`
Partial correlation matrix.
Notes
-----
This function calculates the pairwise partial correlations for each pair of
variables in a :py:class:`pandas.DataFrame` given all the others. It has
the same behavior as the pcor function in the
`ppcor <https://cran.r-project.org/web/packages/ppcor/index.html>`_
R package.
Note that this function only returns the raw Pearson correlation
coefficient. If you want to calculate the test statistic and p-values, or
use more robust estimates of the correlation coefficient, please refer to
the :py:func:`pingouin.pairwise_corr` or :py:func:`pingouin.partial_corr`
functions.
Examples
--------
>>> import pingouin as pg
>>> data = pg.read_dataset('mediation')
>>> data.pcorr().round(3)
X M Y Mbin Ybin W1 W2
X 1.000 0.359 0.074 -0.019 -0.147 -0.148 -0.067
M 0.359 1.000 0.555 -0.024 -0.112 -0.138 -0.176
Y 0.074 0.555 1.000 -0.001 0.169 0.101 0.108
Mbin -0.019 -0.024 -0.001 1.000 -0.080 -0.032 -0.040
Ybin -0.147 -0.112 0.169 -0.080 1.000 -0.000 -0.140
W1 -0.148 -0.138 0.101 -0.032 -0.000 1.000 -0.394
W2 -0.067 -0.176 0.108 -0.040 -0.140 -0.394 1.000
On a subset of columns
>>> data[['X', 'Y', 'M']].pcorr()
X Y M
X 1.000000 0.036649 0.412804
Y 0.036649 1.000000 0.540140
M 0.412804 0.540140 1.000000
"""
V = self.cov(numeric_only=True) # Covariance matrix
Vi = np.linalg.pinv(V, hermitian=True) # Inverse covariance matrix
D = np.diag(np.sqrt(1 / np.diag(Vi)))
pcor = -1 * (D @ Vi @ D) # Partial correlation matrix
pcor[np.diag_indices_from(pcor)] = 1
return pd.DataFrame(pcor, index=V.index, columns=V.columns)
| (self) | [
-0.01969759911298752,
-0.02637634426355362,
0.04624326527118683,
-0.013573846779763699,
0.0034451985266059637,
-0.01964115910232067,
0.029932072386145592,
0.004242415074259043,
0.052790317684412,
0.001348683494143188,
0.009223254397511482,
-0.0023693088442087173,
0.008113265968859196,
0.045264970511198044,
-0.04515208676457405,
-0.017571687698364258,
-0.0037908940576016903,
-0.04090026766061783,
-0.019358957186341286,
-0.02340383268892765,
0.031606461852788925,
0.04436192661523819,
0.018390068784356117,
0.019603531807661057,
-0.018822776153683662,
0.008748217485845089,
-0.0515110082924366,
-0.021259108558297157,
0.028464628383517265,
0.005949728190898895,
0.009256178513169289,
0.01531408354640007,
-0.011128108017146587,
0.012567331083118916,
-0.00966066587716341,
-0.014599175192415714,
0.05373098701238632,
-0.03768318146467209,
-0.03307390585541725,
0.018361849710345268,
-0.013555033132433891,
-0.04233008250594139,
-0.03621573746204376,
-0.02607533149421215,
-0.020073866471648216,
-0.015972550958395004,
0.0037767840549349785,
0.06693796813488007,
0.02174825593829155,
0.006763406563550234,
0.03785249963402748,
0.004407031927257776,
-0.043383631855249405,
-0.019772851839661598,
-0.005761594511568546,
0.049516789615154266,
0.0011799510102719069,
0.05873534083366394,
0.024043487384915352,
-0.0020106788724660873,
-0.010977601632475853,
-0.007163190748542547,
-0.021296735852956772,
-0.0033040980342775583,
0.05324183776974678,
-0.05677875131368637,
0.03768318146467209,
-0.00110410968773067,
0.021879948675632477,
-0.038830794394016266,
-0.02961224503815174,
0.015285863541066647,
-0.0030995027627795935,
0.04635614529252052,
0.011645476333796978,
-0.042668722569942474,
-0.0034240332897752523,
-0.0455283559858799,
0.030741047114133835,
0.025379236787557602,
-0.051473379135131836,
-0.023385019972920418,
-0.015577470883727074,
-0.024777209386229515,
-0.015558657236397266,
-0.04458768665790558,
0.023347392678260803,
0.019848106428980827,
0.050908979028463364,
-0.0013404525816440582,
-0.0024104630574584007,
0.02780616097152233,
0.024758394807577133,
0.010902347974479198,
0.01642407290637493,
-0.021296735852956772,
0.01716719940304756,
0.0821768045425415,
0.03578303009271622,
0.003628628794103861,
-0.05497266724705696,
0.0741623044013977,
0.028389375656843185,
0.0488395094871521,
0.055236056447029114,
0.04466294124722481,
0.004169513005763292,
0.019979799166321754,
-0.03824758157134056,
-0.029875632375478745,
-0.049667298793792725,
-0.00039096534601412714,
0.035444390028715134,
-0.04176568239927292,
0.03570777550339699,
-0.038906048983335495,
-0.0554618164896965,
0.0220680832862854,
-0.02120266854763031,
0.025228729471564293,
0.02011149190366268,
0.02976275235414505,
0.02472076751291752,
-0.07435043901205063,
-0.057042136788368225,
0.024081114679574966,
0.020544201135635376,
-0.028408188372850418,
-0.026921933516860008,
0.008842283859848976,
0.010262693278491497,
0.016790932044386864,
0.011513782665133476,
0.024701954796910286,
-0.03218967467546463,
-0.0007131443126127124,
0.062084123492240906,
-0.05237642303109169,
0.026244651526212692,
0.0011229229858145118,
0.007158487569540739,
0.04090026766061783,
0.0152294235303998,
0.0555746965110302,
0.021466055884957314,
0.0562143512070179,
0.058208566159009933,
0.01796676777303219,
-0.010591926984488964,
-0.02419399470090866,
-0.010102779604494572,
-0.055236056447029114,
0.03802182152867317,
-0.011795982718467712,
0.0360652320086956,
-0.03252831846475601,
0.015803230926394463,
-0.03847334161400795,
-0.03060935251414776,
-0.05564994737505913,
0.0025539149064570665,
-0.03352542594075203,
-0.01578441821038723,
0.02402467280626297,
-0.007167893927544355,
-0.005037279799580574,
0.04067450761795044,
-0.10053864866495132,
0.008640040643513203,
-0.03416508063673973,
0.011156328953802586,
-0.005037279799580574,
0.018540576100349426,
-0.006683449726551771,
-0.0061049386858940125,
0.058622460812330246,
-0.011382088996469975,
-0.04748494550585747,
-0.0501188188791275,
-0.04052399843931198,
0.03250950202345848,
-0.009322024881839752,
-0.021296735852956772,
0.002772620413452387,
0.006556459702551365,
0.06020278483629227,
0.03173815459012985,
-0.047146305441856384,
0.026037704199552536,
0.009707698598504066,
-0.07773684710264206,
0.0039461045525968075,
0.015191796235740185,
0.0721304640173912,
0.041652802377939224,
-0.06987285614013672,
0.03736335411667824,
-0.010432013310492039,
-0.0012381549458950758,
-0.02238791063427925,
0.024306874722242355,
-0.03171934187412262,
0.02088284119963646,
0.0401853583753109,
0.0026809051632881165,
-0.011005821637809277,
-0.02009267918765545,
0.059638384729623795,
-0.011937083676457405,
-0.032641198486089706,
0.07751108705997467,
-0.04635614529252052,
0.07246910035610199,
-0.03935756906867027,
-0.02543567679822445,
0.041577547788619995,
0.01595373824238777,
-0.07514060288667679,
-0.033487800508737564,
0.03958332911133766,
0.0803707167506218,
0.00441643875092268,
-0.05967601016163826,
0.03218967467546463,
-0.021578935906291008,
0.011551409028470516,
-0.039997223764657974,
0.00914329756051302,
0.029480550438165665,
-0.03173815459012985,
-0.005484097637236118,
-0.018813369795680046,
-0.04116365313529968,
-0.06539527326822281,
-0.04985542967915535,
-0.03416508063673973,
-0.01347037311643362,
0.05967601016163826,
-0.04052399843931198,
0.024382127448916435,
-0.012125217355787754,
0.036403872072696686,
0.05361810326576233,
0.03802182152867317,
0.008357839658856392,
-0.03567015007138252,
0.024363314732909203,
-0.007788735441863537,
0.062234628945589066,
0.0422172024846077,
-0.01189945638179779,
-0.053279463201761246,
-0.01433578785508871,
0.003050117753446102,
0.047296810895204544,
-0.02600007690489292,
-0.014683835208415985,
0.030327152460813522,
0.03234018385410309,
0.03683657944202423,
-0.01429816149175167,
-0.03582065552473068,
0.05260218307375908,
-0.00009296450298279524,
0.013837234117090702,
-0.038266394287347794,
-0.059073980897665024,
-0.004929102957248688,
0.0059685418382287025,
0.022557230666279793,
-0.048500869423151016,
-0.00549820763990283,
0.005361810326576233,
0.001969524659216404,
0.006288369186222553,
-0.012294537387788296,
-0.009491344913840294,
0.007581788115203381,
0.002833763835951686,
-0.029085470363497734,
0.03939519822597504,
-0.021183853968977928,
0.00993345957249403,
-0.05636485666036606,
-0.003750915639102459,
0.018813369795680046,
-0.00357218855060637,
0.0137055404484272,
0.031230194494128227,
-0.009670072235167027,
-0.013103512115776539,
-0.03416508063673973,
-0.019217858090996742,
0.015605690889060497,
0.022275030612945557,
0.024212807416915894,
0.01342333946377039,
-0.05873534083366394,
-0.0304588470607996,
-0.027618028223514557,
-0.00947723537683487,
-0.025793131440877914,
0.006805736571550369,
0.026432784274220467,
0.018390068784356117,
0.029725125059485435,
0.022180963307619095,
-0.03392050787806511,
-0.025228729471564293,
-0.010554300621151924,
0.003134777769446373,
0.04586699604988098,
-0.026809051632881165,
-0.0072196307592093945,
0.02182350866496563,
-0.002504529897123575,
0.016264159232378006,
0.003623925382271409,
0.0501188188791275,
0.01575619727373123,
-0.05395674705505371,
-0.040486373007297516,
0.04545310139656067,
0.06445460766553879,
0.03939519822597504,
0.044098541140556335,
-0.0016908516408875585,
-0.01806083507835865,
-0.012896565720438957,
-0.02152249589562416,
-0.012736652046442032,
0.013282239437103271,
-0.01044142059981823,
0.02058182656764984,
0.041201282292604446,
-0.032622385770082474,
0.013968927785754204,
-0.03337492048740387,
0.0328105166554451,
-0.007722888607531786,
0.068292535841465,
-0.05828382074832916,
0.03100443445146084,
-0.03360068053007126,
-0.02600007690489292,
0.0029184240847826004,
-0.007332511246204376,
0.05918686091899872,
0.0005064912256784737,
-0.052263543009757996,
0.01964115910232067,
0.0030383593402802944,
0.01783507503569126,
0.038360461592674255,
0.027618028223514557,
0.03747623413801193,
-0.010667180642485619,
0.05102185904979706,
0.0034828251227736473,
0.029781565070152283,
0.07100165635347366,
0.0011711323168128729,
0.04575411602854729,
-0.015916110947728157,
-0.007073827087879181,
0.046694785356521606,
-0.06761525571346283,
0.059788890182971954,
-0.04530259594321251,
-0.013752573169767857,
-0.02419399470090866,
-0.02150368131697178,
-0.02385535277426243,
-0.0401853583753109,
-0.0017602259758859873,
0.012181657366454601,
-0.05237642303109169,
-0.003727399045601487,
-0.007229037582874298,
-0.03604641556739807,
0.028690390288829803,
-0.05850958079099655,
0.0016250048065558076,
-0.014919002540409565,
-0.035444390028715134,
-0.012463857419788837,
0.013131732121109962,
-0.0005685165524482727,
-0.036949459463357925,
-0.0034804735332727432,
-0.04710868000984192,
-0.016508731991052628,
-0.045415475964546204,
-0.01746821403503418,
-0.01457095518708229,
-0.03190747648477554,
0.006631712894886732,
0.032471876591444016,
-0.004957322962582111,
-0.030985619872808456,
0.04011010378599167,
-0.06641119718551636,
0.006316589191555977,
0.000612022471614182,
-0.027222946286201477,
-0.02583075687289238,
0.0381535142660141,
-0.057907555252313614,
0.029254790395498276,
0.004505801945924759,
-0.04304499179124832,
0.09278754144906998,
0.07562974840402603,
0.007473611272871494,
0.003064227756112814,
0.0321144238114357,
-0.021146228536963463,
-0.04455006122589111,
0.047936465591192245,
0.04624326527118683,
0.07066302001476288,
-0.0327540785074234,
0.031380701810121536,
0.016170091927051544,
0.003638035384938121,
-0.024212807416915894,
0.002352847019210458,
-0.007087937090545893,
0.005206600297242403,
0.050758473575115204,
-0.041803307831287384,
-0.00006867614865768701,
-0.06844303756952286,
0.03651675209403038,
0.009914645925164223,
-0.028125988319516182,
-0.019434211775660515,
0.05489741265773773,
-0.02088284119963646,
0.03958332911133766,
0.05478453263640404,
-0.009354948066174984,
-0.016339411959052086,
-0.09052994102239609,
-0.05267743766307831,
-0.0006996222073212266,
-0.007807548623532057,
-0.06110582500696182,
-0.06234750896692276,
-0.003245306434109807,
0.09459362179040909,
0.04906526952981949,
0.06738949567079544,
-0.005592274479568005,
0.013489186763763428,
0.03151239454746246,
-0.01833362877368927,
-0.005333590321242809,
-0.053580477833747864,
-0.029875632375478745,
-0.010742434300482273,
0.04097551852464676,
0.0030454143416136503,
-0.025567369535565376,
0.011711322702467442,
0.01924607716500759,
-0.03365711867809296,
0.00037744324072264135,
-0.0641159638762474,
0.04451243206858635,
0.010780060663819313,
-0.05331709235906601,
-0.05832144618034363,
-0.03365711867809296,
0.03491761535406113,
0.03679895028471947,
-0.0936153307557106,
0.023911792784929276,
0.0005320656346157193,
-0.031042061746120453,
-0.0849611833691597,
-0.01047904696315527,
0.014279347844421864,
0.0007190235191956162,
0.023290952667593956,
-0.058772969990968704,
0.005032576620578766,
0.03126782178878784,
-0.01743999496102333,
-0.068179652094841,
0.05899873003363609,
0.09271229058504105,
-0.025943636894226074,
0.02976275235414505,
-0.03708115220069885,
0.04451243206858635,
0.04530259594321251,
-0.04097551852464676,
0.0200362391769886,
-0.0036027603782713413,
0.01825837604701519,
0.02645159885287285,
-0.00997108593583107,
-0.010921161621809006,
0.0277873482555151,
-0.07788735628128052,
0.0032076796051114798,
0.04383515194058418,
-0.026658546179533005,
-0.011231581680476665,
-0.032471876591444016,
-0.06242276355624199,
-0.01044142059981823,
0.001346331788226962,
-0.006518832873553038,
0.026508038863539696,
0.010300320573151112,
0.031455956399440765,
-0.03149358183145523,
-0.03935756906867027,
0.038755543529987335,
-0.004465823527425528,
-0.014947222545742989,
0.0662606880068779,
-0.04394803196191788,
0.068179652094841,
0.02472076751291752,
-0.04131416231393814,
-0.026338718831539154,
0.0009988723322749138,
-0.03666725754737854,
-0.009533675387501717,
0.010620147921144962,
0.03038359247148037,
0.005084313452243805,
0.02063826657831669,
-0.052414048463106155,
-0.05324183776974678,
0.026131771504878998,
0.008268476463854313,
-0.010704807937145233,
0.00749712809920311,
0.03273526579141617,
-0.015003662556409836,
0.03433439880609512,
-0.012699024751782417,
-0.012492077425122261,
-0.030214272439479828,
0.029330044984817505,
0.04737206548452377,
0.051623888313770294,
-0.05188727378845215,
0.0023175720125436783,
0.01754346862435341,
-0.01850294880568981,
0.05026932433247566,
0.05143575370311737,
-0.015220016241073608,
-0.002582135144621134,
-0.012209877371788025,
0.006645822897553444,
-0.07705956697463989,
0.07461382448673248,
-0.05527368187904358,
-0.05124761909246445,
0.06787864118814468,
0.015972550958395004,
0.05113473907113075,
-0.07525347918272018,
-0.056816376745700836,
0.019340144470334053,
0.0327540785074234,
-0.03995959833264351,
-0.03171934187412262,
0.03179459646344185,
-0.002525694901123643,
0.02919835038483143,
-0.02874683029949665,
-0.029875632375478745,
-0.031437139958143234,
-0.04014773294329643,
-0.016367632895708084,
0.04564123600721359,
-0.040561627596616745,
-0.0761941522359848,
0.006217818707227707,
-0.06012753024697304,
0.012811904773116112,
0.09609869122505188,
-0.05369335785508156,
-0.05433301255106926,
-0.03250950202345848,
0.001353386789560318,
-0.06125633418560028,
0.03572658821940422,
0.07197995483875275,
-0.07100165635347366,
0.01126920897513628,
0.06148209422826767,
0.006777516566216946,
-0.027147693559527397,
0.03015783242881298,
0.0028619838412851095,
-0.025172289460897446,
-0.034428466111421585,
-0.051548633724451065,
-0.0012593199498951435,
0.040636878460645676,
0.0595255047082901,
-0.010930567979812622,
-0.008113265968859196,
0.006904507055878639,
-0.0028525772504508495,
-0.00022046918456908315,
0.014542735181748867,
-0.04917814955115318,
-0.08375712484121323,
-0.01806083507835865,
-0.015398743562400341,
-0.01986691914498806,
-0.0360652320086956,
-0.01139149535447359,
0.0005126643227413297,
0.034974053502082825,
-0.04710868000984192,
0.06603492796421051,
0.006636416539549828,
-0.04067450761795044,
-0.01734592765569687,
-0.0013381009921431541,
0.048500869423151016,
-0.010977601632475853,
0.0277873482555151,
-0.01118454895913601,
-0.0013663209974765778,
-0.046694785356521606,
-0.0016884999349713326,
0.0013663209974765778,
-0.029950885102152824,
0.03375118598341942,
0.008466016501188278,
-0.027373453602194786,
0.016235938295722008,
-0.02959343045949936,
-0.024833649396896362,
-0.007586491759866476,
-0.035218629986047745,
-0.06930845230817795,
0.05166151374578476,
-0.07991919666528702,
0.00220821937546134,
-0.0070314970798790455,
0.0029231274966150522,
0.0017578742699697614,
0.028163615614175797,
-0.06313767284154892,
0.040335867553949356,
0.026997186243534088,
0.02519110217690468,
0.007525348104536533,
0.02402467280626297,
-0.040937893092632294,
0.03471066802740097,
-0.05064559355378151,
0.0494791641831398,
0.005996761843562126,
0.03886842355132103,
-0.006659932900220156,
-0.009195034392178059,
0.0277873482555151,
0.07559212297201157,
0.07356027513742447,
-0.08255306631326675,
-0.0015685647958889604,
0.04782358556985855,
-0.0009647731203585863,
-0.053128957748413086,
-0.06761525571346283,
-0.04067450761795044,
0.028332935646176338,
0.06720136106014252,
0.02135317586362362,
-0.012398011051118374,
0.007130267098546028,
0.000275439495453611,
0.006349512375891209,
0.10114067792892456,
-0.0177410077303648,
-0.03700589761137962,
-0.08782081305980682,
0.032641198486089706,
-0.006932727061212063,
0.03886842355132103,
0.029160723090171814,
0.01296241208910942,
0.06257326900959015,
-0.03728809952735901,
-0.0675399973988533,
0.01912379078567028,
0.023347392678260803,
-0.01602899096906185,
0.007972165942192078,
0.02065708115696907,
0.055010292679071426,
-0.016941439360380173,
0.0501188188791275,
0.056251976639032364,
0.014373415149748325,
0.009942865930497646,
-0.005808628164231777,
-0.01986691914498806,
0.07743582874536514,
0.03621573746204376,
-0.013178765773773193,
0.017251860350370407,
0.026508038863539696,
-0.03538794815540314,
0.02332857996225357,
0.04575411602854729,
-0.05452114716172218,
0.03719403222203255,
0.03194510191679001,
-0.03055291250348091,
0.017684567719697952,
0.03832283616065979,
0.0022964070085436106,
0.034202706068754196,
0.007685261778533459,
-0.0200362391769886,
-0.021654188632965088,
0.026639731600880623,
-0.03629099205136299,
0.03871791437268257,
0.019998611882328987,
0.017656348645687103,
-0.01825837604701519,
0.0354820154607296,
-0.02387416735291481,
-0.019104978069663048,
0.00965125858783722,
-0.06366444379091263,
0.009792359545826912,
0.05606384202837944,
-0.001475673750974238,
0.007017387077212334,
0.03023308515548706,
0.008729403838515282,
-0.004367053508758545,
0.04816222935914993,
-0.029386484995484352,
0.01213462371379137,
0.011720729991793633,
-0.01362088043242693,
-0.022594857960939407,
-0.0434965118765831,
-0.004849146120250225,
0.00390847772359848,
-0.006151971872895956,
-0.020243186503648758,
-0.03604641556739807,
-0.09466888010501862,
0.008776437491178513,
-0.0006796329980716109,
0.07736057788133621,
0.019434211775660515,
0.04481344670057297,
0.02419399470090866,
0.06505663692951202
]
|
32,038 | pingouin.plotting | plot_blandaltman |
Generate a Bland-Altman plot to compare two sets of measurements.
Parameters
----------
x, y : pd.Series, np.array, or list
First and second measurements.
agreement : float
Multiple of the standard deviation to plot agreement limits.
The defaults is 1.96, which corresponds to 95% confidence interval if
the differences are normally distributed.
xaxis : str
Define which measurements should be used as the reference (x-axis).
Default is to use the average of x and y ("mean"). Accepted values are
"mean", "x" or "y".
confidence : float
If not None, plot the specified percentage confidence interval of
the mean and limits of agreement. The CIs of the mean difference and
agreement limits describe a possible error in the
estimate due to a sampling error. The greater the sample size,
the narrower the CIs will be.
annotate : bool
If True (default), annotate the values for the mean difference
and agreement limits.
ax : matplotlib axes
Axis on which to draw the plot.
**kwargs : optional
Optional argument(s) passed to :py:func:`matplotlib.pyplot.scatter`.
Returns
-------
ax : Matplotlib Axes instance
Returns the Axes object with the plot for further tweaking.
Notes
-----
Bland-Altman plots [1]_ are extensively used to evaluate the agreement
among two different instruments or two measurements techniques.
They allow identification of any systematic difference between the
measurements (i.e., fixed bias) or possible outliers.
The mean difference (= x - y) is the estimated bias, and the SD of the
differences measures the random fluctuations around this mean.
If the mean value of the difference differs significantly from 0 on the
basis of a 1-sample t-test, this indicates the presence of fixed bias.
If there is a consistent bias, it can be adjusted for by subtracting the
mean difference from the new method.
It is common to compute 95% limits of agreement for each comparison
(average difference ± 1.96 standard deviation of the difference), which
tells us how far apart measurements by 2 methods were more likely to be
for most individuals. If the differences within mean ± 1.96 SD are not
clinically important, the two methods may be used interchangeably.
The 95% limits of agreement can be unreliable estimates of the population
parameters especially for small sample sizes so, when comparing methods
or assessing repeatability, it is important to calculate confidence
intervals for the 95% limits of agreement.
The code is an adaptation of the
`PyCompare <https://github.com/jaketmp/pyCompare>`_ package. The present
implementation is a simplified version; please refer to the original
package for more advanced functionalities.
References
----------
.. [1] Bland, J. M., & Altman, D. (1986). Statistical methods for assessing
agreement between two methods of clinical measurement. The lancet,
327(8476), 307-310.
.. [2] Giavarina, D. (2015). Understanding bland altman analysis.
Biochemia medica, 25(2), 141-151.
Examples
--------
Bland-Altman plot (example data from [2]_)
.. plot::
>>> import pingouin as pg
>>> df = pg.read_dataset("blandaltman")
>>> ax = pg.plot_blandaltman(df['A'], df['B'])
>>> plt.tight_layout()
| def plot_blandaltman(
x, y, agreement=1.96, xaxis="mean", confidence=0.95, annotate=True, ax=None, **kwargs
):
"""
Generate a Bland-Altman plot to compare two sets of measurements.
Parameters
----------
x, y : pd.Series, np.array, or list
First and second measurements.
agreement : float
Multiple of the standard deviation to plot agreement limits.
The defaults is 1.96, which corresponds to 95% confidence interval if
the differences are normally distributed.
xaxis : str
Define which measurements should be used as the reference (x-axis).
Default is to use the average of x and y ("mean"). Accepted values are
"mean", "x" or "y".
confidence : float
If not None, plot the specified percentage confidence interval of
the mean and limits of agreement. The CIs of the mean difference and
agreement limits describe a possible error in the
estimate due to a sampling error. The greater the sample size,
the narrower the CIs will be.
annotate : bool
If True (default), annotate the values for the mean difference
and agreement limits.
ax : matplotlib axes
Axis on which to draw the plot.
**kwargs : optional
Optional argument(s) passed to :py:func:`matplotlib.pyplot.scatter`.
Returns
-------
ax : Matplotlib Axes instance
Returns the Axes object with the plot for further tweaking.
Notes
-----
Bland-Altman plots [1]_ are extensively used to evaluate the agreement
among two different instruments or two measurements techniques.
They allow identification of any systematic difference between the
measurements (i.e., fixed bias) or possible outliers.
The mean difference (= x - y) is the estimated bias, and the SD of the
differences measures the random fluctuations around this mean.
If the mean value of the difference differs significantly from 0 on the
basis of a 1-sample t-test, this indicates the presence of fixed bias.
If there is a consistent bias, it can be adjusted for by subtracting the
mean difference from the new method.
It is common to compute 95% limits of agreement for each comparison
(average difference ± 1.96 standard deviation of the difference), which
tells us how far apart measurements by 2 methods were more likely to be
for most individuals. If the differences within mean ± 1.96 SD are not
clinically important, the two methods may be used interchangeably.
The 95% limits of agreement can be unreliable estimates of the population
parameters especially for small sample sizes so, when comparing methods
or assessing repeatability, it is important to calculate confidence
intervals for the 95% limits of agreement.
The code is an adaptation of the
`PyCompare <https://github.com/jaketmp/pyCompare>`_ package. The present
implementation is a simplified version; please refer to the original
package for more advanced functionalities.
References
----------
.. [1] Bland, J. M., & Altman, D. (1986). Statistical methods for assessing
agreement between two methods of clinical measurement. The lancet,
327(8476), 307-310.
.. [2] Giavarina, D. (2015). Understanding bland altman analysis.
Biochemia medica, 25(2), 141-151.
Examples
--------
Bland-Altman plot (example data from [2]_)
.. plot::
>>> import pingouin as pg
>>> df = pg.read_dataset("blandaltman")
>>> ax = pg.plot_blandaltman(df['A'], df['B'])
>>> plt.tight_layout()
"""
# Safety check
assert xaxis in ["mean", "x", "y"]
# Get names before converting to NumPy array
xname = x.name if isinstance(x, pd.Series) else "x"
yname = y.name if isinstance(y, pd.Series) else "y"
x = np.asarray(x)
y = np.asarray(y)
assert x.ndim == 1 and y.ndim == 1
assert x.size == y.size
assert not np.isnan(x).any(), "Missing values in x or y are not supported."
assert not np.isnan(y).any(), "Missing values in x or y are not supported."
# Update default kwargs with specified inputs
_scatter_kwargs = {"color": "tab:blue", "alpha": 0.8}
_scatter_kwargs.update(kwargs)
# Calculate mean, STD and SEM of x - y
n = x.size
dof = n - 1
diff = x - y
mean_diff = np.mean(diff)
std_diff = np.std(diff, ddof=1)
mean_diff_se = np.sqrt(std_diff**2 / n)
# Limits of agreements
high = mean_diff + agreement * std_diff
low = mean_diff - agreement * std_diff
high_low_se = np.sqrt(3 * std_diff**2 / n)
# Define x-axis
if xaxis == "mean":
xval = np.vstack((x, y)).mean(0)
xlabel = f"Mean of {xname} and {yname}"
elif xaxis == "x":
xval = x
xlabel = xname
else:
xval = y
xlabel = yname
# Start the plot
if ax is None:
ax = plt.gca()
# Plot the mean diff, limits of agreement and scatter
ax.scatter(xval, diff, **_scatter_kwargs)
ax.axhline(mean_diff, color="k", linestyle="-", lw=2)
ax.axhline(high, color="k", linestyle=":", lw=1.5)
ax.axhline(low, color="k", linestyle=":", lw=1.5)
# Annotate values
if annotate:
loa_range = high - low
offset = (loa_range / 100.0) * 1.5
trans = transforms.blended_transform_factory(ax.transAxes, ax.transData)
xloc = 0.98
ax.text(xloc, mean_diff + offset, "Mean", ha="right", va="bottom", transform=trans)
ax.text(xloc, mean_diff - offset, "%.2f" % mean_diff, ha="right", va="top", transform=trans)
ax.text(
xloc, high + offset, "+%.2f SD" % agreement, ha="right", va="bottom", transform=trans
)
ax.text(xloc, high - offset, "%.2f" % high, ha="right", va="top", transform=trans)
ax.text(xloc, low - offset, "-%.2f SD" % agreement, ha="right", va="top", transform=trans)
ax.text(xloc, low + offset, "%.2f" % low, ha="right", va="bottom", transform=trans)
# Add 95% confidence intervals for mean bias and limits of agreement
if confidence is not None:
assert 0 < confidence < 1
ci = dict()
ci["mean"] = stats.t.interval(confidence, dof, loc=mean_diff, scale=mean_diff_se)
ci["high"] = stats.t.interval(confidence, dof, loc=high, scale=high_low_se)
ci["low"] = stats.t.interval(confidence, dof, loc=low, scale=high_low_se)
ax.axhspan(ci["mean"][0], ci["mean"][1], facecolor="tab:grey", alpha=0.2)
ax.axhspan(ci["high"][0], ci["high"][1], facecolor=_scatter_kwargs["color"], alpha=0.2)
ax.axhspan(ci["low"][0], ci["low"][1], facecolor=_scatter_kwargs["color"], alpha=0.2)
# Labels
ax.set_ylabel(f"{xname} - {yname}")
ax.set_xlabel(xlabel)
sns.despine(ax=ax)
return ax
| (x, y, agreement=1.96, xaxis='mean', confidence=0.95, annotate=True, ax=None, **kwargs) | [
0.026971980929374695,
-0.012767166830599308,
0.09621508419513702,
0.006147551815956831,
-0.006614250596612692,
-0.04064036160707474,
-0.02330276183784008,
-0.045833054929971695,
-0.03162824362516403,
0.03276548534631729,
-0.033731069415807724,
0.01000452321022749,
0.01517039816826582,
0.012938826344907284,
-0.08866207301616669,
0.016575859859585762,
-0.052012793719768524,
-0.004554338287562132,
0.003049636259675026,
-0.01734832674264908,
-0.018496299162507057,
-0.014322830364108086,
-0.06136823073029518,
-0.02000904642045498,
0.010176182724535465,
-0.008937017060816288,
-0.03933145850896835,
-0.049352072179317474,
-0.006506963633000851,
0.0341387614607811,
0.012005428783595562,
-0.08432767540216446,
-0.0005206777714192867,
-0.030212052166461945,
0.011147131212055683,
-0.08806126564741135,
0.09097947180271149,
-0.006319211330264807,
-0.036692194640636444,
0.022315720096230507,
-0.030748488381505013,
-0.03267965465784073,
0.12041906267404556,
0.009199869818985462,
-0.03360232338309288,
0.006088543683290482,
-0.06995119899511337,
0.06660383939743042,
-0.06608886271715164,
-0.0017259814776480198,
0.010675068013370037,
-0.10316728800535202,
0.015985781326889992,
0.01774528995156288,
0.012960284017026424,
0.032615285366773605,
0.028988979756832123,
0.0671188235282898,
0.036735109984874725,
-0.03274402767419815,
0.05269943177700043,
0.04742090404033661,
-0.02037382312119007,
-0.05724840611219406,
-0.009097947739064693,
0.009548553265631199,
-0.007161415182054043,
-0.00030744465766474605,
0.013164129108190536,
0.03068411536514759,
-0.02471895143389702,
0.04888001084327698,
-0.019601356238126755,
0.0068556466139853,
0.023174017667770386,
-0.006110001355409622,
-0.02894606441259384,
-0.0048037804663181305,
-0.0033312649466097355,
0.02448292076587677,
0.024568749591708183,
0.04132699593901634,
0.07342730462551117,
0.019966132938861847,
0.03302297368645668,
-0.026457002386450768,
-0.014988009817898273,
0.052956920117139816,
0.07870583236217499,
-0.01795986294746399,
-0.022573210299015045,
-0.007992890663444996,
0.07226860523223877,
0.03602701425552368,
-0.017895491793751717,
0.007461818866431713,
-0.004304895643144846,
-0.005595023278146982,
-0.010980836115777493,
0.011114945635199547,
-0.015728291124105453,
0.04656260833144188,
0.04930916056036949,
0.04973830655217171,
-0.02864566072821617,
-0.006818096153438091,
-0.020985359326004982,
0.02122139185667038,
-0.014923637732863426,
0.015063111670315266,
-0.053514812141656876,
-0.025534333661198616,
0.018389012664556503,
-0.004986168816685677,
-0.026950523257255554,
0.01596432365477085,
-0.047892969101667404,
-0.014194085262715816,
-0.014515946619212627,
-0.01161919441074133,
-0.0014751978451386094,
-0.02152179554104805,
-0.009055032394826412,
-0.02242300659418106,
0.011790853925049305,
0.0038891579024493694,
0.020781515166163445,
0.009301792830228806,
-0.0430435910820961,
-0.03362378105521202,
0.04209946468472481,
-0.0035431571304798126,
-0.0352974608540535,
0.03519017621874809,
-0.00042948374175466597,
0.0009722894756123424,
0.007907060906291008,
0.006662529893219471,
0.008658070117235184,
0.021435966715216637,
0.047377992421388626,
0.02825942635536194,
0.0312420092523098,
-0.019998319447040558,
-0.047892969101667404,
0.05570347234606743,
0.002525270450860262,
-0.016039423644542694,
0.0019338502315804362,
0.0015529809752479196,
-0.034074388444423676,
-0.04209946468472481,
0.003942801617085934,
-0.04579014331102371,
0.018346097320318222,
-0.019097106531262398,
-0.02828088402748108,
0.008641976863145828,
0.003406365867704153,
0.03780797868967056,
-0.02068495564162731,
-0.06141114607453346,
0.07347021996974945,
0.020835157483816147,
0.03984643518924713,
0.024933526292443275,
0.014655420556664467,
0.0019593308679759502,
0.0050719985738396645,
-0.06407186388969421,
-0.0495237335562706,
0.0021846338640898466,
-0.0819244459271431,
-0.009114040993154049,
-0.023431506007909775,
-0.001937873545102775,
-0.007461818866431713,
0.03486831486225128,
0.024075228720903397,
-0.016393471509218216,
0.002616464626044035,
0.014977281913161278,
-0.014054612256586552,
-0.02501935511827469,
-0.0689641609787941,
-0.014837807975709438,
0.030469540506601334,
0.009038940072059631,
0.01445157453417778,
0.010272741317749023,
-0.03958894684910774,
-0.04160594567656517,
0.010707254521548748,
-0.018142251297831535,
-0.014848536811769009,
-0.012820810079574585,
-0.02888169139623642,
-0.03328046202659607,
0.01565319113433361,
-0.06926456093788147,
0.040275584906339645,
0.008513232693076134,
-0.0048225559294223785,
0.00670008035376668,
0.08368395268917084,
0.039975181221961975,
-0.00372018082998693,
0.022487379610538483,
-0.03694968298077583,
-0.026607204228639603,
0.009773856028914452,
-0.017230311408638954,
-0.02360316552221775,
0.02622097171843052,
0.007397446781396866,
-0.013807851821184158,
0.06763380020856857,
-0.02946104295551777,
-0.03911688178777695,
-0.001979447202757001,
0.04724924638867378,
-0.04312942177057266,
-0.0352974608540535,
0.03536183387041092,
0.04042578488588333,
0.02598493918776512,
0.07673174887895584,
0.034353334456682205,
0.03982497751712799,
-0.068492092192173,
0.033773984760046005,
-0.0076120211742818356,
0.0028109224513173103,
-0.023109644651412964,
-0.027250926941633224,
-0.02444000542163849,
0.019891031086444855,
-0.011544093489646912,
-0.06072450801730156,
0.05737714841961861,
-0.01090037077665329,
0.02677886374294758,
0.011522636748850346,
0.056132618337869644,
-0.01518112700432539,
0.005568201187998056,
0.023989399895071983,
0.009092583321034908,
-0.04280756041407585,
-0.04960956424474716,
-0.05690508708357811,
-0.01092182844877243,
0.014719792641699314,
-0.011114945635199547,
0.031156178563833237,
-0.05102575197815895,
-0.02774444781243801,
0.017584359273314476,
0.037335917353630066,
-0.021950943395495415,
0.02360316552221775,
0.012928097508847713,
-0.0701228603720665,
0.021993858739733696,
0.016050152480602264,
0.001322984229773283,
-0.02323838882148266,
0.006464048754423857,
0.029246468096971512,
0.017530715093016624,
-0.0791349783539772,
0.033752527087926865,
-0.03596264123916626,
0.0057505895383656025,
-0.024697493761777878,
0.0701228603720665,
0.055574726313352585,
-0.03677802532911301,
-0.005552108399569988,
0.01911856420338154,
0.016608046367764473,
-0.05634719505906105,
-0.02825942635536194,
0.09458432346582413,
-0.03980351984500885,
-0.051197413355112076,
-0.015685375779867172,
-0.0400395505130291,
0.020416738465428352,
0.015910679474473,
-0.009816771373152733,
-0.004374632146209478,
0.048236288130283356,
0.006979026831686497,
0.00598125671967864,
0.04216383770108223,
0.06608886271715164,
-0.0014483761042356491,
-0.0388808511197567,
-0.01976228691637516,
0.020255807787179947,
-0.0088511873036623,
0.07119572907686234,
0.027379672974348068,
-0.0038811115082353354,
-0.07385645061731339,
0.06226944178342819,
-0.06823460757732391,
0.05394396185874939,
-0.0015047017950564623,
0.007890967652201653,
0.06291316449642181,
0.031048892065882683,
-0.023088186979293823,
-0.023817740380764008,
-0.001778283971361816,
0.004473872948437929,
-0.011511907912790775,
0.01679043471813202,
0.046133458614349365,
-0.018979091197252274,
-0.036756567656993866,
0.03564077988266945,
-0.0274225864559412,
0.06982245296239853,
-0.025577249005436897,
0.013475261628627777,
0.039631862193346024,
0.04042578488588333,
0.05488808825612068,
-0.08685965090990067,
-0.018142251297831535,
-0.010213733650743961,
-0.013453804887831211,
-0.014955824241042137,
-0.0057935044169425964,
-0.02508372813463211,
-0.0383015014231205,
0.00759592792019248,
-0.05651885271072388,
-0.023817740380764008,
0.005104184616357088,
-0.0020210209768265486,
0.034031473100185394,
0.013528905808925629,
0.025298302993178368,
0.0055252863094210625,
0.021865114569664,
-0.024053771048784256,
0.06184029579162598,
-0.050596605986356735,
0.07278358191251755,
-0.005460914224386215,
0.031134720891714096,
0.017552172765135765,
0.024590207263827324,
0.0200734194368124,
-0.01549225952476263,
-0.002600371604785323,
0.01241311989724636,
0.00016310994396917522,
-0.012541864067316055,
-0.034975599497556686,
-0.00635139737278223,
-0.0401468388736248,
0.009999159723520279,
-0.043773144483566284,
-0.020556211471557617,
0.04810754209756851,
-0.006785910110920668,
-0.006083179730921984,
-0.0448889285326004,
-0.02598493918776512,
0.0197837445884943,
-0.00017367102554999292,
0.02948250062763691,
-0.006506963633000851,
0.002002245746552944,
-0.0020853932946920395,
0.000751680345274508,
0.04913749918341637,
-0.03476102650165558,
-0.010492679663002491,
0.04476018622517586,
-0.02598493918776512,
-0.05124032869935036,
-0.009103312157094479,
-0.018442654982209206,
0.007268702145665884,
-0.006431862711906433,
0.07578761875629425,
-0.07437142729759216,
0.04548973590135574,
0.004444368649274111,
-0.0638572946190834,
-0.017015736550092697,
-0.005509193520992994,
0.02360316552221775,
-0.020245078951120377,
-0.0013699224218726158,
0.005600387696176767,
0.06776254624128342,
-0.028495458886027336,
-0.030147679150104523,
-0.035254545509815216,
-0.02123212069272995,
0.020888801664114,
0.024912068620324135,
-0.026178056374192238,
0.041992176324129105,
-0.03162824362516403,
0.013185586780309677,
-0.00011231620010221377,
-0.012627693824470043,
0.017884762957692146,
0.001778283971361816,
-0.07415685802698135,
0.0031461946200579405,
-0.01235947571694851,
-0.06660383939743042,
0.014698334969580173,
-0.06325648725032806,
0.024697493761777878,
0.014945095404982567,
0.03152095526456833,
0.023452963680028915,
-0.09484180808067322,
-0.020566940307617188,
-0.029139181599020958,
-0.0483650341629982,
0.06523057073354721,
-0.0002765996032394469,
-0.034074388444423676,
-0.02240155078470707,
-0.009966973215341568,
0.011705024167895317,
-0.043751686811447144,
0.031134720891714096,
0.05008162558078766,
-0.08372686803340912,
-0.015309871174395084,
0.028495458886027336,
0.05978038161993027,
-0.033495038747787476,
-0.06621760874986649,
0.00955928210169077,
-0.014816351234912872,
-0.055531810969114304,
-0.001756826532073319,
-0.06214069947600365,
0.02920355275273323,
0.03918125480413437,
0.06038118898868561,
0.0472063310444355,
-0.03632741793990135,
-0.02980436198413372,
0.003862336277961731,
-0.07136739045381546,
0.01911856420338154,
0.08707422763109207,
0.007880238816142082,
-0.03510434553027153,
-0.08110906183719635,
0.053214408457279205,
0.04300067573785782,
-0.0035243819002062082,
0.08359812200069427,
0.007209694478660822,
-0.031413666903972626,
0.009350072592496872,
0.010878914035856724,
-0.03984643518924713,
0.0023643397726118565,
0.037636321038007736,
-0.008599062450230122,
0.05729132145643234,
0.030448084697127342,
-0.013228501193225384,
-0.029074808582663536,
0.011479721404612064,
-0.0015114073175936937,
-0.01886107586324215,
-0.02920355275273323,
0.04750673472881317,
0.013764937408268452,
-0.0046777185052633286,
-0.031370751559734344,
-0.04074764624238014,
-0.0377221517264843,
-0.007477912120521069,
-0.0052463398315012455,
0.009071125648915768,
-0.017026465386152267,
0.012338018044829369,
-0.022637581452727318,
-0.004020584747195244,
0.019837388768792152,
-0.08673090487718582,
0.034095846116542816,
-0.05742006376385689,
0.03448208048939705,
-0.05003871023654938,
-0.03225050866603851,
-0.03190718963742256,
0.05896500125527382,
0.0019043462816625834,
-0.018957633525133133,
0.018367554992437363,
-0.05690508708357811,
0.039674777537584305,
0.0007248586043715477,
-0.06437227129936218,
0.09981993585824966,
0.014494489878416061,
0.001809129025787115,
0.005181967746466398,
-0.012445305474102497,
0.024010857567191124,
0.044931843876838684,
-0.007960704155266285,
-0.029396669939160347,
0.012917368672788143,
-0.005198061000555754,
-0.05759172514081001,
0.05724840611219406,
0.029267925769090652,
0.007885603234171867,
-0.006651801057159901,
-0.014494489878416061,
-0.010460494086146355,
0.010042074136435986,
-0.017863305285573006,
0.028688574209809303,
0.005541379563510418,
-0.0112222321331501,
0.033430665731430054,
-0.04368731379508972,
-0.021393051370978355,
-0.003441234352067113,
0.011114945635199547,
0.00021474187087733299,
-0.030898690223693848,
-0.03454645350575447,
0.006796638946980238,
0.029611244797706604,
0.039073966443538666,
-0.017627272754907608,
-0.041691772639751434,
0.01240239106118679,
0.013904410414397717,
0.06454393267631531,
0.020287994295358658,
0.02122139185667038,
0.07608802616596222,
-0.05776338279247284,
0.003599482821300626,
0.004017902538180351,
0.0182817243039608,
0.026349715888500214,
-0.007247244939208031,
-0.02242300659418106,
0.0029798997566103935,
0.026049312204122543,
-0.03557640686631203,
0.03186427429318428,
0.020856615155935287,
0.02536267414689064,
0.04126262664794922,
-0.04018975421786308,
-0.03177844360470772,
-0.0022919210605323315,
0.0742855966091156,
-0.004903021268546581,
0.03385981544852257,
-0.03218613564968109,
0.06072450801730156,
0.018807431682944298,
-0.05402979254722595,
-0.055016834288835526,
0.0005196720012463629,
-0.0011955808149650693,
-0.01683334819972515,
-0.02444000542163849,
-0.0659601166844368,
0.03795818239450455,
0.04548973590135574,
-0.019826659932732582,
-0.0005599046708084643,
0.013453804887831211,
-0.01625399850308895,
-0.11329519748687744,
-0.004849377553910017,
-0.01832463964819908,
-0.034825399518013,
0.005423363763839006,
0.11097779124975204,
0.02855983003973961,
-0.016447115689516068,
0.013035384938120842,
0.02592056803405285,
0.0015087251085788012,
0.031177636235952377,
-0.023817740380764008,
-0.031199093908071518,
0.05905082821846008,
0.035211630165576935,
0.06909290701150894,
-0.07964995503425598,
-0.07205402851104736,
-0.034074388444423676,
0.004042041953653097,
0.014526675455272198,
0.020802972838282585,
-0.03984643518924713,
0.026650119572877884,
-0.044717270880937576,
0.013636192306876183,
-0.0018976408755406737,
0.014215542934834957,
0.08063700050115585,
0.03501851484179497,
0.02126430720090866,
-0.026178056374192238,
0.05154073238372803,
-0.009795313701033592,
-0.016382742673158646,
0.014848536811769009,
-0.041133880615234375,
0.01942969672381878,
0.0028001938480883837,
0.01918293721973896,
0.0289246067404747,
-0.01490218099206686,
-0.07711797952651978,
0.03632741793990135,
0.07158196717500687,
0.03776506334543228,
-0.010825269855558872,
0.004439004696905613,
0.04579014331102371,
-0.014569590799510479,
-0.04394480213522911,
0.02920355275273323,
0.04815045744180679,
0.03276548534631729,
0.037035513669252396,
-0.0411982536315918,
0.008765357546508312,
0.021993858739733696,
0.024418547749519348,
0.012187816202640533,
0.03557640686631203,
-0.0330873467028141,
-0.012284374795854092,
-0.01679043471813202,
-0.04121971130371094,
-0.04154157266020775,
0.010873549617826939,
0.03718571364879608,
-0.02688615210354328,
0.02009487710893154,
-0.013378703035414219,
0.0028538373298943043,
0.003264210419729352,
0.048493776470422745,
0.010583873838186264,
-0.01650075800716877,
0.022036774083971977,
0.02127503603696823,
0.027315299957990646,
0.027959022670984268,
0.005997349973767996,
-0.04239986836910248,
0.0020357731264084578,
-0.02804485149681568,
-0.010530230589210987,
0.022315720096230507,
-0.04866543784737587,
0.005798868834972382,
0.001392050296999514,
0.013539633713662624,
0.0330873467028141,
0.0014014379121363163,
-0.03746465966105461,
-0.007762223016470671,
0.012638422660529613,
0.03939582780003548,
-0.02802339568734169,
-0.01891471818089485,
-0.011726481840014458,
-0.015728291124105453,
-0.017487799748778343,
-0.013357246294617653,
-0.036112844944000244,
0.01883961819112301,
0.0022704636212438345,
-0.053514812141656876,
-0.0354047492146492,
0.013646921142935753,
-0.017316140234470367,
0.08132363110780716,
-0.03188573196530342,
-0.0038542896509170532,
0.07741838693618774,
-0.07248317450284958,
0.03156387060880661,
-0.04216383770108223,
-0.0005461584660224617,
-0.004178833216428757,
-0.05377230420708656,
0.008304023183882236,
0.04327962175011635,
0.06741922348737717,
-0.009671933948993683,
0.030512455850839615,
-0.06402894854545593,
-0.07085241377353668,
0.006936111953109503,
0.020792244002223015,
-0.013775666244328022,
0.01626472733914852,
0.032014474272727966,
0.022766325622797012,
-0.011093487963080406,
0.0352974608540535,
0.008641976863145828,
0.050897009670734406,
-0.014741250313818455,
-0.00758519908413291,
-0.07574470341205597,
0.026628661900758743,
0.0641147792339325,
-0.035533491522073746,
0.04840794578194618,
-0.04182051867246628,
0.05596096068620682,
-0.04776422306895256,
-0.013990240171551704,
0.05523140728473663,
0.027186555787920952,
0.009194506332278252,
-0.031113263219594955,
-0.013518176972866058,
-0.03765777871012688,
0.025813279673457146,
0.017616543918848038,
-0.031370751559734344,
0.005847147665917873,
0.021929487586021423,
0.008062627166509628,
0.016339827328920364,
0.001817175536416471,
-0.036434706300497055,
0.07492931932210922,
0.049094583839178085,
0.004020584747195244,
0.047034673392772675,
0.018099335953593254,
0.007869509980082512,
-0.06999411433935165,
0.025856195017695427,
0.008556148037314415,
0.045833054929971695,
0.006034900434315205,
-0.007086314260959625,
0.024096686393022537,
-0.061196573078632355,
0.05390104651451111
]
|
32,039 | pingouin.plotting | plot_circmean | Plot the circular mean and vector length of a set of angles
on the unit circle.
.. versionadded:: 0.3.3
Parameters
----------
angles : array or list
Angles (expressed in radians). Only 1D array are supported here.
square: bool
If True (default), ensure equal aspect ratio between X and Y axes.
ax : matplotlib axes
Axis on which to draw the plot.
kwargs_markers : dict
Optional keywords arguments that are passed to
:obj:`matplotlib.axes.Axes.plot`
to control the markers aesthetics.
kwargs_arrow : dict
Optional keywords arguments that are passed to
:obj:`matplotlib.axes.Axes.arrow`
to control the arrow aesthetics.
Returns
-------
ax : Matplotlib Axes instance
Returns the Axes object with the plot for further tweaking.
Examples
--------
Default plot
.. plot::
>>> import pingouin as pg
>>> ax = pg.plot_circmean([0.05, -0.8, 1.2, 0.8, 0.5, -0.3, 0.3, 0.7])
Changing some aesthetics parameters
.. plot::
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> _, ax = plt.subplots(1, 1, figsize=(3, 3))
>>> ax = pg.plot_circmean([0.05, -0.8, 1.2, 0.8, 0.5, -0.3, 0.3, 0.7],
... kwargs_markers=dict(color='k', mfc='k'),
... kwargs_arrow=dict(ec='k', fc='k'), ax=ax)
.. plot::
>>> import pingouin as pg
>>> import seaborn as sns
>>> sns.set(font_scale=1.5, style='white')
>>> ax = pg.plot_circmean([0.8, 1.5, 3.14, 5.2, 6.1, 2.8, 2.6, 3.2],
... kwargs_markers=dict(marker="None"))
| def plot_circmean(
angles,
square=True,
ax=None,
kwargs_markers=dict(color="tab:blue", marker="o", mfc="none", ms=10),
kwargs_arrow=dict(width=0.01, head_width=0.1, head_length=0.1, fc="tab:red", ec="tab:red"),
):
"""Plot the circular mean and vector length of a set of angles
on the unit circle.
.. versionadded:: 0.3.3
Parameters
----------
angles : array or list
Angles (expressed in radians). Only 1D array are supported here.
square: bool
If True (default), ensure equal aspect ratio between X and Y axes.
ax : matplotlib axes
Axis on which to draw the plot.
kwargs_markers : dict
Optional keywords arguments that are passed to
:obj:`matplotlib.axes.Axes.plot`
to control the markers aesthetics.
kwargs_arrow : dict
Optional keywords arguments that are passed to
:obj:`matplotlib.axes.Axes.arrow`
to control the arrow aesthetics.
Returns
-------
ax : Matplotlib Axes instance
Returns the Axes object with the plot for further tweaking.
Examples
--------
Default plot
.. plot::
>>> import pingouin as pg
>>> ax = pg.plot_circmean([0.05, -0.8, 1.2, 0.8, 0.5, -0.3, 0.3, 0.7])
Changing some aesthetics parameters
.. plot::
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> _, ax = plt.subplots(1, 1, figsize=(3, 3))
>>> ax = pg.plot_circmean([0.05, -0.8, 1.2, 0.8, 0.5, -0.3, 0.3, 0.7],
... kwargs_markers=dict(color='k', mfc='k'),
... kwargs_arrow=dict(ec='k', fc='k'), ax=ax)
.. plot::
>>> import pingouin as pg
>>> import seaborn as sns
>>> sns.set(font_scale=1.5, style='white')
>>> ax = pg.plot_circmean([0.8, 1.5, 3.14, 5.2, 6.1, 2.8, 2.6, 3.2],
... kwargs_markers=dict(marker="None"))
"""
from matplotlib.patches import Circle
from .circular import circ_r, circ_mean
# Sanity checks
angles = np.asarray(angles)
assert angles.ndim == 1, "angles must be a one-dimensional array."
assert angles.size > 1, "angles must have at least 2 values."
assert isinstance(kwargs_markers, dict), "kwargs_markers must be a dict."
assert isinstance(kwargs_arrow, dict), "kwargs_arrow must be a dict."
# Fill missing values in dict
if "color" not in kwargs_markers.keys():
kwargs_markers["color"] = "tab:blue"
if "marker" not in kwargs_markers.keys():
kwargs_markers["marker"] = "o"
if "mfc" not in kwargs_markers.keys():
kwargs_markers["mfc"] = "none"
if "ms" not in kwargs_markers.keys():
kwargs_markers["ms"] = 10
if "width" not in kwargs_arrow.keys():
kwargs_arrow["width"] = 0.01
if "head_width" not in kwargs_arrow.keys():
kwargs_arrow["head_width"] = 0.1
if "head_length" not in kwargs_arrow.keys():
kwargs_arrow["head_length"] = 0.1
if "fc" not in kwargs_arrow.keys():
kwargs_arrow["fc"] = "tab:red"
if "ec" not in kwargs_arrow.keys():
kwargs_arrow["ec"] = "tab:red"
# Convert angles to unit vector
z = np.exp(1j * angles)
r = circ_r(angles) # Resulting vector length
phi = circ_mean(angles) # Circular mean
zm = r * np.exp(1j * phi)
# Plot unit circle
if ax is None:
ax = plt.gca()
circle = Circle((0, 0), 1, edgecolor="k", facecolor="none", linewidth=2)
ax.add_patch(circle)
ax.axvline(0, lw=1, ls=":", color="slategrey")
ax.axhline(0, lw=1, ls=":", color="slategrey")
ax.plot(np.real(z), np.imag(z), ls="None", **kwargs_markers)
# Plot mean resultant vector
ax.arrow(0, 0, np.real(zm), np.imag(zm), **kwargs_arrow)
# X and Y ticks in radians
ax.set_xticks([])
ax.set_yticks([])
ax.spines["top"].set_visible(False)
ax.spines["right"].set_visible(False)
ax.spines["left"].set_visible(False)
ax.spines["bottom"].set_visible(False)
ax.text(1.2, 0, "0", verticalalignment="center")
ax.text(-1.3, 0, r"$\pi$", verticalalignment="center")
ax.text(0, 1.2, r"$+\pi/2$", horizontalalignment="center")
ax.text(0, -1.3, r"$-\pi/2$", horizontalalignment="center")
# Make square
if square:
ax.set_aspect("equal")
return ax
| (angles, square=True, ax=None, kwargs_markers={'color': 'tab:blue', 'marker': 'o', 'mfc': 'none', 'ms': 10}, kwargs_arrow={'width': 0.01, 'head_width': 0.1, 'head_length': 0.1, 'fc': 'tab:red', 'ec': 'tab:red'}) | [
-0.006757867056876421,
-0.038796670734882355,
0.07291168719530106,
-0.01058461144566536,
0.024161411449313164,
0.009831475093960762,
-0.04193134605884552,
0.004895382560789585,
0.04140211269259453,
0.029433362185955048,
0.023876439779996872,
0.023326855152845383,
0.06004731357097626,
0.030573243275284767,
-0.02456851117312908,
0.04510672762989998,
0.04093394801020622,
0.0021194666624069214,
-0.016497744247317314,
-0.042257025837898254,
-0.018309341743588448,
-0.007531357929110527,
-0.043152645230293274,
-0.020904608070850372,
-0.01115455199033022,
0.005628163460642099,
0.013312184251844883,
-0.01612117700278759,
-0.036109808832407,
-0.00002590097028587479,
0.022064844146370888,
-0.01751549541950226,
-0.03828779608011246,
-0.04913702234625816,
0.03551951423287392,
-0.05068400502204895,
0.05320802703499794,
0.017423897981643677,
-0.0435190349817276,
0.06851500272750854,
-0.007678932044655085,
-0.0031524840742349625,
0.03391146659851074,
-0.010788161307573318,
-0.023998571559786797,
0.03639477863907814,
-0.0341150164604187,
0.09876256436109543,
-0.025280937552452087,
-0.020945318043231964,
-0.01508307084441185,
-0.025545552372932434,
-0.026827918365597725,
-0.00043636077316477895,
0.01053372398018837,
0.06322269886732101,
0.005444968119263649,
0.029596202075481415,
0.00619301525875926,
0.0015965970233082771,
0.02462957613170147,
0.02754034474492073,
0.06012873351573944,
-0.036924008280038834,
-0.0038292885292321444,
0.04014010354876518,
0.044007558375597,
0.005735027603805065,
0.027011113241314888,
-0.026563303545117378,
0.03431856632232666,
0.0598437637090683,
0.008477866649627686,
-0.058866724371910095,
0.02715359814465046,
-0.012650646269321442,
-0.007205677684396505,
0.007373606786131859,
-0.019601885229349136,
-0.00529230572283268,
-0.019469577819108963,
0.016039757058024406,
0.023428630083799362,
0.029881171882152557,
0.011897509917616844,
0.01810579188168049,
-0.07063192874193192,
-0.01508307084441185,
-0.051498204469680786,
-0.0008752659196034074,
0.015154313296079636,
-0.027011113241314888,
0.03783998638391495,
-0.011256326921284199,
-0.07258600741624832,
0.0010387422516942024,
-0.0042058564722537994,
-0.05512139946222305,
0.032669808715581894,
-0.0395498089492321,
0.02081301063299179,
-0.036069098860025406,
-0.004325442016124725,
-0.021718807518482208,
0.002497306792065501,
-0.024853480979800224,
-0.029535137116909027,
-0.03301584720611572,
0.038002826273441315,
0.0534115768969059,
-0.031814899295568466,
0.008147097192704678,
0.013322361744940281,
-0.02739785984158516,
-0.01715928316116333,
0.030044011771678925,
-0.029453717172145844,
-0.014482597820460796,
-0.04767145961523056,
-0.037208978086709976,
0.0033204129431396723,
0.03490886092185974,
0.05227169767022133,
-0.010136800818145275,
0.049381282180547714,
0.01701679825782776,
-0.0020367742981761694,
-0.00046116847079247236,
-0.034338921308517456,
0.02680756337940693,
0.027927089482545853,
-0.017271235585212708,
0.058663174510002136,
-0.036964718252420425,
0.005444968119263649,
0.03138744458556175,
0.01364804245531559,
-0.04429252818226814,
-0.015764964744448662,
0.010080824606120586,
0.04677584022283554,
-0.0038827203679829836,
-0.02245158888399601,
-0.0006539050955325365,
-0.040771108120679855,
0.07633133232593536,
0.019612062722444534,
-0.0484449528157711,
0.022410878911614418,
-0.00047325424384325743,
0.05251595750451088,
-0.00221996963955462,
0.035377029329538345,
0.06155358627438545,
0.03120424784719944,
-0.06753796339035034,
0.021779872477054596,
0.02151525765657425,
-0.058378200978040695,
0.08817795664072037,
-0.01745443046092987,
-0.002870058175176382,
0.042745545506477356,
0.00934295542538166,
-0.01036070566624403,
0.028150994330644608,
0.04706081002950668,
-0.01937798038125038,
-0.03169276937842369,
-0.042297735810279846,
-0.00297946622595191,
-0.035173479467630386,
-0.0346238911151886,
0.009989227168262005,
0.014065319672226906,
-0.018482359126210213,
-0.04290838539600372,
0.033850401639938354,
-0.012986503541469574,
-0.09078339487314224,
0.003620649455115199,
-0.000818017462734133,
0.003992128651589155,
-0.05780826136469841,
-0.010910291224718094,
0.046653710305690765,
0.07954742759466171,
-0.035824839025735855,
0.04176850616931915,
-0.07795973122119904,
-0.047345779836177826,
-0.007154790218919516,
-0.00453662546351552,
0.058174651116132736,
0.050114065408706665,
-0.0771455317735672,
0.026420818641781807,
-0.013118811883032322,
-0.000823106209281832,
-0.08325204253196716,
-0.030573243275284767,
0.029107680544257164,
0.013027213513851166,
-0.08329275250434875,
0.03995690867304802,
-0.04860779270529747,
-0.012935616075992584,
0.02234981395304203,
0.04608377069234848,
0.014706503599882126,
0.04176850616931915,
0.015612301416695118,
-0.007154790218919516,
0.03248661383986473,
-0.038348861038684845,
0.07034695893526077,
0.06358908861875534,
-0.016039757058024406,
-0.02536235749721527,
0.016446856781840324,
-0.01115455199033022,
0.008208162151277065,
-0.03635406866669655,
-0.004335619509220123,
0.016334904357790947,
-0.001871389802545309,
0.062489915639162064,
0.026034072041511536,
0.005032779183238745,
-0.0583374910056591,
0.06334482878446579,
-0.03818602114915848,
-0.031326379626989365,
0.025850877165794373,
-0.05271950736641884,
-0.07449937611818314,
0.023164015263319016,
0.009836563840508461,
-0.03299548849463463,
0.03576377406716347,
-0.00835573673248291,
-0.019459400326013565,
-0.012294433079659939,
0.07128328830003738,
0.010335261933505535,
0.020639991387724876,
-0.00257745455019176,
0.06338553875684738,
-0.03836921602487564,
-0.03724968805909157,
-0.043152645230293274,
0.030634308233857155,
-0.004844495095312595,
-0.02739785984158516,
0.00089180440409109,
-0.023306500166654587,
-0.011174906976521015,
0.04465891793370247,
0.056546252220869064,
-0.0034323656000196934,
0.01627383939921856,
-0.017739402130246162,
0.03299548849463463,
0.034399986267089844,
0.06224565580487251,
0.005065856035798788,
-0.018655378371477127,
-0.03633371368050575,
-0.029738686978816986,
0.0048139626160264015,
-0.04036400839686394,
0.06253062933683395,
-0.012742243707180023,
-0.034888505935668945,
0.04889276251196861,
0.06310056895017624,
0.024202121421694756,
0.01696591079235077,
0.032323773950338364,
-0.016843780875205994,
-0.004004850517958403,
-0.04579880088567734,
-0.04441465809941292,
0.0205280389636755,
-0.04197205603122711,
0.006035264115780592,
0.010493014007806778,
-0.009785676375031471,
0.032160934060811996,
0.0043050870299339294,
0.02898555062711239,
-0.035723064094781876,
-0.016650408506393433,
-0.030939633026719093,
0.026319043710827827,
0.025240227580070496,
-0.01641632430255413,
0.011317391879856586,
-0.07494719326496124,
0.00595893245190382,
0.003551951376721263,
-0.015317154116928577,
0.058663174510002136,
-0.030491823330521584,
-0.020639991387724876,
-0.02046697400510311,
0.05247524753212929,
-0.05695335194468498,
0.06977701187133789,
-0.003674081526696682,
0.010655853897333145,
-0.0012378398096188903,
0.018635021522641182,
0.00006436480180127546,
-0.0004242749710101634,
0.024995965883135796,
-0.002989643719047308,
-0.05829678103327751,
0.10478765517473221,
-0.012467450462281704,
-0.025728747248649597,
-0.06143145635724068,
-0.034888505935668945,
-0.001592780463397503,
0.003218637779355049,
0.00038960782694630325,
-0.022614428773522377,
0.07348162680864334,
0.015144135802984238,
0.03368756175041199,
-0.039386965334415436,
-0.009002008475363255,
-0.05255666747689247,
-0.00775017449632287,
-0.030003301799297333,
-0.027173954993486404,
-0.010869581252336502,
0.0006497704889625311,
0.0395701639354229,
-0.02086389809846878,
0.027560699731111526,
-0.011510765179991722,
0.017271235585212708,
0.050806134939193726,
-0.06517677754163742,
0.02684827335178852,
0.07384801656007767,
-0.014502952806651592,
0.008421890437602997,
-0.022471943870186806,
0.023306500166654587,
0.07454008609056473,
-0.02941300719976425,
0.006259169429540634,
-0.01591762714087963,
0.07291168719530106,
0.03788069635629654,
-0.028619160875678062,
-0.008686505258083344,
-0.044781047850847244,
0.002788637997582555,
-0.009103783406317234,
0.006727334577590227,
0.0036028388421982527,
-0.05019548535346985,
0.03950909897685051,
-0.013607332482933998,
-0.018919993191957474,
0.029535137116909027,
-0.025647327303886414,
-0.009429464116692543,
0.016385791823267937,
-0.017047330737113953,
-0.028354546055197716,
0.020507683977484703,
0.036516908556222916,
-0.0020558570977300406,
-0.027703184634447098,
0.013251119293272495,
-0.031529929488897324,
-0.015530881471931934,
-0.08304848521947861,
-0.015317154116928577,
0.015948159620165825,
-0.01176520250737667,
0.010930647142231464,
-0.01840093918144703,
0.00813183095306158,
-0.038002826273441315,
0.03704613819718361,
-0.03698507323861122,
-0.060657963156700134,
0.07474364340305328,
-0.017932774499058723,
-0.06155358627438545,
0.03881702572107315,
0.017769934609532356,
0.026319043710827827,
-0.07946600764989853,
0.001386685878969729,
0.021026737987995148,
-0.02116922289133072,
0.013485201634466648,
-0.010106268338859081,
-0.009383665397763252,
-0.029942236840724945,
-0.003821655409410596,
-0.060942936688661575,
0.025830522179603577,
-0.014574195258319378,
0.001207943307235837,
-0.008177629671990871,
0.028212059289216995,
0.022675493732094765,
0.031672414392232895,
0.02018200419843197,
-0.1206645667552948,
-0.07991381734609604,
-0.0012365676229819655,
-0.026665078476071358,
0.008549109101295471,
-0.040323298424482346,
0.013759994879364967,
0.0628155991435051,
0.08052446693181992,
0.0390816405415535,
0.04036400839686394,
-0.06350766867399216,
0.0031575728207826614,
-0.01725088059902191,
0.010798338800668716,
0.043152645230293274,
-0.06143145635724068,
0.01357679907232523,
-0.041015367954969406,
0.0066459146328270435,
-0.011907687410712242,
-0.03586554899811745,
0.0212709978222847,
-0.01612117700278759,
-0.017240703105926514,
0.05666838213801384,
-0.036415133625268936,
-0.019673127681016922,
-0.0220037791877985,
0.057930391281843185,
-0.01063549891114235,
-0.038450635969638824,
0.021637387573719025,
-0.015215379185974598,
0.001685650204308331,
0.0017759756883606315,
0.04929986223578453,
0.004630767274647951,
0.01894034817814827,
-0.031529929488897324,
-0.04999193176627159,
-0.013088279403746128,
-0.015642834827303886,
0.0030354426708072424,
0.03258838877081871,
-0.0032746142242103815,
-0.07523216307163239,
-0.030186496675014496,
-0.006238813977688551,
0.05267879739403725,
0.09827404469251633,
0.032018449157476425,
-0.04811927303671837,
0.01632472686469555,
0.07291168719530106,
-0.0563834086060524,
0.00017317671154160053,
0.022736558690667152,
0.013159521855413914,
0.04095430299639702,
-0.03051217831671238,
-0.018808040767908096,
-0.034746021032333374,
-0.0284359659999609,
-0.0628155991435051,
-0.00420331209897995,
-0.04127998277544975,
0.031122827902436256,
0.015571591444313526,
0.09615712612867355,
0.03203880414366722,
-0.04024187847971916,
0.04396684840321541,
-0.05801181122660637,
-0.030227206647396088,
0.01799383945763111,
-0.025504842400550842,
0.06989914178848267,
0.010442126542329788,
0.04040471836924553,
0.01357679907232523,
-0.03494957089424133,
0.011378456838428974,
0.0022759458515793085,
0.04494388774037361,
-0.006498340517282486,
0.01874697580933571,
-0.03979406878352165,
0.03055288828909397,
-0.007902837358415127,
-0.05548778921365738,
-0.028944840654730797,
-0.06078009679913521,
0.009821297600865364,
0.009836563840508461,
0.0187978632748127,
0.09119049459695816,
-0.006620470900088549,
0.010091002099215984,
-0.024609221145510674,
-0.0017823366215452552,
0.040872883051633835,
0.045676667243242264,
-0.053289446979761124,
-0.0032364483922719955,
-0.029881171882152557,
-0.0727081373333931,
0.041117142885923386,
-0.029250165447592735,
0.04465891793370247,
-0.008477866649627686,
-0.003121951362118125,
-0.015164490789175034,
-0.020008986815810204,
-0.02318437024950981,
0.010930647142231464,
-0.060006603598594666,
0.021433837711811066,
-0.019174430519342422,
0.0009884907631203532,
0.021535612642765045,
-0.027357149869203568,
0.06611311435699463,
0.01751549541950226,
-0.011235971935093403,
0.03690365329384804,
0.028150994330644608,
-0.01622295193374157,
0.02018200419843197,
0.02536235749721527,
0.06257133930921555,
-0.08573535084724426,
0.06126861646771431,
-0.021820582449436188,
0.058174651116132736,
-0.0005887054139748216,
0.002857336075976491,
0.04246057569980621,
-0.01828898675739765,
0.046165190637111664,
0.012528516352176666,
-0.05613914877176285,
-0.03635406866669655,
-0.016436679288744926,
0.036272648721933365,
0.02916874550282955,
0.005984376184642315,
-0.07726766169071198,
-0.007256565149873495,
0.04127998277544975,
0.03885773569345474,
0.016996443271636963,
0.017138928174972534,
-0.038348861038684845,
-0.053777966648340225,
0.06334482878446579,
0.020639991387724876,
-0.04913702234625816,
0.025891587138175964,
0.028110284358263016,
0.04429252818226814,
0.009195380844175816,
-0.0460023507475853,
-0.022268394008278847,
-0.026420818641781807,
-0.07014340162277222,
-0.02526058256626129,
-0.06322269886732101,
0.06102435663342476,
0.043396905064582825,
-0.03370791673660278,
0.04612448066473007,
-0.0008701771730557084,
0.0187978632748127,
-0.025749102234840393,
-0.01751549541950226,
0.021576322615146637,
-0.01147005520761013,
-0.05373725667595863,
0.030573243275284767,
-0.030980342999100685,
0.01660969853401184,
-0.0028013598639518023,
0.0672529935836792,
-0.060942936688661575,
0.033850401639938354,
-0.008477866649627686,
-0.00001847655585152097,
-0.0529230572283268,
0.04750861972570419,
0.03604874387383461,
-0.012426740489900112,
-0.07340020686388016,
-0.02798815444111824,
-0.016049934551119804,
0.06293772906064987,
-0.02556590735912323,
-0.031672414392232895,
0.014492775313556194,
-0.02542342245578766,
-0.017281413078308105,
0.04134104773402214,
0.028904130682349205,
0.08630529046058655,
-0.01874697580933571,
-0.01676236093044281,
-0.06908494234085083,
0.0010947184637188911,
-0.05430719628930092,
0.003562128869816661,
-0.0084066241979599,
0.005500944796949625,
-0.046409450471401215,
-0.030675018206238747,
0.004170235246419907,
-0.003821655409410596,
-0.04372258856892586,
-0.03425750136375427,
-0.006422009319067001,
0.01374981738626957,
-0.022838333621621132,
0.015174668282270432,
-0.0018497626297175884,
0.014228160493075848,
0.022329458966851234,
-0.07107973843812943,
-0.016996443271636963,
0.05096897482872009,
0.08097227662801743,
0.01785135455429554,
-0.03566199913620949,
0.04099501296877861,
0.025280937552452087,
0.028150994330644608,
0.008320115506649017,
0.03863383084535599,
-0.003989584278315306,
0.014146740548312664,
-0.006223547738045454,
-0.0049081044271588326,
-0.031143182888627052,
-0.012111238203942776,
0.025749102234840393,
-0.016823425889015198,
-0.005729938857257366,
-0.05064329504966736,
-0.02037537656724453,
0.05622056871652603,
0.03155028447508812,
-0.04258270561695099,
-0.029066970571875572,
0.03639477863907814,
-0.016701295971870422,
0.021148867905139923,
0.02032448910176754,
0.0024324250407516956,
0.040771108120679855,
0.022573718801140785,
0.0021194666624069214,
0.02452780120074749,
0.008981653489172459,
0.008930766023695469,
0.005546743515878916,
0.019815614446997643,
-0.0069054411724209785,
0.00008142009028233588,
0.003261892357841134,
0.023428630083799362,
-0.01157183013856411,
-0.024364961311221123,
0.0316317044198513,
-0.024710996076464653,
0.019866501912474632,
0.014014432206749916,
-0.020059874281287193,
0.05964021384716034,
0.03185560926795006,
0.002625797875225544,
-0.003551951376721263,
0.004752897657454014,
-0.05296376720070839,
-0.011327569372951984,
0.023815374821424484,
0.024975610896945,
0.0776340514421463,
-0.03189631924033165,
-0.019917389377951622,
0.01255904883146286,
-0.04474033787846565,
0.03501063585281372,
0.003956507425755262,
0.010035025887191296,
0.00897147599607706,
-0.0185434240847826,
-0.011276681907474995,
0.06171642616391182,
0.039427679032087326,
0.011592185124754906,
-0.02304188534617424,
-0.07511003315448761,
-0.001362514216452837,
-0.021332062780857086,
0.01641632430255413,
0.01835005171597004,
-0.01399407722055912,
0.028252771124243736,
0.04209418594837189,
0.05691264197230339,
-0.0012626474490389228,
-0.03085821308195591,
-0.006844376213848591,
0.021800227463245392,
-0.0573604516685009,
-0.02674649842083454,
0.039040930569171906,
0.05426648631691933,
-0.01948993280529976,
0.03299548849463463,
-0.026929693296551704,
0.028904130682349205,
-0.015296799130737782,
-0.05304518714547157,
-0.057930391281843185,
0.002424791920930147,
-0.022410878911614418,
-0.06521748751401901,
-0.04217560589313507,
-0.06692731380462646,
-0.004457749892026186,
-0.02220732904970646,
-0.026929693296551704,
-0.024018926545977592,
0.0435190349817276,
0.0321405790746212,
-0.010248753242194653,
0.028700580820441246,
-0.04372258856892586,
0.0647696778178215,
-0.004562069196254015,
0.030451113358139992,
-0.0108797587454319,
0.02255336381494999,
-0.0011665972415357828,
-0.07637204229831696,
-0.025932297110557556,
-0.01203999575227499,
0.013759994879364967,
0.0573604516685009,
0.01810579188168049,
0.039834778755903244,
-0.08931783586740494,
0.015988869592547417
]
|
32,040 | pingouin.plotting | plot_paired |
Paired plot.
Parameters
----------
data : :py:class:`pandas.DataFrame`
Long-format dataFrame.
dv : string
Name of column containing the dependent variable.
within : string
Name of column containing the within-subject factor.
subject : string
Name of column containing the subject identifier.
order : list of str
List of values in ``within`` that define the order of elements on the
x-axis of the plot. If None, uses alphabetical order.
boxplot : boolean
If True, add a boxplot to the paired lines using the
:py:func:`seaborn.boxplot` function.
boxplot_in_front : boolean
If True, the boxplot is plotted on the foreground (i.e. above the
individual lines) and with a slight transparency. This makes the
overall plot more readable when plotting a large numbers of subjects.
.. versionadded:: 0.3.8
orient : string
Plot the boxplots vertically and the subjects on the x-axis if
``orient='v'`` (default). Set to ``orient='h'`` to rotate the plot by
by 90 degrees.
.. versionadded:: 0.3.9
ax : matplotlib axes
Axis on which to draw the plot.
colors : list of str
Line colors names. Default is green when value increases from A to B,
indianred when value decreases from A to B and grey when the value is
the same in both measurements.
pointplot_kwargs : dict
Dictionnary of optional arguments that are passed to the
:py:func:`seaborn.pointplot` function.
boxplot_kwargs : dict
Dictionnary of optional arguments that are passed to the
:py:func:`seaborn.boxplot` function.
Returns
-------
ax : Matplotlib Axes instance
Returns the Axes object with the plot for further tweaking.
Notes
-----
Data must be a long-format pandas DataFrame. Missing values are automatically removed using a
strict listwise approach (= complete-case analysis).
Examples
--------
Default paired plot:
.. plot::
>>> import pingouin as pg
>>> df = pg.read_dataset('mixed_anova').query("Time != 'January'")
>>> df = df.query("Group == 'Meditation' and Subject > 40")
>>> ax = pg.plot_paired(data=df, dv='Scores', within='Time', subject='Subject')
Paired plot on an existing axis (no boxplot and uniform color):
.. plot::
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> df = pg.read_dataset('mixed_anova').query("Time != 'January'")
>>> df = df.query("Group == 'Meditation' and Subject > 40")
>>> fig, ax1 = plt.subplots(1, 1, figsize=(5, 4))
>>> pg.plot_paired(data=df, dv='Scores', within='Time',
... subject='Subject', ax=ax1, boxplot=False,
... colors=['grey', 'grey', 'grey']) # doctest: +SKIP
Horizontal paired plot with three unique within-levels:
.. plot::
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> df = pg.read_dataset('mixed_anova').query("Group == 'Meditation'")
>>> # df = df.query("Group == 'Meditation' and Subject > 40")
>>> pg.plot_paired(data=df, dv='Scores', within='Time',
... subject='Subject', orient='h') # doctest: +SKIP
With the boxplot on the foreground:
.. plot::
>>> import pingouin as pg
>>> df = pg.read_dataset('mixed_anova').query("Time != 'January'")
>>> df = df.query("Group == 'Control'")
>>> ax = pg.plot_paired(data=df, dv='Scores', within='Time',
... subject='Subject', boxplot_in_front=True)
| def plot_paired(
data=None,
dv=None,
within=None,
subject=None,
order=None,
boxplot=True,
boxplot_in_front=False,
orient="v",
ax=None,
colors=["green", "grey", "indianred"],
pointplot_kwargs={"scale": 0.6, "marker": "."},
boxplot_kwargs={"color": "lightslategrey", "width": 0.2},
):
"""
Paired plot.
Parameters
----------
data : :py:class:`pandas.DataFrame`
Long-format dataFrame.
dv : string
Name of column containing the dependent variable.
within : string
Name of column containing the within-subject factor.
subject : string
Name of column containing the subject identifier.
order : list of str
List of values in ``within`` that define the order of elements on the
x-axis of the plot. If None, uses alphabetical order.
boxplot : boolean
If True, add a boxplot to the paired lines using the
:py:func:`seaborn.boxplot` function.
boxplot_in_front : boolean
If True, the boxplot is plotted on the foreground (i.e. above the
individual lines) and with a slight transparency. This makes the
overall plot more readable when plotting a large numbers of subjects.
.. versionadded:: 0.3.8
orient : string
Plot the boxplots vertically and the subjects on the x-axis if
``orient='v'`` (default). Set to ``orient='h'`` to rotate the plot by
by 90 degrees.
.. versionadded:: 0.3.9
ax : matplotlib axes
Axis on which to draw the plot.
colors : list of str
Line colors names. Default is green when value increases from A to B,
indianred when value decreases from A to B and grey when the value is
the same in both measurements.
pointplot_kwargs : dict
Dictionnary of optional arguments that are passed to the
:py:func:`seaborn.pointplot` function.
boxplot_kwargs : dict
Dictionnary of optional arguments that are passed to the
:py:func:`seaborn.boxplot` function.
Returns
-------
ax : Matplotlib Axes instance
Returns the Axes object with the plot for further tweaking.
Notes
-----
Data must be a long-format pandas DataFrame. Missing values are automatically removed using a
strict listwise approach (= complete-case analysis).
Examples
--------
Default paired plot:
.. plot::
>>> import pingouin as pg
>>> df = pg.read_dataset('mixed_anova').query("Time != 'January'")
>>> df = df.query("Group == 'Meditation' and Subject > 40")
>>> ax = pg.plot_paired(data=df, dv='Scores', within='Time', subject='Subject')
Paired plot on an existing axis (no boxplot and uniform color):
.. plot::
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> df = pg.read_dataset('mixed_anova').query("Time != 'January'")
>>> df = df.query("Group == 'Meditation' and Subject > 40")
>>> fig, ax1 = plt.subplots(1, 1, figsize=(5, 4))
>>> pg.plot_paired(data=df, dv='Scores', within='Time',
... subject='Subject', ax=ax1, boxplot=False,
... colors=['grey', 'grey', 'grey']) # doctest: +SKIP
Horizontal paired plot with three unique within-levels:
.. plot::
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> df = pg.read_dataset('mixed_anova').query("Group == 'Meditation'")
>>> # df = df.query("Group == 'Meditation' and Subject > 40")
>>> pg.plot_paired(data=df, dv='Scores', within='Time',
... subject='Subject', orient='h') # doctest: +SKIP
With the boxplot on the foreground:
.. plot::
>>> import pingouin as pg
>>> df = pg.read_dataset('mixed_anova').query("Time != 'January'")
>>> df = df.query("Group == 'Control'")
>>> ax = pg.plot_paired(data=df, dv='Scores', within='Time',
... subject='Subject', boxplot_in_front=True)
"""
from pingouin.utils import _check_dataframe
# Update default kwargs with specified inputs
_pointplot_kwargs = {"scale": 0.6, "marker": "."}
_pointplot_kwargs.update(pointplot_kwargs)
_boxplot_kwargs = {"color": "lightslategrey", "width": 0.2}
_boxplot_kwargs.update(boxplot_kwargs)
# Extract pointplot alpha, if set
pp_alpha = _pointplot_kwargs.pop("alpha", 1.0)
# Calculate size of the plot elements by scale as in Seaborn pointplot
scale = _pointplot_kwargs.pop("scale")
lw = plt.rcParams["lines.linewidth"] * 1.8 * scale # get the linewidth
mew = lw * 0.75 # get the markeredgewidth
markersize = np.pi * np.square(lw) * 2 # get the markersize
# Set boxplot in front of Line2D plot (zorder=2 for both) and add alpha
if boxplot_in_front:
_boxplot_kwargs.update(
{
"boxprops": {"zorder": 2},
"whiskerprops": {"zorder": 2},
"zorder": 2,
}
)
# Validate args
data = _check_dataframe(data=data, dv=dv, within=within, subject=subject, effects="within")
# Pivot and melt the table. This has several effects:
# 1) Force missing values to be explicit (a NaN cell is created)
# 2) Automatic collapsing to the mean if multiple within factors are present
# 3) If using dropna, remove rows with missing values (listwise deletion).
# The latter is the same behavior as JASP (= strict complete-case analysis).
data_piv = data.pivot_table(index=subject, columns=within, values=dv, observed=True)
data_piv = data_piv.dropna()
data = data_piv.melt(ignore_index=False, value_name=dv).reset_index()
# Extract within-subject level (alphabetical order)
x_cat = np.unique(data[within])
if order is None:
order = x_cat
else:
assert len(order) == len(
x_cat
), "Order must have the same number of elements as the number of levels in `within`."
# Substitue within by integer order of the ordered columns to allow for
# changing the order of numeric withins.
data["wthn"] = data[within].replace({_ordr: i for i, _ordr in enumerate(order)})
order_num = range(len(order)) # Make numeric order
# Start the plot
if ax is None:
ax = plt.gca()
# Set x and y depending on orientation using the num. replacement within
_x = "wthn" if orient == "v" else dv
_y = dv if orient == "v" else "wthn"
for cat in range(len(x_cat) - 1):
_order = (order_num[cat], order_num[cat + 1])
# Extract data of the current subject-combination
data_now = data.loc[data["wthn"].isin(_order), [dv, "wthn", subject]]
# Select colors for all lines between the current subjects
y1 = data_now.loc[data_now["wthn"] == _order[0], dv].to_numpy()
y2 = data_now.loc[data_now["wthn"] == _order[1], dv].to_numpy()
# Line and scatter colors depending on subject dv trend
_colors = np.where(y1 < y2, colors[0], np.where(y1 > y2, colors[2], colors[1]))
# Line and scatter colors as hue-indexed dictionary
_colors = {subj: clr for subj, clr in zip(data_now[subject].unique(), _colors)}
# Plot individual lines using Seaborn
sns.lineplot(
data=data_now,
x=_x,
y=_y,
hue=subject,
palette=_colors,
ls="-",
lw=lw,
legend=False,
ax=ax,
)
# Plot individual markers using Seaborn
sns.scatterplot(
data=data_now,
x=_x,
y=_y,
hue=subject,
palette=_colors,
edgecolor="face",
lw=mew,
sizes=[markersize] * data_now.shape[0],
legend=False,
ax=ax,
**_pointplot_kwargs,
)
# Set zorder and alpha of pointplot markers and lines
_ = plt.setp(ax.collections, alpha=pp_alpha, zorder=2) # Set marker alpha
_ = plt.setp(ax.lines, alpha=pp_alpha, zorder=2) # Set line alpha
if boxplot:
# Set boxplot x and y d | (data=None, dv=None, within=None, subject=None, order=None, boxplot=True, boxplot_in_front=False, orient='v', ax=None, colors=['green', 'grey', 'indianred'], pointplot_kwargs={'scale': 0.6, 'marker': '.'}, boxplot_kwargs={'color': 'lightslategrey', 'width': 0.2}) | [
0.042630720883607864,
0.04910418763756752,
0.001434461446478963,
0.029519008472561836,
0.004866870120167732,
-0.027965376153588295,
-0.02023252658545971,
-0.009939714334905148,
0.07400938123464584,
0.029048211872577667,
-0.040135495364665985,
-0.01923208124935627,
0.013264722190797329,
0.049998704344034195,
-0.05654279142618179,
-0.009922059252858162,
-0.003660451155155897,
0.02000889740884304,
-0.009551306255161762,
-0.02377527765929699,
0.013135252520442009,
-0.02885989099740982,
-0.02379881776869297,
0.044725771993398666,
0.004478462040424347,
-0.03264981135725975,
-0.023704659193754196,
-0.04001779481768608,
0.0036310264840722084,
0.015253841876983643,
0.009086393751204014,
-0.03286167234182358,
-0.03952345624566078,
-0.039570536464452744,
-0.008850994519889355,
0.02883635275065899,
-0.030248744413256645,
-0.02584678679704666,
-0.006850104779005051,
0.08738002926111221,
0.028977591544389725,
0.018325796350836754,
0.04981038346886635,
-0.011687549762427807,
-0.002018544590100646,
0.06638246029615402,
-0.016607385128736496,
0.09392412006855011,
0.04449037089943886,
0.000054160111176315695,
0.007144353352487087,
-0.04639710113406181,
-0.00926294270902872,
-0.00039649984682910144,
-0.018266946077346802,
0.02000889740884304,
-0.0045667365193367004,
0.05597783252596855,
0.028247855603694916,
-0.029448388144373894,
0.05635447055101395,
0.05296472832560539,
-0.001634550397284329,
0.03335600718855858,
-0.005146406125277281,
-0.029919186607003212,
0.04373709484934807,
-0.04218346253037453,
-0.041853904724121094,
-0.042677801102399826,
-0.00550538906827569,
0.017031103372573853,
-0.034085746854543686,
-0.0014690356329083443,
-0.008903959766030312,
-0.010292812250554562,
0.021374210715293884,
-0.02199801802635193,
-0.007032538764178753,
0.010151572525501251,
0.06416971236467361,
0.024952271953225136,
-0.0187612846493721,
0.032767511904239655,
-0.03064892254769802,
0.050751980394124985,
0.022951383143663406,
0.03978239744901657,
0.0058584874495863914,
0.01949102059006691,
-0.00030473110382445157,
0.02202155627310276,
0.038322921842336655,
-0.007214972749352455,
-0.012970473617315292,
-0.05207021161913872,
0.007897629402577877,
-0.0288834311068058,
-0.04234824329614639,
0.0055671813897788525,
0.0002092842332785949,
0.009421836584806442,
-0.028906971216201782,
0.00550538906827569,
-0.05009286478161812,
-0.0288834311068058,
-0.030036885291337967,
0.019185001030564308,
-0.01087542437016964,
0.02401067689061165,
-0.03820522502064705,
-0.019608719274401665,
-0.04020611196756363,
-0.015842339023947716,
0.006302802823483944,
-0.0011240292806178331,
-0.03662805259227753,
0.010239847004413605,
-0.04430205374956131,
-0.0215389896184206,
-0.023457489907741547,
0.022080406546592712,
-0.052493929862976074,
-0.0001750778465066105,
-0.07716372609138489,
-0.0734444260597229,
0.036086633801460266,
-0.0016934000886976719,
-0.04536134749650955,
-0.03674575313925743,
0.014159237034618855,
0.024646254256367683,
0.0006403582519851625,
-0.010075068101286888,
-0.07994142919778824,
0.01088719442486763,
-0.01075772475451231,
-0.018667124211788177,
-0.004010607022792101,
0.028247855603694916,
0.020138366147875786,
0.057813942432403564,
-0.03373264521360397,
-0.005905567202717066,
-0.002574674319475889,
0.029754407703876495,
0.016619155183434486,
-0.033520787954330444,
0.009616040624678135,
0.01922031119465828,
-0.008686215616762638,
-0.033049989491701126,
0.028742192313075066,
-0.0023142644204199314,
0.05258809030056,
-0.050987377762794495,
0.003060184186324477,
0.01819632574915886,
-0.018137477338314056,
-0.01177582424134016,
-0.011864098720252514,
-0.09632518887519836,
0.0887453481554985,
0.022904302924871445,
-0.009963253512978554,
0.01873774453997612,
-0.0027659358456730843,
-0.018808363005518913,
0.0017110549379140139,
-0.0676536113023758,
-0.010445821098983288,
0.05348260700702667,
-0.06115660443902016,
-0.01455941516906023,
-0.023422179743647575,
-0.018325796350836754,
-0.014924283139407635,
0.01927916146814823,
0.0831899344921112,
-0.07005468010902405,
0.00582023523747921,
-0.004101824015378952,
-0.005993841681629419,
0.06148616597056389,
-0.04336045682430267,
0.005331782624125481,
0.02071509324014187,
0.007697540335357189,
0.02483457326889038,
-0.017313580960035324,
-0.062145281583070755,
-0.008992234244942665,
-0.01949102059006691,
0.026246964931488037,
-0.004890409763902426,
0.047715336084365845,
0.027753517031669617,
-0.008274267427623272,
-0.029660247266292572,
-0.038322921842336655,
0.05414172261953354,
-0.05946173518896103,
-0.005314127542078495,
-0.02685900218784809,
-0.019926507025957108,
-0.023175010457634926,
-0.012346666306257248,
0.019408630207180977,
0.03013104572892189,
0.02381058782339096,
0.04785657301545143,
-0.03392096608877182,
0.020291374996304512,
0.038322921842336655,
0.0035721766762435436,
-0.025658467784523964,
-0.019679339602589607,
-0.05767270550131798,
0.029566088691353798,
-0.01869066432118416,
-0.03420344367623329,
-0.014312246814370155,
-0.059132177382707596,
0.06402847170829773,
0.014971363358199596,
0.004484347067773342,
0.09180553257465363,
0.05494207888841629,
0.024622714146971703,
-0.04726807773113251,
0.06016793102025986,
-0.01618366688489914,
-0.006367537193000317,
-0.02330448105931282,
-0.01318233273923397,
-0.027023781090974808,
-0.00999267864972353,
-0.0003586153616197407,
-0.0734444260597229,
0.05013994127511978,
0.024975812062621117,
0.0053053004667162895,
0.014865433797240257,
0.026411743834614754,
0.033285390585660934,
-0.01644260622560978,
0.022151026874780655,
0.022468814626336098,
-0.035615839064121246,
-0.00017535370716359466,
0.027212100103497505,
0.0060497489757835865,
-0.0024966984055936337,
0.001338095054961741,
-0.01011037826538086,
-0.030672462657094002,
-0.03688699007034302,
-0.027165019884705544,
0.010840114206075668,
-0.014112157747149467,
-0.0023069081362336874,
-0.0006929552182555199,
-0.07353857904672623,
0.005614261142909527,
0.0434546172618866,
0.0009239402716048062,
-0.07203202694654465,
0.0051758307963609695,
0.019043762236833572,
0.004557908978313208,
-0.0617215633392334,
-0.03698115050792694,
-0.004746227990835905,
0.05065781995654106,
-0.021138811483979225,
0.05870845913887024,
-0.034062206745147705,
-0.014312246814370155,
0.03288521245121956,
-0.009515996091067791,
-0.01544216088950634,
-0.0006392548675648868,
-0.012946933507919312,
-0.03669867292046547,
0.007756390143185854,
-0.044914089143276215,
0.004372532479465008,
-0.03133158013224602,
-0.010975468903779984,
-0.015889419242739677,
-0.032249633222818375,
-0.037334248423576355,
0.026953162625432014,
0.020420845597982407,
0.015830568969249725,
0.040606290102005005,
-0.024928731843829155,
0.020703323185443878,
-0.019797038286924362,
0.010481131263077259,
0.08370780944824219,
-0.020620934665203094,
0.08403737097978592,
0.050234101712703705,
-0.010869539342820644,
0.012899854220449924,
0.015677560120821,
-0.01545393094420433,
0.03778150677680969,
-0.029542548581957817,
0.008315462619066238,
0.10009156912565231,
-0.02151544950902462,
-0.02051500417292118,
-0.0005943819414824247,
0.015877649188041687,
-0.0324614942073822,
-0.03217901661992073,
-0.005087556317448616,
0.017278270795941353,
-0.016277827322483063,
-0.0659116581082344,
-0.00001626412631594576,
-0.00875094998627901,
0.0887453481554985,
0.04453745111823082,
0.00032679972355253994,
-0.0032573307398706675,
0.0073620970360934734,
0.06713573634624481,
-0.028412634506821632,
0.04580860584974289,
-0.028436174616217613,
-0.008203648030757904,
-0.023975366726517677,
-0.007061963900923729,
-0.006614706013351679,
-0.005022821947932243,
0.04981038346886635,
-0.02375173754990101,
0.021644918248057365,
-0.06223944202065468,
-0.021127041429281235,
-0.014735964126884937,
0.02810661494731903,
-0.0076328059658408165,
-0.030484143644571304,
0.050987377762794495,
-0.0187612846493721,
0.060356251895427704,
-0.02148013934493065,
0.09213508665561676,
-0.009904404170811176,
0.013511890545487404,
0.001575700705870986,
0.025658467784523964,
0.04074753075838089,
-0.0409829281270504,
0.02279837243258953,
0.036580972373485565,
0.04333691671490669,
0.010151572525501251,
0.01302932295948267,
0.028153695166110992,
-0.020456155762076378,
-0.0027659358456730843,
-0.02704732120037079,
-0.030554763972759247,
0.01767844893038273,
0.04816259443759918,
-0.029730867594480515,
-0.028954051434993744,
-0.03269689157605171,
0.0027482809964567423,
0.002043555723503232,
-0.0024555036798119545,
-0.002785061951726675,
-0.009704315103590488,
0.05169357359409332,
-0.02838909439742565,
0.05593075230717659,
-0.08676799386739731,
0.0013851748080924153,
0.03947637602686882,
-0.020938722416758537,
-0.01852588541805744,
0.06746529042720795,
0.006991344038397074,
0.021868547424674034,
-0.03161405771970749,
0.02308085188269615,
-0.024646254256367683,
0.10357546806335449,
-0.013841449283063412,
0.014382866211235523,
-0.010963698849081993,
-0.04359585791826248,
0.01597180776298046,
-0.060827046632766724,
0.0037899205926805735,
0.02047969400882721,
0.0009055497357621789,
0.005208198446780443,
-0.01793738827109337,
0.004769768100231886,
-0.044137272983789444,
0.026458824053406715,
-0.014088617637753487,
0.02052677422761917,
-0.0007275294046849012,
0.004519656766206026,
0.08370780944824219,
-0.029942726716399193,
-0.058614298701286316,
0.03742840886116028,
-0.004069456830620766,
-0.013005782850086689,
-0.009427721612155437,
0.03721654787659645,
0.030813701450824738,
0.06746529042720795,
-0.04639710113406181,
-0.002074451884254813,
0.029566088691353798,
-0.0006072553223930299,
0.023457489907741547,
-0.07537469267845154,
0.01568933017551899,
-0.002034728415310383,
-0.020091287791728973,
0.03309706971049309,
-0.040865231305360794,
-0.012582065537571907,
0.006296917796134949,
0.003401512512937188,
-0.007679885718971491,
-0.03359140828251839,
-0.012664454989135265,
-0.017643138766288757,
-0.025634927675127983,
-0.010881309397518635,
0.005908509716391563,
-0.006408731918781996,
-0.0714670717716217,
0.0338268056511879,
0.035568758845329285,
-0.018643584102392197,
-0.024340234696865082,
-0.07466849684715271,
-0.02379881776869297,
0.013876758515834808,
0.029942726716399193,
0.05141109600663185,
0.021362440660595894,
-0.09081685543060303,
-0.008680330589413643,
-0.0006675762706436217,
-0.08050638437271118,
-0.05268225073814392,
0.04806843400001526,
-0.0010033873841166496,
-0.03917035833001137,
-0.06384015083312988,
0.030672462657094002,
0.008391967043280602,
0.06553502380847931,
-0.000959250086452812,
-0.04691497981548309,
-0.07104335725307465,
0.014853663742542267,
0.005864372476935387,
-0.0364161916077137,
-0.04985746368765831,
-0.03992363438010216,
0.007003114093095064,
0.06506422907114029,
0.033544328063726425,
-0.008645020425319672,
-0.005640743765980005,
0.03519212082028389,
-0.017301810905337334,
-0.033285390585660934,
0.029001131653785706,
0.06040332838892937,
0.025187671184539795,
0.04891587048768997,
-0.0006973689305596054,
0.013959147967398167,
-0.0339445061981678,
-0.004419612232595682,
0.021162351593375206,
0.0026335238944739103,
-0.04183036461472511,
0.07339734584093094,
-0.015124372206628323,
0.043148599565029144,
-0.011599275283515453,
-0.053011808544397354,
0.06388723105192184,
-0.07989434897899628,
0.03804044425487518,
-0.045173026621341705,
0.018090397119522095,
-0.02100934274494648,
0.08121258020401001,
-0.0022642421536147594,
-0.028177235275506973,
0.05089321732521057,
-0.0261057261377573,
0.01717234216630459,
0.01543039083480835,
-0.04081815108656883,
0.08243665844202042,
-0.026152806356549263,
0.034556541591882706,
0.020397305488586426,
0.0031631712336093187,
0.024104835465550423,
0.037357788532972336,
-0.043948955833911896,
0.013394190929830074,
-0.04383125528693199,
0.0425836406648159,
0.01301755290478468,
-0.01723119243979454,
0.05207021161913872,
0.001154189696535468,
0.027941836044192314,
-0.019420400261878967,
-0.004298970568925142,
0.017395971342921257,
0.02561138942837715,
0.0374048687517643,
0.02909529022872448,
0.0036133714020252228,
-0.0036898760590702295,
-0.04227762296795845,
-0.011422726325690746,
0.04371355473995209,
-0.017878537997603416,
0.01617189683020115,
-0.02379881776869297,
-0.01115201786160469,
-0.003619256429374218,
0.017619600519537926,
0.05032826215028763,
-0.013888528570532799,
-0.024104835465550423,
-0.02502289228141308,
-0.0004939696518704295,
0.02146836929023266,
-0.02328094094991684,
0.02831847406923771,
-0.017266500741243362,
0.0024143089540302753,
0.0009077566210180521,
0.02911883033812046,
-0.0038811375852674246,
-0.035827696323394775,
-0.01693694293498993,
0.00689129950478673,
0.035027340054512024,
0.046467721462249756,
-0.09914997220039368,
0.029989806935191154,
-0.06454634666442871,
-0.016301365569233894,
-0.00975139532238245,
-0.02375173754990101,
-0.011899408884346485,
0.023598728701472282,
0.04500824958086014,
-0.03337954729795456,
0.042112842202186584,
0.01545393094420433,
0.027165019884705544,
0.04816259443759918,
-0.006602935958653688,
-0.07349150627851486,
-0.008756835013628006,
-0.03387388586997986,
0.017607830464839935,
0.03778150677680969,
-0.015818798914551735,
-0.0013174975756555796,
0.0026658913120627403,
-0.014771274290978909,
0.025964487344026566,
0.0032720433082431555,
-0.008544975891709328,
-0.07932939380407333,
0.040629830211400986,
-0.01947925053536892,
-0.017137032002210617,
0.007373867090791464,
0.0754217728972435,
0.05084614083170891,
0.00001703422822174616,
0.08093010634183884,
0.02352810837328434,
-0.011440381407737732,
0.07033716142177582,
-0.03347370773553848,
0.0024628599639981985,
0.01530092116445303,
-0.02860095351934433,
0.028954051434993744,
-0.030060425400733948,
-0.0676536113023758,
-0.04081815108656883,
0.046208783984184265,
0.0617215633392334,
-0.0005425206618383527,
-0.07735203951597214,
0.04858630895614624,
-0.062710240483284,
-0.02225695550441742,
-0.014888973906636238,
0.02457563392817974,
0.020456155762076378,
0.012829233892261982,
-0.01796092838048935,
-0.03340308740735054,
0.05852013826370239,
0.03980593755841255,
-0.006944264285266399,
0.04107708856463432,
-0.022845452651381493,
0.024363774806261063,
-0.05409464240074158,
0.015807028859853745,
0.040347352623939514,
0.004066514316946268,
-0.03695761039853096,
-0.00728559261187911,
0.003619256429374218,
0.009810244664549828,
-0.06454634666442871,
-0.015359771437942982,
0.057107746601104736,
-0.0055171591229736805,
-0.06478174775838852,
-0.00959838554263115,
0.004360762424767017,
0.06181572377681732,
0.05112861841917038,
0.0024496186524629593,
-0.04529072716832161,
-0.0035751191899180412,
0.04576152563095093,
0.03568645566701889,
-0.025870326906442642,
-0.06515838205814362,
-0.05145817622542381,
-0.01051644142717123,
0.042654260993003845,
0.021821467205882072,
0.021680228412151337,
0.055318716913461685,
0.002081808168441057,
0.02655298449099064,
-0.03568645566701889,
0.039052657783031464,
-0.004198926035314798,
0.0927000418305397,
0.035851236432790756,
0.020926952362060547,
0.03773442655801773,
0.03448592126369476,
0.028436174616217613,
-0.00237605650909245,
0.019644029438495636,
-0.053812164813280106,
0.014641804620623589,
-0.00017516980005893856,
-0.07631628960371017,
-0.03166113793849945,
-0.031072640791535378,
-0.01902022212743759,
-0.04635002091526985,
0.02352810837328434,
-0.018184557557106018,
-0.026717763394117355,
-0.031496357172727585,
-0.038652483373880386,
-0.026647143065929413,
0.0757984146475792,
-0.09905581176280975,
-0.04458453133702278,
-0.028695112094283104,
-0.03978239744901657,
0.010581175796687603,
-0.0404885932803154,
0.0095042260363698,
-0.036816369742155075,
-0.06416971236467361,
-0.027188559994101524,
-0.06449926644563675,
0.0019361550221219659,
-0.04074753075838089,
0.028271395713090897,
-0.03116679936647415,
0.03342662751674652,
0.09091101586818695,
-0.045714445412158966,
0.04590276628732681,
-0.04675019904971123,
0.011028433218598366,
0.028671571984887123,
-0.06026209145784378,
-0.05965005233883858,
-0.0003536498988978565,
0.040159035474061966,
0.0036545663606375456,
0.009233517572283745,
-0.019902968779206276,
-0.019173230975866318,
-0.011987683363258839,
0.0043048555962741375,
0.015759948641061783,
0.009445376694202423,
0.04522010684013367,
-0.012711535207927227,
-0.00042151095112785697,
0.037122391164302826,
0.030319364741444588,
0.010292812250554562,
0.00370164611376822,
-0.0029630823992192745,
-0.021127041429281235,
0.025870326906442642,
0.06770069152116776,
-0.02730626054108143,
0.028200775384902954,
0.006850104779005051,
0.007562186103314161,
-0.010704760439693928,
0.018549425527453423,
0.018773052841424942,
0.03399158641695976,
-0.04700914025306702,
-0.06614705920219421,
-0.016266057267785072,
-0.08587347716093063,
0.08902782201766968,
0.023433949798345566,
0.006367537193000317,
0.02958962880074978,
0.01995004713535309,
-0.024881651625037193,
0.07758744060993195,
-0.020891642197966576,
-0.05819058045744896,
0.005523044150322676,
-0.031049100682139397,
0.0515994168817997,
0.03669867292046547,
-0.0018169843824580312,
0.03347370773553848,
-0.06440510600805283,
-0.044396210461854935,
-0.004828617908060551,
0.07669292390346527,
0.04046505317091942,
0.02883635275065899,
0.04105354845523834,
-0.05621322989463806,
0.07278530299663544
]
|
32,041 | pingouin.plotting | plot_rm_corr | Plot a repeated measures correlation.
Parameters
----------
data : :py:class:`pandas.DataFrame`
Dataframe.
x, y : string
Name of columns in ``data`` containing the two dependent variables.
subject : string
Name of column in ``data`` containing the subject indicator.
legend : boolean
If True, add legend to plot. Legend will show all the unique values in
``subject``.
kwargs_facetgrid : dict
Optional keyword arguments passed to :py:class:`seaborn.FacetGrid`
kwargs_line : dict
Optional keyword arguments passed to :py:class:`matplotlib.pyplot.plot`
kwargs_scatter : dict
Optional keyword arguments passed to :py:class:`matplotlib.pyplot.scatter`
Returns
-------
g : :py:class:`seaborn.FacetGrid`
Seaborn FacetGrid.
See also
--------
rm_corr
Notes
-----
Repeated measures correlation [1]_ (rmcorr) is a statistical technique
for determining the common within-individual association for paired
measures assessed on two or more occasions for multiple individuals.
Results have been tested against the
`rmcorr <https://github.com/cran/rmcorr>` R package. Note that this
function requires `statsmodels
<https://www.statsmodels.org/stable/index.html>`_.
Missing values are automatically removed from the ``data``
(listwise deletion).
References
----------
.. [1] Bakdash, J.Z., Marusich, L.R., 2017. Repeated Measures Correlation.
Front. Psychol. 8, 456. https://doi.org/10.3389/fpsyg.2017.00456
Examples
--------
Default repeated mesures correlation plot
.. plot::
>>> import pingouin as pg
>>> df = pg.read_dataset('rm_corr')
>>> g = pg.plot_rm_corr(data=df, x='pH', y='PacO2', subject='Subject')
With some tweakings
.. plot::
>>> import pingouin as pg
>>> import seaborn as sns
>>> df = pg.read_dataset('rm_corr')
>>> sns.set(style='darkgrid', font_scale=1.2)
>>> g = pg.plot_rm_corr(data=df, x='pH', y='PacO2',
... subject='Subject', legend=True,
... kwargs_facetgrid=dict(height=4.5, aspect=1.5,
... palette='Spectral'))
| def plot_rm_corr(
data=None,
x=None,
y=None,
subject=None,
legend=False,
kwargs_facetgrid=dict(height=4, aspect=1),
kwargs_line=dict(ls="solid"),
kwargs_scatter=dict(marker="o"),
):
"""Plot a repeated measures correlation.
Parameters
----------
data : :py:class:`pandas.DataFrame`
Dataframe.
x, y : string
Name of columns in ``data`` containing the two dependent variables.
subject : string
Name of column in ``data`` containing the subject indicator.
legend : boolean
If True, add legend to plot. Legend will show all the unique values in
``subject``.
kwargs_facetgrid : dict
Optional keyword arguments passed to :py:class:`seaborn.FacetGrid`
kwargs_line : dict
Optional keyword arguments passed to :py:class:`matplotlib.pyplot.plot`
kwargs_scatter : dict
Optional keyword arguments passed to :py:class:`matplotlib.pyplot.scatter`
Returns
-------
g : :py:class:`seaborn.FacetGrid`
Seaborn FacetGrid.
See also
--------
rm_corr
Notes
-----
Repeated measures correlation [1]_ (rmcorr) is a statistical technique
for determining the common within-individual association for paired
measures assessed on two or more occasions for multiple individuals.
Results have been tested against the
`rmcorr <https://github.com/cran/rmcorr>` R package. Note that this
function requires `statsmodels
<https://www.statsmodels.org/stable/index.html>`_.
Missing values are automatically removed from the ``data``
(listwise deletion).
References
----------
.. [1] Bakdash, J.Z., Marusich, L.R., 2017. Repeated Measures Correlation.
Front. Psychol. 8, 456. https://doi.org/10.3389/fpsyg.2017.00456
Examples
--------
Default repeated mesures correlation plot
.. plot::
>>> import pingouin as pg
>>> df = pg.read_dataset('rm_corr')
>>> g = pg.plot_rm_corr(data=df, x='pH', y='PacO2', subject='Subject')
With some tweakings
.. plot::
>>> import pingouin as pg
>>> import seaborn as sns
>>> df = pg.read_dataset('rm_corr')
>>> sns.set(style='darkgrid', font_scale=1.2)
>>> g = pg.plot_rm_corr(data=df, x='pH', y='PacO2',
... subject='Subject', legend=True,
... kwargs_facetgrid=dict(height=4.5, aspect=1.5,
... palette='Spectral'))
"""
# Check that stasmodels is installed
from pingouin.utils import _is_statsmodels_installed
_is_statsmodels_installed(raise_error=True)
from statsmodels.formula.api import ols
# Safety check (duplicated from pingouin.rm_corr)
assert isinstance(data, pd.DataFrame), "Data must be a DataFrame"
assert x in data.columns, "The %s column is not in data." % x
assert y in data.columns, "The %s column is not in data." % y
assert data[x].dtype.kind in "bfiu", "%s must be numeric." % x
assert data[y].dtype.kind in "bfiu", "%s must be numeric." % y
assert subject in data.columns, "The %s column is not in data." % subject
if data[subject].nunique() < 3:
raise ValueError("rm_corr requires at least 3 unique subjects.")
# Remove missing values
data = data[[x, y, subject]].dropna(axis=0)
# Calculate rm_corr
# rmc = pg.rm_corr(data=data, x=x, y=y, subject=subject)
# Fit ANCOVA model
# https://patsy.readthedocs.io/en/latest/builtins-reference.html
# C marks the data as categorical
# Q allows to quote variable that do not meet Python variable name rule
# e.g. if variable is "weight.in.kg" or "2A"
assert x not in ["C", "Q"], "`x` must not be 'C' or 'Q'."
assert y not in ["C", "Q"], "`y` must not be 'C' or 'Q'."
assert subject not in ["C", "Q"], "`subject` must not be 'C' or 'Q'."
formula = f"Q('{y}') ~ C(Q('{subject}')) + Q('{x}')"
model = ols(formula, data=data).fit()
# Fitted values
data["pred"] = model.fittedvalues
# Define color palette
if "palette" not in kwargs_facetgrid:
kwargs_facetgrid["palette"] = sns.hls_palette(data[subject].nunique())
# Start plot
g = sns.FacetGrid(data, hue=subject, **kwargs_facetgrid)
g = g.map(sns.regplot, x, "pred", scatter=False, ci=None, truncate=True, line_kws=kwargs_line)
g = g.map(sns.scatterplot, x, y, **kwargs_scatter)
if legend:
g.add_legend()
return g
| (data=None, x=None, y=None, subject=None, legend=False, kwargs_facetgrid={'height': 4, 'aspect': 1}, kwargs_line={'ls': 'solid'}, kwargs_scatter={'marker': 'o'}) | [
0.011625921353697777,
0.029377328231930733,
0.046878714114427567,
-0.015865840017795563,
0.019199438393115997,
-0.02537701092660427,
-0.015084529295563698,
-0.013615662232041359,
0.1350940465927124,
-0.011469659395515919,
-0.009641389362514019,
0.01114671677350998,
0.03133581578731537,
0.03700293228030205,
-0.0447118766605854,
0.007073477376252413,
-0.033940188586711884,
-0.026189574971795082,
-0.029794028028845787,
-0.038128022104501724,
0.014824091456830502,
0.03389852121472359,
-0.06417175382375717,
0.0033388063311576843,
0.023481028154492378,
-0.0013314856914803386,
-0.02246011421084404,
-0.0024337866343557835,
0.004948308691382408,
0.05887966603040695,
-0.009740355424582958,
-0.058671317994594574,
-0.06438010185956955,
0.00884965993463993,
-0.034273549914360046,
-0.014094866812229156,
0.025439515709877014,
-0.02229343354701996,
-0.004531609360128641,
0.05458765849471092,
0.00039684135117568076,
0.012198884040117264,
0.057212866842746735,
0.0017149796476587653,
0.005932761821895838,
0.006177572999149561,
-0.03696126118302345,
0.08288156986236572,
-0.02383522316813469,
-0.025543691590428352,
0.022043414413928986,
-0.05258750170469284,
-0.051004040986299515,
0.023626873269677162,
0.0027762616518884897,
0.03041907772421837,
-0.03710710629820824,
0.11700927466154099,
0.02902313321828842,
-0.036023687571287155,
0.056379467248916626,
0.004794650711119175,
-0.04512857645750046,
0.0074589247815310955,
0.030814941972494125,
-0.024043573066592216,
0.056671157479286194,
-0.013011448085308075,
0.021751724183559418,
-0.0931740552186966,
-0.05825461819767952,
0.0684637576341629,
0.02117876149713993,
-0.035023611038923264,
0.02400190196931362,
-0.04052404686808586,
0.06413008272647858,
-0.03673207759857178,
-0.02327267825603485,
0.0055525233037769794,
0.03458607569336891,
0.02766885980963707,
0.026189574971795082,
-0.015219956636428833,
-0.011198804713785648,
-0.0392739474773407,
0.020491207018494606,
-0.0039221858605742455,
-0.008141269907355309,
-0.028689773753285408,
0.009370534680783749,
-0.0337526760995388,
0.06017143651843071,
-0.006573437713086605,
-0.0045602573081851006,
-0.032815102487802505,
0.007172443438321352,
0.0010925345122814178,
0.03512778505682945,
-0.03727378696203232,
-0.027147985994815826,
0.013448982499539852,
-0.009948705323040485,
0.047712113708257675,
0.006719282828271389,
0.026606274768710136,
-0.018241029232740402,
0.021564209833741188,
0.001631639781408012,
0.018751487135887146,
-0.06671362370252609,
0.05229581147432327,
0.044336847960948944,
-0.006229660473763943,
0.012792680412530899,
0.0035731999669224024,
-0.06429675966501236,
0.001065839664079249,
-0.03941979259252548,
-0.0021486077457666397,
-0.0009427830809727311,
0.04246170073747635,
-0.02429359219968319,
-0.017855582758784294,
-0.004927474074065685,
-0.0013868287205696106,
-0.00412793131545186,
0.034023530781269073,
-0.06525517255067825,
-0.039044760167598724,
0.002377792727202177,
-0.04179497808218002,
0.024668622761964798,
-0.013386477716267109,
-0.0029715897981077433,
0.06246328353881836,
0.06017143651843071,
-0.030085718259215355,
0.007037016097456217,
0.01688675582408905,
0.032002538442611694,
0.08917373418807983,
-0.07821453362703323,
0.0219184048473835,
0.01833478733897209,
0.004779024515300989,
0.023397687822580338,
0.0021941843442618847,
-0.024543611332774162,
-0.032002538442611694,
-0.017053434625267982,
-0.03614869713783264,
0.06046312674880028,
-0.0012976288562640548,
0.05175410211086273,
-0.03216921538114548,
-0.007886041887104511,
0.011948863975703716,
-0.05696284770965576,
0.014407391659915447,
0.008985087275505066,
-0.02337685227394104,
0.049087222665548325,
-0.008412125520408154,
0.027460509911179543,
-0.03706543892621994,
0.04550360515713692,
-0.04271171987056732,
-0.031273312866687775,
-0.01378234289586544,
-0.06317167729139328,
-0.018022261559963226,
-0.007021389901638031,
-0.06342169642448425,
-0.029689854010939598,
0.02591872029006481,
-0.02683546021580696,
-0.02875227853655815,
0.03631537780165672,
-0.00543272215873003,
-0.01806393265724182,
-0.038503050804138184,
0.00292210653424263,
0.011605086736381054,
-0.04152412340044975,
0.026877131313085556,
0.030356572940945625,
-0.009167393669486046,
0.03344015032052994,
-0.029439833015203476,
-0.009438248351216316,
-0.0004980863304808736,
-0.022855978459119797,
0.045878637582063675,
0.021939238533377647,
-0.07058893144130707,
0.04154495894908905,
-0.04060738533735275,
-0.009209062904119492,
-0.06233827397227287,
-0.003828428452834487,
-0.010740434750914574,
-0.003794571617618203,
-0.0032137962989509106,
-0.008380872197449207,
-0.017126357182860374,
0.03937812149524689,
0.04787879437208176,
0.03971148282289505,
-0.011469659395515919,
0.04144078493118286,
0.023710213601589203,
0.05954638496041298,
0.0077974931336939335,
-0.059754736721515656,
0.012438486330211163,
-0.014396974816918373,
-0.05342090129852295,
0.007037016097456217,
0.031189972534775734,
-0.010855027474462986,
-0.01725136674940586,
-0.046253666281700134,
0.01934528350830078,
-0.02375188283622265,
-0.008610057644546032,
0.013532322831451893,
0.0940074548125267,
0.06004642695188522,
-0.09567424654960632,
0.06783871352672577,
0.006740117445588112,
0.05321254953742027,
-0.06625524908304214,
-0.029627349227666855,
-0.057296209037303925,
0.019126515835523605,
0.08884037286043167,
-0.022710133343935013,
0.06979719549417496,
-0.026439595967531204,
0.02566870115697384,
0.003976877778768539,
0.07467258721590042,
0.02291848324239254,
-0.0073860022239387035,
0.02183506451547146,
0.027356335893273354,
-0.014646993950009346,
-0.0520457923412323,
0.0038154067005962133,
-0.0109487846493721,
-0.026772955432534218,
0.0005931459600105882,
0.029356492683291435,
-0.04437851905822754,
-0.016136696562170982,
0.007224530912935734,
0.052170801907777786,
-0.016918007284402847,
0.00495091313496232,
0.032815102487802505,
-0.02529367245733738,
0.04637867584824562,
0.01861605979502201,
-0.0484205037355423,
-0.10309150815010071,
0.0484205037355423,
0.002528846263885498,
-0.0009427830809727311,
-0.012813515961170197,
0.007490177173167467,
0.010006001219153404,
0.017751406878232956,
0.010063298046588898,
0.04912889376282692,
-0.008208983577787876,
-0.028689773753285408,
0.03225255757570267,
-0.00872464943677187,
-0.014428227208554745,
-0.010401866398751736,
0.051087383180856705,
-0.05608778074383736,
-0.009183019399642944,
-0.010688346810638905,
-0.02016826532781124,
0.004323259461671114,
-0.013365643098950386,
0.02829390950500965,
-0.0043909731321036816,
-0.06371338665485382,
-0.0049170562997460365,
0.03096078708767891,
-0.008682980202138424,
0.016584647819399834,
0.024960311129689217,
0.004172205924987793,
-0.04087824001908302,
0.025335341691970825,
0.03544031083583832,
0.006885962560772896,
0.022626793012022972,
-0.0191786028444767,
-0.025981226935982704,
-0.007604769431054592,
0.07583934813737869,
-0.027606355026364326,
0.02043912000954151,
0.021564209833741188,
0.014303216710686684,
0.06496348232030869,
-0.01681383326649666,
-0.0037867585197091103,
-0.015917928889393806,
0.0346694141626358,
0.01780349388718605,
-0.05979640781879425,
0.043961819261312485,
-0.004726937040686607,
-0.02275180257856846,
-0.0767144113779068,
0.03387768566608429,
-0.03450273349881172,
0.054837681353092194,
0.0026825042441487312,
-0.0292106494307518,
0.02035577967762947,
0.013261468149721622,
0.012938525527715683,
-0.009464291855692863,
0.014303216710686684,
-0.026877131313085556,
-0.017376378178596497,
0.04089907556772232,
-0.03448190167546272,
0.008594430983066559,
-0.020668305456638336,
0.05242082104086876,
-0.019418206065893173,
0.026335420086979866,
-0.05104571208357811,
0.016938842833042145,
-0.004617553669959307,
-0.037648819386959076,
0.06438010185956955,
0.00046064850175753236,
0.009005921892821789,
0.011344648897647858,
-0.05542105808854103,
-0.0009043685859069228,
0.06471346318721771,
0.017855582758784294,
0.033377647399902344,
0.016365880146622658,
0.05612944811582565,
0.005734829697757959,
0.04256587475538254,
0.050253983587026596,
0.04479521885514259,
-0.018293116241693497,
0.017136774957180023,
0.026772955432534218,
-0.012250971049070358,
-0.05267084017395973,
0.0032736968714743853,
-0.07788117229938507,
0.06858877092599869,
0.031002458184957504,
-0.045711956918239594,
-0.032085876911878586,
0.005599402356892824,
-0.0073495409451425076,
0.0050082094967365265,
-0.005750455893576145,
0.020584965124726295,
0.013917770236730576,
-0.04217001050710678,
0.020116178318858147,
-0.049545593559741974,
0.033002614974975586,
-0.06308833509683609,
-0.06567186862230301,
-0.021689219400286674,
-0.040399037301540375,
-0.01961613819003105,
0.006375505123287439,
0.034190211445093155,
-0.01137590128928423,
-0.007375584449619055,
0.014917849563062191,
-0.07658940553665161,
0.08459004014730453,
-0.0011244381312280893,
-0.029106473550200462,
-0.007667274214327335,
0.0006058422732166946,
0.012021786533296108,
-0.08296491205692291,
0.010235186666250229,
0.03252341225743294,
0.0015821566339582205,
0.0084537947550416,
-0.02329351380467415,
0.021855898201465607,
0.02802305482327938,
0.02537701092660427,
-0.07867290079593658,
0.018282698467373848,
-0.010125802829861641,
-0.013949022628366947,
0.044045157730579376,
0.02364770695567131,
-0.04829549416899681,
-0.026981305330991745,
0.017647232860326767,
-0.04006567597389221,
-0.03841971233487129,
0.041044920682907104,
0.028710609301924706,
0.028543928638100624,
-0.011219639331102371,
0.0006061678286641836,
0.05050400272011757,
0.011615503579378128,
0.08058971911668777,
-0.014303216710686684,
0.02300182357430458,
-0.027064645662903786,
-0.0024637370370328426,
-0.04821215569972992,
0.0011094629298895597,
-0.010438327677547932,
-0.001957186497747898,
0.002961172256618738,
-0.035648658871650696,
-0.089507095515728,
-0.001803528401069343,
-0.05942137539386749,
-0.004383159801363945,
0.020418284460902214,
-0.009657015092670918,
-0.019959915429353714,
-0.1250932514667511,
-0.05758789926767349,
0.048628855496644974,
-0.005138427950441837,
-0.054754339158535004,
-0.05267084017395973,
-0.016647152602672577,
0.0794229656457901,
0.04125326871871948,
0.020251605659723282,
0.039857324212789536,
-0.015011606737971306,
-0.0410657562315464,
-0.005661907140165567,
-0.03460691124200821,
-0.03452356904745102,
-0.06054646521806717,
-0.0383572056889534,
0.008427751250565052,
-0.05225414037704468,
-0.008802780881524086,
0.023585202172398567,
0.07271409779787064,
0.03796134144067764,
-0.0016811228124424815,
-0.05350423976778984,
0.023481028154492378,
-0.020980829373002052,
-0.06283831596374512,
-0.02775220014154911,
-0.004870177712291479,
0.00025783292949199677,
0.06496348232030869,
-0.025043651461601257,
0.035106949508190155,
-0.029293987900018692,
0.030814941972494125,
0.0365237295627594,
-0.02055371180176735,
-0.0055525233037769794,
0.03158583864569664,
0.0356069877743721,
0.010386239737272263,
0.020397450774908066,
-0.014761586673557758,
-0.05650448054075241,
-0.0028205360285937786,
-0.012355145998299122,
0.030898282304406166,
-0.06675529479980469,
0.10350820422172546,
0.02044953778386116,
0.026772955432534218,
0.010318526066839695,
-0.04329509660601616,
0.016918007284402847,
-0.01579291932284832,
0.032002538442611694,
-0.04575362801551819,
-0.009969539940357208,
-0.013876100070774555,
0.03210671246051788,
-0.03954480215907097,
-0.034294385462999344,
0.013980275020003319,
-0.02756468579173088,
0.0009388764738105237,
-0.04002400487661362,
-0.03614869713783264,
0.08146478980779648,
0.00926115084439516,
0.027085479348897934,
-0.033377647399902344,
-0.006349461618810892,
-0.01117796916514635,
-0.04708706587553024,
0.00769331818446517,
-0.004510774277150631,
-0.003390893805772066,
-0.02712715044617653,
0.026814624667167664,
-0.010292482562363148,
0.04229502007365227,
0.00020183892047498375,
-0.018959837034344673,
0.0037268579471856356,
0.0030601383186876774,
-0.0029168978799134493,
-0.030606592074036598,
-0.016011685132980347,
0.008917373605072498,
0.007047433406114578,
-0.03462774306535721,
-0.05612944811582565,
-0.06258829683065414,
0.053004201501607895,
0.017230533063411713,
-0.04002400487661362,
0.02475196123123169,
0.010401866398751736,
-0.015865840017795563,
0.015001188963651657,
0.015490811318159103,
0.08363162726163864,
-0.025043651461601257,
-0.004625366535037756,
0.006036936771124601,
0.012678088620305061,
-0.03539863973855972,
-0.01086544431746006,
0.009802860207855701,
-0.06354670226573944,
0.028710609301924706,
0.023147668689489365,
-0.018772320821881294,
0.007787075359374285,
-0.03206504136323929,
0.030252397060394287,
-0.012386398389935493,
0.05133740231394768,
-0.05500435829162598,
0.02001200243830681,
0.04550360515713692,
0.016834666952490807,
0.019793234765529633,
-0.06700531393289566,
-0.02400190196931362,
0.009453874081373215,
0.012865602970123291,
-0.03175251558423042,
0.055379390716552734,
0.014459479600191116,
0.010573755018413067,
0.05600443854928017,
-0.05067068338394165,
-0.04367012903094292,
-0.004515983164310455,
-0.035294465720653534,
-0.023960232734680176,
0.04617032781243324,
-0.025106156244874,
0.023876892402768135,
0.04629533737897873,
-0.01291769091039896,
0.047795455902814865,
0.0013855264987796545,
-0.03425271436572075,
-0.03964897617697716,
0.07079727947711945,
-0.009396578185260296,
-0.05133740231394768,
-0.011792601086199284,
0.07475592195987701,
0.02729382924735546,
0.02393939718604088,
0.02210591919720173,
0.06400507688522339,
-0.0013881308259442449,
0.016303375363349915,
0.009537214413285255,
-0.01799101009964943,
-0.05379592999815941,
-0.041211601346731186,
0.014907431788742542,
0.01834520325064659,
0.02756468579173088,
-0.02839808352291584,
-0.0278563741594553,
-0.005812960676848888,
-0.014417809434235096,
-0.027981383726000786,
0.04271171987056732,
-0.08500673621892929,
-0.07238073647022247,
0.007891250774264336,
0.006813040003180504,
0.048628855496644974,
0.004974352661520243,
-0.03533613309264183,
-0.030752437189221382,
0.07054726034402847,
-0.014813674613833427,
0.10850860178470612,
-0.013490652665495872,
-0.045336928218603134,
-0.027460509911179543,
-0.041315775364637375,
0.004068030975759029,
0.0030262814834713936,
-0.011355066671967506,
-0.014917849563062191,
0.026877131313085556,
0.01314687542617321,
0.00011369716230547056,
0.027793869376182556,
-0.028731444850564003,
0.01014142856001854,
0.020147429779171944,
-0.04975394532084465,
-0.01091753225773573,
0.05496269091963768,
-0.0030002377461642027,
0.0520457923412323,
0.000681694655213505,
-0.0812147706747055,
0.04235752299427986,
-0.0025965599343180656,
0.03512778505682945,
0.04675370454788208,
-0.027898045256733894,
-0.010151846334338188,
0.03554448485374451,
-0.01716802828013897,
0.018959837034344673,
-0.006313000340014696,
0.001065839664079249,
-0.0005459417006932199,
0.03873223811388016,
-0.021564209833741188,
0.05850463733077049,
-0.028439754620194435,
0.05312921106815338,
-0.027231324464082718,
0.04100324958562851,
0.01150091178715229,
0.04256587475538254,
0.007047433406114578,
-0.0038622852880507708,
0.03414854034781456,
-0.0401490144431591,
0.034211043268442154,
0.03316929563879967,
0.0068078311160206795,
-0.03212754800915718,
-0.02500198222696781,
-0.012803098186850548,
0.022210093215107918,
0.016918007284402847,
0.005797334481030703,
-0.032377567142248154,
-0.04608698561787605,
-0.000484087853692472,
-0.012938525527715683,
0.05687950924038887,
-0.03577366843819618,
-0.0278563741594553,
-0.021960074082016945,
-0.006943258456885815,
0.059754736721515656,
0.025502020493149757,
-0.03248174116015434,
0.021564209833741188,
0.041419949382543564,
-0.09075719118118286,
-0.044878557324409485,
0.021251684054732323,
0.012417650781571865,
0.024251922965049744,
-0.009740355424582958,
0.02043912000954151,
0.06363004446029663,
-0.05271251127123833,
0.05679616704583168,
-0.03231506049633026,
0.005760873202234507,
-0.014230295084416866,
-0.046420346945524216,
-0.0009304122650064528,
0.06600522994995117,
0.02493947744369507,
0.006536976434290409,
-0.027523014694452286,
-0.058296289294958115,
-0.031377486884593964,
0.024522777646780014,
-0.009063218720257282,
-0.01429279986768961,
0.03489859774708748,
0.07046391814947128,
0.019855741411447525,
0.023793552070856094,
0.08625683933496475,
-0.013709420338273048,
0.05979640781879425,
-0.010938366875052452,
0.02593955583870411,
-0.04217001050710678,
0.04754543676972389,
0.010563337244093418,
-0.02856476418673992,
0.017053434625267982,
-0.009167393669486046,
-0.004815485794097185,
-0.0074589247815310955,
-0.03658623248338699,
-0.035565320402383804,
0.027335500344634056,
-0.04987895488739014,
-0.035377804189920425,
0.003794571617618203,
-0.03512778505682945,
0.030710767954587936,
0.025252001360058784,
-0.0028804366011172533,
0.026189574971795082,
0.04421183839440346,
-0.04858718439936638,
0.02775220014154911,
-0.04144078493118286,
-0.015272043645381927,
0.0036903966683894396,
-0.06838042289018631,
0.018313951790332794,
-0.003828428452834487,
0.02137669362127781,
0.034461066126823425,
-0.015751248225569725,
-0.018824409693479538,
-0.03216921538114548,
0.03662790358066559,
0.007792284246534109,
0.011105046607553959,
0.012105125933885574,
-0.005370217375457287,
0.04267004877328873
]
|
32,042 | pingouin.plotting | plot_shift | Shift plot.
Parameters
----------
x, y : array_like
First and second set of observations.
paired : bool
Specify whether ``x`` and ``y`` are related (i.e. repeated measures) or independent.
.. versionadded:: 0.3.0
n_boot : int
Number of bootstrap iterations. The higher, the better, the slower.
percentiles: array_like
Sequence of percentiles to compute, which must be between 0 and 100 inclusive.
Default set to [10, 20, 30, 40, 50, 60, 70, 80, 90].
confidence : float
Confidence level (0.95 = 95%) for the confidence intervals.
seed : int or None
Random seed for generating bootstrap samples, can be integer or None for no seed (default).
show_median: boolean
If True (default), show the median with black lines.
violin: boolean
If True (default), plot the density of X and Y distributions. Defaut set to True.
Returns
-------
fig : matplotlib Figure instance
Matplotlib Figure. To get the individual axes, use fig.axes.
See also
--------
harrelldavis
Notes
-----
The shift plot is described in [1]_. It computes a shift function [2]_ for two (in)dependent
groups using the robust Harrell-Davis quantile estimator in conjunction with bias-corrected
bootstrap confidence intervals.
References
----------
.. [1] Rousselet, G. A., Pernet, C. R. and Wilcox, R. R. (2017). Beyond
differences in means: robust graphical methods to compare two groups
in neuroscience. Eur J Neurosci, 46: 1738-1748.
doi:10.1111/ejn.13610
.. [2] https://garstats.wordpress.com/2016/07/12/shift-function/
Examples
--------
Default shift plot
.. plot::
>>> import numpy as np
>>> import pingouin as pg
>>> np.random.seed(42)
>>> x = np.random.normal(5.5, 2, 50)
>>> y = np.random.normal(6, 1.5, 50)
>>> fig = pg.plot_shift(x, y)
With different options, and custom axes labels
.. plot::
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> data = pg.read_dataset("pairwise_corr")
>>> fig = pg.plot_shift(data["Neuroticism"], data["Conscientiousness"], paired=True,
... n_boot=2000, percentiles=[25, 50, 75], show_median=False, seed=456,
... violin=False)
>>> fig.axes[0].set_xlabel("Groups")
>>> fig.axes[0].set_ylabel("Values", size=15)
>>> fig.axes[0].set_title("Comparing Neuroticism and Conscientiousness", size=15)
>>> fig.axes[1].set_xlabel("Neuroticism quantiles", size=12)
>>> plt.tight_layout()
| def plot_shift(
x,
y,
paired=False,
n_boot=1000,
percentiles=np.arange(10, 100, 10),
confidence=0.95,
seed=None,
show_median=True,
violin=True,
):
"""Shift plot.
Parameters
----------
x, y : array_like
First and second set of observations.
paired : bool
Specify whether ``x`` and ``y`` are related (i.e. repeated measures) or independent.
.. versionadded:: 0.3.0
n_boot : int
Number of bootstrap iterations. The higher, the better, the slower.
percentiles: array_like
Sequence of percentiles to compute, which must be between 0 and 100 inclusive.
Default set to [10, 20, 30, 40, 50, 60, 70, 80, 90].
confidence : float
Confidence level (0.95 = 95%) for the confidence intervals.
seed : int or None
Random seed for generating bootstrap samples, can be integer or None for no seed (default).
show_median: boolean
If True (default), show the median with black lines.
violin: boolean
If True (default), plot the density of X and Y distributions. Defaut set to True.
Returns
-------
fig : matplotlib Figure instance
Matplotlib Figure. To get the individual axes, use fig.axes.
See also
--------
harrelldavis
Notes
-----
The shift plot is described in [1]_. It computes a shift function [2]_ for two (in)dependent
groups using the robust Harrell-Davis quantile estimator in conjunction with bias-corrected
bootstrap confidence intervals.
References
----------
.. [1] Rousselet, G. A., Pernet, C. R. and Wilcox, R. R. (2017). Beyond
differences in means: robust graphical methods to compare two groups
in neuroscience. Eur J Neurosci, 46: 1738-1748.
doi:10.1111/ejn.13610
.. [2] https://garstats.wordpress.com/2016/07/12/shift-function/
Examples
--------
Default shift plot
.. plot::
>>> import numpy as np
>>> import pingouin as pg
>>> np.random.seed(42)
>>> x = np.random.normal(5.5, 2, 50)
>>> y = np.random.normal(6, 1.5, 50)
>>> fig = pg.plot_shift(x, y)
With different options, and custom axes labels
.. plot::
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> data = pg.read_dataset("pairwise_corr")
>>> fig = pg.plot_shift(data["Neuroticism"], data["Conscientiousness"], paired=True,
... n_boot=2000, percentiles=[25, 50, 75], show_median=False, seed=456,
... violin=False)
>>> fig.axes[0].set_xlabel("Groups")
>>> fig.axes[0].set_ylabel("Values", size=15)
>>> fig.axes[0].set_title("Comparing Neuroticism and Conscientiousness", size=15)
>>> fig.axes[1].set_xlabel("Neuroticism quantiles", size=12)
>>> plt.tight_layout()
"""
from pingouin.regression import _bias_corrected_ci
from pingouin.nonparametric import harrelldavis as hd
# Safety check
x = np.asarray(x)
y = np.asarray(y)
percentiles = np.asarray(percentiles) / 100 # Convert to 0 - 1 range
assert x.ndim == 1, "x must be 1D."
assert y.ndim == 1, "y must be 1D."
nx, ny = x.size, y.size
assert not np.isnan(x).any(), "Missing values are not allowed."
assert not np.isnan(y).any(), "Missing values are not allowed."
assert nx >= 10, "x must have at least 10 samples."
assert ny >= 10, "y must have at least 10 samples."
assert 0 < confidence < 1, "confidence must be between 0 and 1."
if paired:
assert nx == ny, "x and y must have the same size when paired=True."
# Robust percentile
x_per = hd(x, percentiles)
y_per = hd(y, percentiles)
delta = y_per - x_per
# Compute bootstrap distribution of differences
rng = np.random.RandomState(seed)
if paired:
bootsam = rng.choice(np.arange(nx), size=(nx, n_boot), replace=True)
bootstat = hd(y[bootsam], percentiles, axis=0) - hd(x[bootsam], percentiles, axis=0)
else:
x_list = rng.choice(x, size=(nx, n_boot), replace=True)
y_list = rng.choice(y, size=(ny, n_boot), replace=True)
bootstat = hd(y_list, percentiles, axis=0) - hd(x_list, percentiles, axis=0)
# Find upper and lower confidence interval for each quantiles
# Bias-corrected bootstrapped confidence interval
lower, median_per, upper = [], [], []
for i, d in enumerate(delta):
ci = _bias_corrected_ci(bootstat[i, :], d, alpha=(1 - confidence))
median_per.append(_bias_corrected_ci(bootstat[i, :], d, alpha=1)[0])
lower.append(ci[0])
upper.append(ci[1])
lower = np.asarray(lower)
median_per = np.asarray(median_per)
upper = np.asarray(upper)
# Create long-format dataFrame for use with Seaborn
data = pd.DataFrame({"value": np.concatenate([x, y]), "variable": ["X"] * nx + ["Y"] * ny})
#############################
# Plots X and Y distributions
#############################
fig = plt.figure(figsize=(8, 5))
ax1 = plt.subplot2grid((3, 3), (0, 0), rowspan=2, colspan=3)
# Boxplot X & Y
def adjacent_values(vals, q1, q3):
upper_adjacent_value = q3 + (q3 - q1) * 1.5
upper_adjacent_value = np.clip(upper_adjacent_value, q3, vals[-1])
lower_adjacent_value = q1 - (q3 - q1) * 1.5
lower_adjacent_value = np.clip(lower_adjacent_value, vals[0], q1)
return lower_adjacent_value, upper_adjacent_value
for dis, pos in zip([x, y], [1.2, -0.2]):
qrt1, medians, qrt3 = np.percentile(dis, [25, 50, 75])
whiskers = adjacent_values(np.sort(dis), qrt1, qrt3)
ax1.plot(medians, pos, marker="o", color="white", zorder=10)
ax1.hlines(pos, qrt1, qrt3, color="k", linestyle="-", lw=7, zorder=9)
ax1.hlines(pos, whiskers[0], whiskers[1], color="k", linestyle="-", lw=2, zorder=9)
ax1 = sns.stripplot(
data=data,
x="value",
y="variable",
orient="h",
order=["Y", "X"],
palette=["#88bedc", "#cfcfcf"],
)
if violin:
vl = plt.violinplot([y, x], showextrema=False, vert=False, widths=1)
# Upper plot
paths = vl["bodies"][0].get_paths()[0]
paths.vertices[:, 1][paths.vertices[:, 1] >= 1] = 1
paths.vertices[:, 1] = paths.vertices[:, 1] - 1.2
vl["bodies"][0].set_edgecolor("k")
vl["bodies"][0].set_facecolor("#88bedc")
vl["bodies"][0].set_alpha(0.8)
# Lower plot
paths = vl["bodies"][1].get_paths()[0]
paths.vertices[:, 1][paths.vertices[:, 1] <= 2] = 2
paths.vertices[:, 1] = paths.vertices[:, 1] - 0.8
vl["bodies"][1].set_edgecolor("k")
vl["bodies"][1].set_facecolor("#cfcfcf")
vl["bodies"][1].set_alpha(0.8)
# Rescale ylim
ax1.set_ylim(2, -1)
for i in range(len(percentiles)):
# Connection between quantiles
if upper[i] < 0:
col = "#4c72b0"
elif lower[i] > 0:
col = "#c34e52"
else:
col = "darkgray"
plt.plot([y_per[i], x_per[i]], [0.2, 0.8], marker="o", color=col, zorder=10)
# X quantiles
plt.plot([x_per[i], x_per[i]], [0.8, 1.2], "k--", zorder=9)
# Y quantiles
plt.plot([y_per[i], y_per[i]], [-0.2, 0.2], "k--", zorder=9)
if show_median:
x_med, y_med = np.median(x), np.median(y)
plt.plot([x_med, x_med], [0.8, 1.2], "k-")
plt.plot([y_med, y_med], [-0.2, 0.2], "k-")
plt.xlabel("Scores (a.u.)", size=15)
ax1.set_yticklabels(["Y", "X"], size=15)
ax1.set_ylabel("")
#######################
# Plots quantiles shift
#######################
ax2 = plt.subplot2grid((3, 3), (2, 0), rowspan=1, colspan=3)
for i, per in enumerate(x_per):
if upper[i] < 0:
col = "#4c72b0"
elif lower[i] > 0:
col = "#c34e52"
else:
col = "darkgray"
plt.plot([per, per], [upper[i], lower[i]], lw=3, color=col, zorder=10)
plt.plot(per, median_per[i], marker="o", ms=10, color=col, zorder=10)
plt.axh | (x, y, paired=False, n_boot=1000, percentiles=array([10, 20, 30, 40, 50, 60, 70, 80, 90]), confidence=0.95, seed=None, show_median=True, violin=True) | [
0.02392490766942501,
0.0013205209979787469,
0.013769560493528843,
0.016293585300445557,
-0.02770501933991909,
-0.04230407252907753,
-0.03540744259953499,
0.031876176595687866,
-0.0037682619877159595,
0.057163823395967484,
-0.017834069207310677,
0.032113175839185715,
0.07455944269895554,
0.054272450506687164,
0.0028410088270902634,
0.032990068197250366,
-0.00253587425686419,
0.008691887371242046,
0.03571553900837898,
-0.004449630156159401,
-0.0017700758762657642,
-0.0614771768450737,
-0.03012239560484886,
0.02155493199825287,
0.002621785970404744,
-0.009284380823373795,
-0.04446075111627579,
-0.03810921311378479,
-0.046380430459976196,
0.026140835136175156,
-0.042327772825956345,
-0.05763781815767288,
0.011553633026778698,
-0.08712031692266464,
0.03671092912554741,
-0.012086877599358559,
0.027349524199962616,
-0.006381160579621792,
-0.046427831053733826,
0.021519381552934647,
0.029079606756567955,
0.0020944662392139435,
0.010297546163201332,
-0.018829459324479103,
0.024233004078269005,
0.05730602145195007,
-0.05484124645590782,
0.03829881176352501,
0.0013745861360803246,
0.019102007150650024,
0.0036793877370655537,
-0.037421923130750656,
0.020322544500231743,
0.04190117493271828,
0.0487741082906723,
0.06612233072519302,
0.03569183871150017,
0.00962802767753601,
0.0656009390950203,
-0.05474644526839256,
0.0013960640644654632,
0.06659632921218872,
0.023344263434410095,
0.020820239558815956,
-0.007785371039062738,
-0.028368612751364708,
-0.014682001434266567,
-0.051475878804922104,
-0.050812285393476486,
0.010226446203887463,
0.0035786638036370277,
0.040597688406705856,
0.0046866275370121,
0.0036408756859600544,
-0.0058538406156003475,
0.025287644937634468,
-0.022728070616722107,
-0.0332033634185791,
-0.0077024223282933235,
-0.015404844656586647,
0.0444844514131546,
0.056784626096487045,
-0.01726527512073517,
0.016127686947584152,
0.035241544246673584,
0.01636468432843685,
0.021744530647993088,
0.05294526368379593,
0.04047919064760208,
0.018485812470316887,
-0.0492481030523777,
-0.016115836799144745,
0.0714784786105156,
0.0041415332816541195,
-0.00617971271276474,
0.010872265323996544,
-0.026472631841897964,
0.0021818592213094234,
-0.024055257439613342,
-0.022230375558137894,
0.033890657126903534,
-0.03460165113210678,
0.024458153173327446,
0.05536264181137085,
-0.043868254870176315,
-0.008075693622231483,
-0.0497220978140831,
0.06190377473831177,
-0.07560223340988159,
-0.027302123606204987,
-0.025335043668746948,
-0.023996006697416306,
-0.06365755945444107,
-0.018995357677340508,
-0.00970505177974701,
0.01955230161547661,
-0.010759690776467323,
0.013425914570689201,
0.04939030110836029,
-0.0444844514131546,
-0.06996168941259384,
-0.0033179663587361574,
0.003744562156498432,
-0.02919810451567173,
-0.045456141233444214,
-0.028700409457087517,
0.06503213942050934,
0.019895948469638824,
-0.05024349316954613,
0.00970505177974701,
0.005759041756391525,
-0.04152198135852814,
-0.06858710944652557,
0.024837348610162735,
-0.01214612741023302,
-0.02433965355157852,
0.001879687188193202,
-0.0053265211172401905,
0.03834621235728264,
0.023865658789873123,
0.024173755198717117,
0.02798941731452942,
-0.020630640909075737,
0.018770210444927216,
-0.0373271219432354,
0.027349524199962616,
0.057211220264434814,
0.010013149119913578,
0.08318615704774857,
-0.025714239105582237,
-0.03137848153710365,
-0.029956497251987457,
0.013568112626671791,
-0.006505584344267845,
0.05820661038160324,
-0.059533797204494476,
0.03180507943034172,
0.05356145650148392,
0.006932179909199476,
0.04313356429338455,
0.0015760341193526983,
-0.06659632921218872,
0.06749691814184189,
0.001783406944014132,
-0.046949226409196854,
0.006120462901890278,
0.022514771670103073,
0.028344912454485893,
0.013971008360385895,
-0.016127686947584152,
-0.008899260312318802,
0.005249497015029192,
-0.038322512060403824,
-0.008869634941220284,
-0.04664113000035286,
-0.008318616077303886,
-0.006233036983758211,
0.014302805066108704,
0.01925605535507202,
-0.041071683168411255,
-0.04356015846133232,
-0.03460165113210678,
-0.006558908615261316,
0.0012997837038710713,
-0.08773650974035263,
0.010718216188251972,
0.05844360962510109,
0.0025566115509718657,
0.030904486775398254,
-0.009266606532037258,
-0.05005389451980591,
-0.03931790217757225,
-0.045503538101911545,
0.02962470054626465,
0.023261314257979393,
0.003155030542984605,
0.024647749960422516,
0.005003612022846937,
0.050717487931251526,
-0.06285176426172256,
0.027396922931075096,
0.009029608219861984,
0.025406142696738243,
-0.05602623522281647,
0.03614213317632675,
-0.007649097591638565,
-0.02095058746635914,
0.015558892861008644,
0.03855951130390167,
-0.0036053259391337633,
0.02187487855553627,
-0.003472014795988798,
-0.032397571951150894,
0.03237387165427208,
-0.019931498914957047,
0.03839361295104027,
-0.02611713670194149,
-0.07754561305046082,
0.01698087900876999,
0.009509528987109661,
-0.0019507865654304624,
0.007933494634926319,
-0.08238036930561066,
0.08318615704774857,
0.012525323778390884,
0.05209207162261009,
0.09029608964920044,
0.02028699405491352,
0.0659327358007431,
-0.05825401097536087,
0.08081617951393127,
0.018367314711213112,
0.0006747025763615966,
-0.05460424721240997,
-0.020441044121980667,
-0.03995779529213905,
-0.008123093284666538,
-0.021519381552934647,
-0.08574572950601578,
0.067354716360569,
-0.037895917892456055,
-0.05247126892209053,
-0.004825863521546125,
0.07271086424589157,
0.02471885085105896,
-0.015345594845712185,
-0.037421923130750656,
0.03059639036655426,
-0.002537355525419116,
0.010807090438902378,
0.035004545003175735,
-0.004787351470440626,
0.016163237392902374,
-0.05901240184903145,
0.03441205248236656,
-0.029458802193403244,
-0.02943510189652443,
-0.037113822996616364,
0.05541003867983818,
-0.024031557142734528,
0.031923577189445496,
-0.04706772416830063,
-0.0949886366724968,
0.021531231701374054,
-0.005776816513389349,
-0.017845919355750084,
-0.046617429703474045,
0.02201707661151886,
0.008354165591299534,
0.002775834407657385,
-0.04322836175560951,
0.035241544246673584,
-0.06346795707941055,
0.02433965355157852,
-0.025737939402461052,
0.0433705598115921,
0.03882020711898804,
-0.07081488519906998,
0.045029543340206146,
-0.06342055648565292,
0.0015167846577242017,
-0.041948575526475906,
-0.03315596655011177,
0.014575352892279625,
0.03372475877404213,
-0.03434095159173012,
0.00844303984194994,
-0.013354814611375332,
0.0006724806735292077,
0.005572406109422445,
-0.010564167983829975,
0.001314596040174365,
-0.014456854201853275,
-0.022088177502155304,
0.02228962443768978,
0.04967469722032547,
-0.03054899163544178,
-0.0016278772382065654,
-0.04552723839879036,
-0.006233036983758211,
0.02678072825074196,
-0.0422566719353199,
0.050812285393476486,
0.046996623277664185,
0.005661280360072851,
0.020417343825101852,
0.05787481367588043,
-0.033369261771440506,
0.012418674305081367,
0.02355756238102913,
0.028321214020252228,
0.06858710944652557,
-0.01291636936366558,
-0.030383093282580376,
0.0186635609716177,
-0.043441660702228546,
0.024600351229310036,
0.01785776950418949,
-0.012371274642646313,
0.03863060846924782,
0.015475943684577942,
-0.08536653965711594,
0.008366015739738941,
-0.0034009155351668596,
0.03623693436384201,
0.03213687613606453,
-0.02084393985569477,
0.027870917692780495,
0.01833176426589489,
0.025263944640755653,
-0.041261281818151474,
-0.010629342868924141,
0.021306084468960762,
0.022230375558137894,
0.01791701838374138,
0.005228759720921516,
-0.017194176092743874,
-0.027396922931075096,
0.020263295620679855,
-0.06209337338805199,
-0.02751542255282402,
-0.023723460733890533,
-0.01721787638962269,
0.012240925803780556,
0.03498084470629692,
-0.0008961471612565219,
0.02514544501900673,
-0.0031165184918791056,
-0.06470034271478653,
0.09508343786001205,
0.032160576432943344,
0.08854230493307114,
0.0020485480781644583,
0.011269235983490944,
0.008146792650222778,
0.054130252450704575,
0.02924550510942936,
-0.04187747463583946,
0.014101357199251652,
0.014196156524121761,
0.016992727294564247,
0.0020722479093819857,
-0.007619473151862621,
0.0186635609716177,
-0.025903837755322456,
-0.0029654325917363167,
-0.04263586923480034,
0.01577218994498253,
0.020227745175361633,
0.03417505323886871,
-0.012240925803780556,
-0.017656320706009865,
-0.057353418320417404,
-0.00536503316834569,
-0.017834069207310677,
-0.0006543355411849916,
-0.02597493678331375,
-0.009011833928525448,
0.009598403237760067,
-0.001124997972510755,
0.019007207825779915,
-0.059865593910217285,
-0.06109798327088356,
0.03841731324791908,
0.007192877121269703,
0.022846568375825882,
0.046522628515958786,
-0.03429355472326279,
0.02915070578455925,
-0.06048178672790527,
0.012229076586663723,
-0.05749562010169029,
0.08550873398780823,
0.03964969888329506,
-0.009035533294081688,
-0.009930199943482876,
0.025453543290495872,
0.05531524121761322,
-0.012951918877661228,
0.01324816606938839,
0.018213266506791115,
0.0046392278745770454,
0.01520339585840702,
0.01986039988696575,
0.030904486775398254,
-0.09328226000070572,
-0.008277141489088535,
0.0028913707938045263,
-0.013307415880262852,
-0.006286361254751682,
0.02467145025730133,
0.010913739912211895,
-0.01688607968389988,
-0.06086098402738571,
0.022882118821144104,
-0.002393675735220313,
-0.07185767590999603,
-0.006274511571973562,
0.028629310429096222,
-0.043536458164453506,
0.01791701838374138,
-0.054225049912929535,
0.02663853019475937,
0.014871599152684212,
-0.01884130947291851,
-0.029980197548866272,
-0.03242127224802971,
-0.026922928169369698,
-0.013260016217827797,
-0.005951602477580309,
0.030169794335961342,
-0.028013117611408234,
-0.029601000249385834,
0.019955197349190712,
0.0001807106746127829,
-0.008360090665519238,
-0.03763521835207939,
-0.009936124086380005,
0.011180361732840538,
-0.01339036412537098,
-0.04028959199786186,
0.008537838235497475,
0.026283035054802895,
-0.07707162201404572,
-0.028842607513070107,
0.04128498211503029,
-0.048110514879226685,
0.010978913865983486,
-0.03727972134947777,
-0.00918958242982626,
0.000987243140116334,
-0.014219855889678001,
0.035383742302656174,
0.031496983021497726,
-0.011968378908932209,
-0.06588533520698547,
-0.04630933329463005,
-0.043963056057691574,
0.0016500958008691669,
0.02602233737707138,
0.022822869941592216,
-0.027776118367910385,
-0.07489123940467834,
-0.018876859918236732,
0.030098695307970047,
0.07204727083444595,
0.015345594845712185,
-0.013591812923550606,
0.010653042234480381,
0.0017493385821580887,
0.0314495824277401,
-0.01566554233431816,
-0.02924550510942936,
0.038180314004421234,
0.038085516542196274,
0.05450944975018501,
-0.02621193416416645,
-0.011044088751077652,
0.0022692519705742598,
0.007649097591638565,
-0.04322836175560951,
-0.041995976120233536,
0.04730472341179848,
0.03986299782991409,
-0.011683981865644455,
-0.02309541590511799,
0.01856876164674759,
-0.06948769837617874,
0.02238442376255989,
-0.01529819518327713,
0.008597088046371937,
0.03903350606560707,
-0.03429355472326279,
0.034791249781847,
-0.04292026534676552,
0.01637653447687626,
0.02276361919939518,
-0.04939030110836029,
0.08219076693058014,
-0.09906499832868576,
0.05503084510564804,
0.030809689313173294,
0.04268326982855797,
-0.043441660702228546,
0.03768261894583702,
0.021720830351114273,
-0.007109927944839001,
-0.0038778732996433973,
-0.04159307852387428,
-0.019149405881762505,
0.048489708453416824,
-0.06389455497264862,
0.05597883462905884,
-0.015985488891601562,
-0.0264489334076643,
-0.03498084470629692,
-0.013674762099981308,
0.07256866246461868,
0.025548340752720833,
-0.003788999281823635,
-0.002489956095814705,
-0.04021849483251572,
0.030383093282580376,
-0.009290305897593498,
0.0022840644232928753,
0.02519284561276436,
-0.0024203381035476923,
0.02214742638170719,
-0.008010518737137318,
0.021614180877804756,
-0.02452925220131874,
0.023960458114743233,
-0.0044703674502670765,
0.014456854201853275,
0.008294915780425072,
0.004659965168684721,
-0.04472144693136215,
0.006665557622909546,
0.06872930377721786,
-0.024837348610162735,
0.013105967082083225,
0.0003538300225045532,
0.019931498914957047,
0.03583403676748276,
-0.028368612751364708,
0.07342185825109482,
-0.017312675714492798,
0.02905590645968914,
-0.0013553299941122532,
-0.015558892861008644,
0.020168496295809746,
0.00821196660399437,
0.003951935097575188,
-0.0018530250526964664,
-0.01380511000752449,
0.02505064755678177,
0.03642653301358223,
0.011269235983490944,
-0.018165865913033485,
0.02467145025730133,
-0.006381160579621792,
0.08783131092786789,
0.05327706038951874,
-0.08413414657115936,
0.005527968984097242,
-0.030999286100268364,
-0.019718199968338013,
-0.003092818660661578,
-0.013283715583384037,
-0.03147328272461891,
-0.0019359742291271687,
0.08380234986543655,
-0.007791296113282442,
0.009888725355267525,
-0.035928837954998016,
0.014065807685256004,
0.07745081931352615,
-0.011334409937262535,
-0.06171417608857155,
-0.06564833968877792,
-0.02060694247484207,
-0.02659113146364689,
0.0945146456360817,
-0.0889689028263092,
-0.004748839419335127,
0.009965749457478523,
-0.03889130800962448,
0.027823518961668015,
-0.029885398223996162,
0.05048048868775368,
-0.00895850919187069,
0.03562074154615402,
-0.04581163823604584,
-0.033369261771440506,
0.013082267716526985,
-0.00029291422106325626,
0.02368791028857231,
-0.012750471010804176,
0.026377832517027855,
0.035004545003175735,
0.009657652117311954,
0.04744692146778107,
-0.0025092121213674545,
-0.0062567368149757385,
0.030809689313173294,
-0.019706349819898605,
0.026377832517027855,
-0.05062268674373627,
-0.10759691148996353,
-0.017845919355750084,
0.054225049912929535,
0.06503213942050934,
0.03898610547184944,
-0.038227714598178864,
0.022751769050955772,
-0.01576033979654312,
0.02084393985569477,
-0.046617429703474045,
0.014468703418970108,
0.0010961139341816306,
0.0336773581802845,
-0.0316154807806015,
-0.016945328563451767,
0.039910394698381424,
0.0064878095872700214,
-0.04220927134156227,
0.015108597464859486,
0.03021719492971897,
0.04768391698598862,
-0.00888148508965969,
-0.005276158917695284,
0.012525323778390884,
0.028416013345122337,
-0.10968249291181564,
-0.0015641842037439346,
0.022597720846533775,
0.009248831309378147,
-0.04886890575289726,
-0.029861697927117348,
0.037113822996616364,
0.039673399180173874,
-0.0565476268529892,
0.025335043668746948,
0.042185574769973755,
0.024789949879050255,
-0.0023596074897795916,
0.021768229082226753,
0.03841731324791908,
0.005812366027384996,
-0.011198136955499649,
0.011334409937262535,
-0.019469352439045906,
-0.059438999742269516,
-0.022455522790551186,
-0.02038179337978363,
-0.032444972544908524,
-0.01650688238441944,
0.019327154383063316,
0.0460723340511322,
-0.030383093282580376,
0.054035454988479614,
-0.023308714851737022,
0.01045159436762333,
0.04519544169306755,
0.05308746173977852,
0.021839329972863197,
0.012928219512104988,
0.01785776950418949,
-0.004274844191968441,
-0.017514122650027275,
0.04460294917225838,
-0.020227745175361633,
0.003009869484230876,
-0.03422245383262634,
-0.05436725169420242,
-0.06133497878909111,
-0.03810921311378479,
0.007607623003423214,
-0.05275566503405571,
0.033985454589128494,
-0.03718492388725281,
0.02182747982442379,
-0.05612103268504143,
0.0012005410389974713,
0.008703736588358879,
0.02047659270465374,
0.03912830352783203,
-0.030904486775398254,
-0.042327772825956345,
0.04201967641711235,
0.00995982438325882,
0.02033439464867115,
-0.0070151290856301785,
-0.01462275255471468,
-0.025856439024209976,
-0.02211187593638897,
-0.017668170854449272,
-0.03130738437175751,
0.043441660702228546,
-0.05171287804841995,
0.042754366993904114,
-0.018391013145446777,
0.002766947029158473,
0.06488994508981705,
-0.043868254870176315,
0.010297546163201332,
-0.06119278073310852,
0.0006302655092440546,
0.02765762060880661,
-0.037990715354681015,
-0.044057853519916534,
0.03275306895375252,
0.01986039988696575,
-0.05318226292729378,
-0.012335725128650665,
-0.044887345284223557,
-0.06939289718866348,
-0.015132296830415726,
0.036497630178928375,
0.019090157002210617,
0.03893870487809181,
0.018343614414334297,
-0.022230375558137894,
-0.0008768911357037723,
-0.024363353848457336,
0.0309755876660347,
0.019801149144768715,
-0.00858523789793253,
-0.03329816460609436,
-0.018592461943626404,
0.02452925220131874,
0.05872800573706627,
-0.009716901928186417,
0.07621842622756958,
0.023711610585451126,
0.012987468391656876,
-0.016258034855127335,
-0.016992727294564247,
0.028605610132217407,
0.025856439024209976,
-0.015866989269852638,
-0.09385105222463608,
-0.01045159436762333,
-0.0628991648554802,
0.028155315667390823,
-0.003750486997887492,
0.00667148269712925,
0.01580774039030075,
0.03171027824282646,
0.03275306895375252,
0.05640542879700661,
-0.012726771645247936,
-0.04630933329463005,
0.007992744445800781,
0.0014923443086445332,
0.017146777361631393,
0.029506200924515724,
0.020630640909075737,
0.02429225482046604,
-0.05327706038951874,
-0.004461479838937521,
0.0018248815322294831,
0.030714889988303185,
-0.005489456932991743,
0.06631193310022354,
0.06503213942050934,
-0.05602623522281647,
0.05029089003801346
]
|
32,045 | pingouin.power | power_anova |
Evaluate power, sample size, effect size or significance level of a one-way balanced ANOVA.
Parameters
----------
eta_squared : float
ANOVA effect size (eta-squared, :math:`\eta^2`).
k : int
Number of groups
n : int
Sample size per group. Groups are assumed to be balanced (i.e. same sample size).
power : float
Test power (= 1 - type II error).
alpha : float
Significance level :math:`\alpha` (type I error probability). The default is 0.05.
Notes
-----
Exactly ONE of the parameters ``eta_squared``, ``k``, ``n``, ``power`` and ``alpha``
must be passed as None, and that parameter is determined from the others.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to
compute it.
This function is a Python adaptation of the `pwr.anova.test` function implemented in the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Statistical power is the likelihood that a study will detect an effect when there is an
effect there to be detected. A high statistical power means that there is a low probability of
concluding that there is no effect when there is one. Statistical power is mainly affected by
the effect size and the sample size.
For one-way ANOVA, eta-squared is the same as partial eta-squared. It can be evaluated from the
F-value (:math:`F^*`) and the degrees of freedom of the ANOVA (:math:`v_1, v_2`) using the
following formula:
.. math:: \eta^2 = \frac{v_1 F^*}{v_1 F^* + v_2}
GPower uses the :math:`f` effect size instead of the :math:`\eta^2`. The formula to convert
from one to the other are given below:
.. math:: f = \sqrt{\frac{\eta^2}{1 - \eta^2}}
.. math:: \eta^2 = \frac{f^2}{1 + f^2}
Using :math:`\eta^2` and the total sample size :math:`N`, the non-centrality parameter is
defined by:
.. math:: \delta = N * \frac{\eta^2}{1 - \eta^2}
Then the critical value of the non-central F-distribution is computed using the percentile
point function of the F-distribution with:
.. math:: q = 1 - \alpha
.. math:: v_1 = k - 1
.. math:: v_2 = N - k
where :math:`k` is the number of groups.
Finally, the power of the ANOVA is calculated using the survival function of the non-central
F-distribution using the previously computed critical value, non-centrality parameter, and
degrees of freedom.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables (i.e.
sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
Results have been tested against GPower and the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Examples
--------
1. Compute achieved power
>>> from pingouin import power_anova
>>> print('power: %.4f' % power_anova(eta_squared=0.1, k=3, n=20))
power: 0.6082
2. Compute required number of groups
>>> print('k: %.4f' % power_anova(eta_squared=0.1, n=20, power=0.80))
k: 6.0944
3. Compute required sample size
>>> print('n: %.4f' % power_anova(eta_squared=0.1, k=3, power=0.80))
n: 29.9256
4. Compute achieved effect size
>>> print('eta-squared: %.4f' % power_anova(n=20, k=4, power=0.80, alpha=0.05))
eta-squared: 0.1255
5. Compute achieved alpha (significance)
>>> print('alpha: %.4f' % power_anova(eta_squared=0.1, n=20, k=4, power=0.80, alpha=None))
alpha: 0.1085
| def power_anova(eta_squared=None, k=None, n=None, power=None, alpha=0.05):
"""
Evaluate power, sample size, effect size or significance level of a one-way balanced ANOVA.
Parameters
----------
eta_squared : float
ANOVA effect size (eta-squared, :math:`\\eta^2`).
k : int
Number of groups
n : int
Sample size per group. Groups are assumed to be balanced (i.e. same sample size).
power : float
Test power (= 1 - type II error).
alpha : float
Significance level :math:`\\alpha` (type I error probability). The default is 0.05.
Notes
-----
Exactly ONE of the parameters ``eta_squared``, ``k``, ``n``, ``power`` and ``alpha``
must be passed as None, and that parameter is determined from the others.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to
compute it.
This function is a Python adaptation of the `pwr.anova.test` function implemented in the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Statistical power is the likelihood that a study will detect an effect when there is an
effect there to be detected. A high statistical power means that there is a low probability of
concluding that there is no effect when there is one. Statistical power is mainly affected by
the effect size and the sample size.
For one-way ANOVA, eta-squared is the same as partial eta-squared. It can be evaluated from the
F-value (:math:`F^*`) and the degrees of freedom of the ANOVA (:math:`v_1, v_2`) using the
following formula:
.. math:: \\eta^2 = \\frac{v_1 F^*}{v_1 F^* + v_2}
GPower uses the :math:`f` effect size instead of the :math:`\\eta^2`. The formula to convert
from one to the other are given below:
.. math:: f = \\sqrt{\\frac{\\eta^2}{1 - \\eta^2}}
.. math:: \\eta^2 = \\frac{f^2}{1 + f^2}
Using :math:`\\eta^2` and the total sample size :math:`N`, the non-centrality parameter is
defined by:
.. math:: \\delta = N * \\frac{\\eta^2}{1 - \\eta^2}
Then the critical value of the non-central F-distribution is computed using the percentile
point function of the F-distribution with:
.. math:: q = 1 - \\alpha
.. math:: v_1 = k - 1
.. math:: v_2 = N - k
where :math:`k` is the number of groups.
Finally, the power of the ANOVA is calculated using the survival function of the non-central
F-distribution using the previously computed critical value, non-centrality parameter, and
degrees of freedom.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables (i.e.
sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
Results have been tested against GPower and the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Examples
--------
1. Compute achieved power
>>> from pingouin import power_anova
>>> print('power: %.4f' % power_anova(eta_squared=0.1, k=3, n=20))
power: 0.6082
2. Compute required number of groups
>>> print('k: %.4f' % power_anova(eta_squared=0.1, n=20, power=0.80))
k: 6.0944
3. Compute required sample size
>>> print('n: %.4f' % power_anova(eta_squared=0.1, k=3, power=0.80))
n: 29.9256
4. Compute achieved effect size
>>> print('eta-squared: %.4f' % power_anova(n=20, k=4, power=0.80, alpha=0.05))
eta-squared: 0.1255
5. Compute achieved alpha (significance)
>>> print('alpha: %.4f' % power_anova(eta_squared=0.1, n=20, k=4, power=0.80, alpha=None))
alpha: 0.1085
"""
# Check the number of arguments that are None
n_none = sum([v is None for v in [eta_squared, k, n, power, alpha]])
if n_none != 1:
err = "Exactly one of eta, k, n, power, and alpha must be None."
raise ValueError(err)
# Safety checks
if eta_squared is not None:
eta_squared = abs(eta_squared)
f_sq = eta_squared / (1 - eta_squared)
if alpha is not None:
assert 0 < alpha <= 1
if power is not None:
assert 0 < power <= 1
def func(f_sq, k, n, power, alpha):
nc = (n * k) * f_sq
dof1 = k - 1
dof2 = (n * k) - k
fcrit = stats.f.ppf(1 - alpha, dof1, dof2)
return stats.ncf.sf(fcrit, dof1, dof2, nc)
# Evaluate missing variable
if power is None:
# Compute achieved power
return func(f_sq, k, n, power, alpha)
elif k is None:
# Compute required number of groups
def _eval_k(k, f_sq, n, power, alpha):
return func(f_sq, k, n, power, alpha) - power
try:
return brenth(_eval_k, 2, 100, args=(f_sq, n, power, alpha))
except ValueError: # pragma: no cover
return np.nan
elif n is None:
# Compute required sample size
def _eval_n(n, f_sq, k, power, alpha):
return func(f_sq, k, n, power, alpha) - power
try:
return brenth(_eval_n, 2, 1e07, args=(f_sq, k, power, alpha))
except ValueError: # pragma: no cover
return np.nan
elif eta_squared is None:
# Compute achieved eta-squared
def _eval_eta(f_sq, k, n, power, alpha):
return func(f_sq, k, n, power, alpha) - power
try:
f_sq = brenth(_eval_eta, 1e-10, 1 - 1e-10, args=(k, n, power, alpha))
return f_sq / (f_sq + 1) # Return eta-square
except ValueError: # pragma: no cover
return np.nan
else:
# Compute achieved alpha
def _eval_alpha(alpha, f_sq, k, n, power):
return func(f_sq, k, n, power, alpha) - power
try:
return brenth(_eval_alpha, 1e-10, 1 - 1e-10, args=(f_sq, k, n, power))
except ValueError: # pragma: no cover
return np.nan
| (eta_squared=None, k=None, n=None, power=None, alpha=0.05) | [
0.029178515076637268,
-0.029615256935358047,
0.02162911929190159,
-0.011688043363392353,
0.04384056106209755,
-0.020526867359876633,
-0.07615946233272552,
-0.04421491175889969,
-0.0063223582692444324,
0.024062396958470345,
0.015223572961986065,
0.0484575480222702,
0.05190989002585411,
0.013632585294544697,
-0.05532063543796539,
0.02016291581094265,
-0.002303293440490961,
-0.015493936836719513,
0.03533449396491051,
0.010876951739192009,
-0.017126519232988358,
-0.001067807781510055,
0.011563260108232498,
0.037019070237874985,
-0.001303726457990706,
0.07482843846082687,
0.04496361315250397,
0.001409012358635664,
-0.024187179282307625,
0.019310228526592255,
0.014152515679597855,
-0.08036050200462341,
0.025746971368789673,
-0.008953208103775978,
0.04637782648205757,
-0.07944542169570923,
-0.00015394824731629342,
0.0009092289255931973,
-0.13776086270809174,
-0.026017336174845695,
0.02541421540081501,
-0.02768111415207386,
-0.0019315428799018264,
-0.013154248706996441,
-0.03427383676171303,
-0.022939344868063927,
-0.009629118256270885,
0.1147175282239914,
-0.010700175538659096,
-0.03851647302508354,
0.03764298930764198,
-0.03622877597808838,
0.016419414430856705,
-0.03868284821510315,
-0.006909879855811596,
0.07765685766935349,
0.008006934076547623,
-0.056526873260736465,
0.053324099630117416,
-0.07786483317613602,
0.020079726353287697,
-0.004697574768215418,
-0.0144956698641181,
-0.025746971368789673,
-0.030218375846743584,
-0.004445408005267382,
-0.05681803449988365,
-0.0009911180241033435,
0.025435013696551323,
0.04762565717101097,
0.004432410001754761,
0.016918547451496124,
0.03113345429301262,
-0.03448180854320526,
-0.08801387995481491,
0.027389952912926674,
-0.03604160249233246,
-0.018967075273394585,
0.018571928143501282,
-0.0024904683232307434,
-0.049164652824401855,
0.008911613374948502,
-0.003046794328838587,
-0.06613519787788391,
-0.004440208896994591,
0.03731023147702217,
0.007996534928679466,
0.012915080413222313,
0.0682981088757515,
0.000861785258166492,
-0.017532065510749817,
-0.0013134750770404935,
0.02662045508623123,
0.04675217345356941,
-0.014298096299171448,
-0.023480074480175972,
0.01176083367317915,
-0.021982673555612564,
0.012811094522476196,
-0.009655114263296127,
-0.01761525496840477,
-0.020495671778917313,
0.042883891612291336,
0.09383710473775864,
0.016398616135120392,
-0.02528943307697773,
-0.050537269562482834,
0.025143852457404137,
0.034128256142139435,
-0.023001737892627716,
-0.07241595536470413,
-0.02768111415207386,
-0.019715774804353714,
-0.06284923106431961,
-0.04471404477953911,
0.017188912257552147,
-0.043632589280605316,
0.03606239706277847,
0.005339689087122679,
0.007991336286067963,
0.05744195356965065,
0.006436742842197418,
-0.009701908566057682,
0.042488742619752884,
0.019642984494566917,
0.029698446393013,
0.040804166346788406,
-0.03514732047915459,
-0.0014363087248057127,
-0.007700174581259489,
0.03458579629659653,
0.04812479391694069,
-0.002221404341980815,
0.07819759100675583,
-0.02892894856631756,
0.05315772071480751,
0.015254768542945385,
0.02233622595667839,
0.015452343039214611,
-0.06538649648427963,
0.016388218849897385,
-0.037518203258514404,
-0.001757366000674665,
-0.06264126300811768,
0.02901213802397251,
-0.02522704191505909,
0.08348008245229721,
-0.019518202170729637,
0.027077995240688324,
-0.031923748552799225,
0.03439861908555031,
0.02050606906414032,
-0.005386482924222946,
-0.0689220204949379,
0.027452344074845314,
-0.00811091996729374,
0.05303293839097023,
-0.03348354250192642,
-0.011594456620514393,
-0.047708846628665924,
-0.02454073168337345,
0.040117859840393066,
-0.022544197738170624,
-0.015441943891346455,
0.006000000983476639,
0.0339202843606472,
0.015441943891346455,
0.026121322065591812,
0.028471408411860466,
-0.06363952904939651,
0.0003590771812014282,
-0.013798962347209454,
-0.039410751312971115,
0.023750437423586845,
-0.04779203608632088,
0.024998271837830544,
-0.03169497847557068,
-0.04629463702440262,
-0.015431545674800873,
-0.034960146993398666,
-0.046960148960351944,
-0.0097694993019104,
-0.07857193797826767,
-0.010970539413392544,
-0.009961873292922974,
0.0005335789755918086,
0.0754939466714859,
0.023792032152414322,
-0.027265170589089394,
-0.017937611788511276,
-0.0412617065012455,
-0.031299833208322525,
0.05141075327992439,
0.020152516663074493,
-0.020058929920196533,
-0.008812827058136463,
0.016419414430856705,
-0.014381284825503826,
0.0357920341193676,
0.007856153883039951,
-0.013268633745610714,
-0.01123050507158041,
0.016481805592775345,
-0.01176083367317915,
0.024207977578043938,
-0.03304680064320564,
0.003985269460827112,
0.011552861891686916,
0.01301906630396843,
0.015431545674800873,
-0.024582326412200928,
-0.03321317955851555,
0.007507800590246916,
0.056110929697752,
0.022876953706145287,
-0.029615256935358047,
0.09275565296411514,
-0.021670714020729065,
-0.00577123137190938,
0.00486135296523571,
-0.013819759711623192,
-0.03452340513467789,
0.004739169031381607,
0.05062045902013779,
0.017136918380856514,
0.0425095409154892,
0.023043332621455193,
0.050370894372463226,
-0.023604856804013252,
-0.03706066682934761,
-0.029240906238555908,
0.01640901528298855,
-0.008017332293093204,
-0.04013865441083908,
-0.05082843080163002,
0.02662045508623123,
-0.00679549528285861,
-0.023563262075185776,
-0.016824960708618164,
-0.01047140546143055,
-0.008870018646121025,
-0.034065864980220795,
0.004713172558695078,
0.050870027393102646,
-0.025123054161667824,
-0.006733103655278683,
0.041365694254636765,
0.013788564130663872,
0.005838822573423386,
-0.024519935250282288,
0.027764303609728813,
-0.05249221250414848,
0.005968805402517319,
0.022481806576251984,
-0.057899489998817444,
-0.008958407677710056,
0.05386482924222946,
-0.006036396138370037,
0.06210053339600563,
-0.030904686078429222,
0.00164038164075464,
-0.013445409946143627,
-0.05532063543796539,
-0.009426345117390156,
-0.007788563147187233,
0.000749350234400481,
0.015639517456293106,
-0.025996537879109383,
0.011958408169448376,
0.029157718643546104,
0.09450262039899826,
0.08709879964590073,
-0.008162912912666798,
0.013060661032795906,
-0.07025304436683655,
0.017001736909151077,
0.059854429215192795,
0.014828425832092762,
-0.0038630857598036528,
-0.017344890162348747,
0.0046663787215948105,
0.01640901528298855,
-0.03458579629659653,
0.027889085933566093,
-0.05390642210841179,
0.030842293053865433,
-0.008880417793989182,
-0.05943848565220833,
0.09583363682031631,
-0.033504340797662735,
0.02177469991147518,
0.011438476853072643,
0.050370894372463226,
-0.04354939982295036,
0.07137610018253326,
0.007965339347720146,
-0.04207279905676842,
-0.02389601804316044,
0.03165338560938835,
0.03221490979194641,
0.0631403923034668,
-0.02028769813477993,
0.08851301670074463,
-0.027077995240688324,
-0.02214905060827732,
0.0051915086805820465,
0.09516812860965729,
-0.0006915079429745674,
0.016824960708618164,
-0.013455808162689209,
-0.04078337177634239,
0.018831891939044,
0.02314731851220131,
-0.013383017852902412,
0.01692894659936428,
-0.10290469974279404,
0.07204160839319229,
0.003642115043476224,
0.047708846628665924,
0.06101907417178154,
-0.005290295463055372,
0.013861354440450668,
0.08298095315694809,
0.009514733217656612,
0.02830503135919571,
-0.0457955040037632,
0.03308839350938797,
-0.023667247965931892,
0.008516466245055199,
-0.051618728786706924,
-0.04417331889271736,
-0.04650260880589485,
0.03346274420619011,
0.051868293434381485,
-0.0940866693854332,
0.060103997588157654,
-0.0006190426065586507,
-0.011552861891686916,
-0.03487695753574371,
-0.0345441997051239,
0.021670714020729065,
0.0839376226067543,
-0.02466551586985588,
-0.0014792029978707433,
-0.003990468569099903,
-0.043632589280605316,
0.07694975286722183,
-0.03955633193254471,
-0.04263432323932648,
0.030738307163119316,
0.011199308559298515,
-0.009670712053775787,
0.044131722301244736,
0.003439342137426138,
0.05336569622159004,
0.030031202360987663,
0.01622183993458748,
0.0013466207310557365,
-0.012093589641153812,
-0.01421490777283907,
-0.04662739112973213,
0.04221837967634201,
-0.03227730095386505,
-0.0009384750737808645,
0.04508839547634125,
-0.06588562577962875,
0.014506069011986256,
0.014142117463052273,
0.022668981924653053,
-0.03433622792363167,
0.04246794432401657,
-0.03764298930764198,
-0.02302253432571888,
-0.020058929920196533,
0.02736915647983551,
0.00888561736792326,
-0.005186309572309256,
-0.020339692011475563,
0.04144887998700142,
-0.020266901701688766,
0.05190989002585411,
0.002625650493428111,
-0.05706760287284851,
0.020485272631049156,
0.0028466209769248962,
0.008017332293093204,
-0.014547662809491158,
0.03924437612295151,
-0.008204507641494274,
-0.039098795503377914,
0.00936915259808302,
-0.013466207310557365,
0.05012132599949837,
0.01817677915096283,
0.01686655357480049,
0.02100520394742489,
0.04479723423719406,
-0.015379552729427814,
-0.12777818739414215,
0.007679377682507038,
0.0057088397443294525,
0.005235702730715275,
-0.039722710847854614,
-0.03181976452469826,
0.00010081782966153696,
-0.06289082765579224,
-0.02528943307697773,
0.011927211657166481,
-0.0384540818631649,
0.013185444287955761,
-0.07873831689357758,
-0.004835356026887894,
-0.036894287914037704,
-0.02081802859902382,
-0.032797232270240784,
0.024000003933906555,
-0.006629117298871279,
-0.002997400937601924,
-0.009935877285897732,
-0.04575390741229057,
0.03464818745851517,
-0.07366379350423813,
0.012603121809661388,
0.027452344074845314,
0.081899493932724,
-0.004297228064388037,
-0.00978509709239006,
-0.04800000786781311,
-0.008334490470588207,
-0.01258232444524765,
0.013549395836889744,
-0.038786835968494415,
-0.03770538046956062,
0.012842290103435516,
-0.00911958608776331,
-0.048665519803762436,
-0.02333449386060238,
-0.015597923658788204,
-0.00910398829728365,
0.006816292647272348,
-0.0020251304376870394,
-0.0002224328782176599,
0.06538649648427963,
0.007850954309105873,
-0.010112653486430645,
0.03747661039233208,
0.08406240493059158,
-0.011147315613925457,
0.0044350093230605125,
-0.01312305312603712,
0.03169497847557068,
0.032110925763845444,
0.06992029398679733,
0.018291164189577103,
-0.0160970576107502,
0.039785102009773254,
-0.05195148289203644,
-0.007341422606259584,
-0.030155984684824944,
-0.01399653684347868,
0.029532067477703094,
0.010481804609298706,
-0.03315078467130661,
0.021608322858810425,
-0.009707107208669186,
0.07046101987361908,
0.05016292259097099,
0.056277308613061905,
0.021920280531048775,
0.0021343159023672342,
0.01761525496840477,
-0.0378301627933979,
-0.013050262816250324,
-0.0008975305245257914,
0.05968805402517319,
0.032110925763845444,
-0.03637435659766197,
-0.003140381770208478,
0.017885617911815643,
-0.05577817186713219,
-0.02830503135919571,
0.019237438216805458,
0.008870018646121025,
0.02050606906414032,
0.006129983812570572,
-0.03032236360013485,
-0.00175346655305475,
-0.0148492231965065,
-0.003753900295123458,
-0.003413345431908965,
-0.02370884269475937,
0.008256500586867332,
0.048415955156087875,
0.07711613178253174,
-0.06646794825792313,
0.003249567234888673,
0.034003473818302155,
0.029719242826104164,
0.039410751312971115,
-0.017594456672668457,
-0.007767765782773495,
0.06750781089067459,
-0.046461012214422226,
-0.025206243619322777,
-0.001895147725008428,
-0.01891508139669895,
-0.04924784228205681,
-0.022668981924653053,
-0.045213181525468826,
-0.000947573862504214,
0.00888561736792326,
-0.02162911929190159,
0.05141075327992439,
-0.029032934457063675,
0.004518198315054178,
0.040554601699113846,
0.0326724499464035,
0.04700174182653427,
0.020110921934247017,
-0.013393417000770569,
0.06592722237110138,
0.004177643917500973,
0.013185444287955761,
-0.0328180305659771,
0.024623921141028404,
0.0036889088805764914,
-0.028409017249941826,
0.00784575566649437,
0.03202773630619049,
0.025435013696551323,
0.021857889369130135,
-0.0010892549762502313,
-0.014672446064651012,
0.030987873673439026,
-0.02560139074921608,
-0.05365685746073723,
-0.04937262460589409,
0.004528596997261047,
0.0010853555286303163,
0.031736575067043304,
-0.02389601804316044,
0.003759099403396249,
0.029552865773439407,
-0.06097748130559921,
-0.0021460142452269793,
0.06605200469493866,
0.020610056817531586,
0.006634316872805357,
-0.030176782980561256,
-0.030904686078429222,
0.06264126300811768,
-0.021753903478384018,
0.046461012214422226,
0.0522010512650013,
0.03333796188235283,
0.03855806589126587,
0.005012132693082094,
-0.01528596505522728,
-0.03256846219301224,
-0.06338995695114136,
-0.005084923002868891,
-0.02610052563250065,
-0.018322359770536423,
-0.08826344460248947,
0.003525130683556199,
0.00033405551221221685,
0.04554593563079834,
0.057150792330503464,
-0.01045580767095089,
-0.012696709483861923,
-0.07041942328214645,
0.06700868159532547,
0.016793763265013695,
-0.06613519787788391,
-0.04949741065502167,
0.025580594316124916,
0.012103988789021969,
-0.05007973313331604,
-0.047334495931863785,
-0.004219238180667162,
0.029844027012586594,
-0.06047834828495979,
0.004138648975640535,
0.0050641256384551525,
0.011896016076207161,
0.027202777564525604,
-0.025393418967723846,
0.012561527080833912,
-0.06451301276683807,
0.07973658293485641,
-0.016918547451496124,
0.04858233034610748,
-0.03760139271616936,
-0.06696708500385284,
-0.029656851664185524,
-0.005667245481163263,
-0.006046794820576906,
0.0000368013497791253,
0.042551133781671524,
0.00640034768730402,
-0.010518199764192104,
-0.003057193011045456,
0.017095323652029037,
-0.01409012358635664,
0.016918547451496124,
0.057150792330503464,
0.0548630952835083,
-0.02196187525987625,
0.03618718311190605,
-0.03335876017808914,
-0.005760833155363798,
0.003730503376573324,
-0.0326724499464035,
-0.021545931696891785,
-0.04203120246529579,
0.02503986656665802,
-0.01633622497320175,
-0.030155984684824944,
0.019455809146165848,
0.019341424107551575,
-0.04933103173971176,
0.06222531571984291,
-0.005542462226003408,
0.04483883082866669,
0.015046796761453152,
-0.061435021460056305,
0.0403258316218853,
-0.029844027012586594,
-0.02882496267557144,
-0.045254774391651154,
-0.0005563259474001825,
0.05315772071480751,
0.0114488760009408,
-0.02780589833855629,
-0.02214905060827732,
-0.02364645153284073,
0.032422881573438644,
0.014682845212519169,
-0.05577817186713219,
0.01612825319170952,
-0.04949741065502167,
0.015452343039214611,
-0.005625650752335787,
-0.0005683493218384683,
0.023292899131774902,
0.06950434297323227,
-0.05290815606713295,
-0.02133795991539955,
0.024311963468790054,
-0.02811785601079464,
-0.019060662016272545,
-0.008651647716760635,
-0.08635010570287704,
0.0006079940358176827,
-0.04259273037314415,
0.01941421441733837,
0.05249221250414848,
0.0019380419980734587,
-0.011896016076207161,
-0.012478338554501534,
-0.0445476695895195,
-0.015254768542945385,
-0.02137955278158188,
0.007980937138199806,
0.006421145051717758,
0.01566031575202942,
0.04163605719804764,
-0.022169848904013634,
-0.03254766762256622,
0.06147661432623863,
-0.02901213802397251,
-0.06222531571984291,
0.0030935881659388542,
-0.023251304402947426,
-0.007559793535619974,
0.07811439782381058,
-0.04546274617314339,
0.05440555512905121,
-0.021545931696891785,
-0.00047118726070038974,
0.04858233034610748,
0.03348354250192642,
0.004094454925507307,
-0.0203188955783844,
0.019746970385313034,
-0.014620453119277954,
0.0017248702934011817,
0.025892551988363266,
-0.007814559154212475,
-0.030426349490880966,
-0.024311963468790054,
-0.00211221887730062,
-0.03862045705318451,
-0.0019978340715169907,
0.00486135296523571,
-0.01612825319170952,
0.0035693247336894274,
0.027202777564525604,
0.03248527646064758,
-0.0426759198307991,
0.013663780875504017,
-0.0037928950041532516,
-0.0030935881659388542,
-0.013071059249341488,
0.0007766466005705297,
-0.012062394060194492,
-0.05498787760734558,
-0.008032930083572865,
0.0016429811948910356,
-0.019331026822328568,
-0.026641253381967545,
0.02982322871685028,
-0.00980069488286972,
-0.022668981924653053,
-0.048207979649305344,
0.003670711303129792,
-0.037518203258514404,
0.023771235719323158,
-0.06526171416044235,
0.03656153380870819,
-0.02364645153284073,
0.018904682248830795,
0.025331027805805206,
-0.03514732047915459,
0.009514733217656612,
0.03315078467130661,
0.015639517456293106,
-0.0008149914792738855,
0.0002895364596042782,
-0.002716638380661607,
0.033254772424697876,
-0.029490472748875618,
0.027847493067383766,
-0.0066083199344575405,
0.006161179859191179,
-0.021670714020729065,
-0.018956676125526428,
-0.03889082372188568,
0.04042981564998627,
-0.003798094345256686,
0.09150781482458115,
0.037726178765296936,
0.017220107838511467,
-0.06542808562517166,
0.01658579148352146,
0.036894287914037704,
-0.014641250483691692,
0.006265165749937296,
0.054946284741163254,
-0.05868978425860405,
-0.014672446064651012,
-0.04078337177634239,
0.03774697333574295,
0.047542471438646317,
0.020734839141368866,
0.01469324342906475,
0.01017504557967186,
-0.06122704967856407,
-0.04122011363506317,
-0.02059965766966343,
0.015868287533521652,
-0.03466898575425148,
0.009426345117390156,
0.05744195356965065,
-0.022377820685505867,
-0.015254768542945385,
0.008958407677710056,
-0.004432410001754761
]
|
32,046 | pingouin.power | power_chi2 |
Evaluate power, sample size, effect size or significance level of chi-squared tests.
Parameters
----------
dof : float
Degree of freedom (depends on the chosen test).
w : float
Cohen's w effect size [1]_.
n : int
Total number of observations.
power : float
Test power (= 1 - type II error).
alpha : float
Significance level (type I error probability). The default is 0.05.
Notes
-----
Exactly ONE of the parameters ``w``, ``n``, ``power`` and ``alpha`` must be passed as None,
and that parameter is determined from the others. The degrees of freedom ``dof`` must always
be specified.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to
compute it.
This function is a Python adaptation of the `pwr.chisq.test` function implemented in the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Statistical power is the likelihood that a study will detect an effect when there is an effect
there to be detected. A high statistical power means that there is a low probability of
concluding that there is no effect when there is one. Statistical power is mainly affected by
the effect size and the sample size.
The non-centrality parameter is defined by:
.. math:: \delta = N * w^2
Then the critical value is computed using the percentile point function of the :math:`\chi^2`
distribution with the alpha level and degrees of freedom.
Finally, the power of the chi-squared test is calculated using the survival function of the
non-central :math:`\chi^2` distribution using the previously computed critical value,
non-centrality parameter, and the degrees of freedom of the test.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables (i.e.
sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
Results have been tested against GPower and the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
References
----------
.. [1] Cohen, J. (1988). Statistical power analysis for the behavioral sciences (2nd ed.).
Examples
--------
1. Compute achieved power
>>> from pingouin import power_chi2
>>> print('power: %.4f' % power_chi2(dof=1, w=0.3, n=20))
power: 0.2687
2. Compute required sample size
>>> print('n: %.4f' % power_chi2(dof=3, w=0.3, power=0.80))
n: 121.1396
3. Compute achieved effect size
>>> print('w: %.4f' % power_chi2(dof=2, n=20, power=0.80, alpha=0.05))
w: 0.6941
4. Compute achieved alpha (significance)
>>> print('alpha: %.4f' % power_chi2(dof=1, w=0.5, n=20, power=0.80, alpha=None))
alpha: 0.1630
| def power_chi2(dof, w=None, n=None, power=None, alpha=0.05):
"""
Evaluate power, sample size, effect size or significance level of chi-squared tests.
Parameters
----------
dof : float
Degree of freedom (depends on the chosen test).
w : float
Cohen's w effect size [1]_.
n : int
Total number of observations.
power : float
Test power (= 1 - type II error).
alpha : float
Significance level (type I error probability). The default is 0.05.
Notes
-----
Exactly ONE of the parameters ``w``, ``n``, ``power`` and ``alpha`` must be passed as None,
and that parameter is determined from the others. The degrees of freedom ``dof`` must always
be specified.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to
compute it.
This function is a Python adaptation of the `pwr.chisq.test` function implemented in the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Statistical power is the likelihood that a study will detect an effect when there is an effect
there to be detected. A high statistical power means that there is a low probability of
concluding that there is no effect when there is one. Statistical power is mainly affected by
the effect size and the sample size.
The non-centrality parameter is defined by:
.. math:: \\delta = N * w^2
Then the critical value is computed using the percentile point function of the :math:`\\chi^2`
distribution with the alpha level and degrees of freedom.
Finally, the power of the chi-squared test is calculated using the survival function of the
non-central :math:`\\chi^2` distribution using the previously computed critical value,
non-centrality parameter, and the degrees of freedom of the test.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables (i.e.
sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
Results have been tested against GPower and the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
References
----------
.. [1] Cohen, J. (1988). Statistical power analysis for the behavioral sciences (2nd ed.).
Examples
--------
1. Compute achieved power
>>> from pingouin import power_chi2
>>> print('power: %.4f' % power_chi2(dof=1, w=0.3, n=20))
power: 0.2687
2. Compute required sample size
>>> print('n: %.4f' % power_chi2(dof=3, w=0.3, power=0.80))
n: 121.1396
3. Compute achieved effect size
>>> print('w: %.4f' % power_chi2(dof=2, n=20, power=0.80, alpha=0.05))
w: 0.6941
4. Compute achieved alpha (significance)
>>> print('alpha: %.4f' % power_chi2(dof=1, w=0.5, n=20, power=0.80, alpha=None))
alpha: 0.1630
"""
assert isinstance(dof, (int, float))
# Check the number of arguments that are None
n_none = sum([v is None for v in [w, n, power, alpha]])
if n_none != 1:
err = "Exactly one of w, n, power, and alpha must be None."
raise ValueError(err)
# Safety checks
if w is not None:
w = abs(w)
if alpha is not None:
assert 0 < alpha <= 1
if power is not None:
assert 0 < power <= 1
def func(w, n, power, alpha):
k = stats.chi2.ppf(1 - alpha, dof)
nc = n * w**2
return stats.ncx2.sf(k, dof, nc)
# Evaluate missing variable
if power is None:
# Compute achieved power
return func(w, n, power, alpha)
elif n is None:
# Compute required sample size
def _eval_n(n, w, power, alpha):
return func(w, n, power, alpha) - power
try:
return brenth(_eval_n, 1, 1e07, args=(w, power, alpha))
except ValueError: # pragma: no cover
return np.nan
elif w is None:
# Compute achieved effect size
def _eval_w(w, n, power, alpha):
return func(w, n, power, alpha) - power
try:
return brenth(_eval_w, 1e-10, 100, args=(n, power, alpha))
except ValueError: # pragma: no cover
return np.nan
else:
# Compute achieved alpha
def _eval_alpha(alpha, w, n, power):
return func(w, n, power, alpha) - power
try:
return brenth(_eval_alpha, 1e-10, 1 - 1e-10, args=(w, n, power))
except ValueError: # pragma: no cover
return np.nan
| (dof, w=None, n=None, power=None, alpha=0.05) | [
-0.01230639312416315,
0.009951776824891567,
0.03205901011824608,
-0.060857780277729034,
0.05602779611945152,
-0.003891657805070281,
-0.04544208571314812,
-0.022660667076706886,
-0.019843177869915962,
0.02938239276409149,
0.047414328902959824,
0.07542822510004044,
0.05147956311702728,
0.03980710729956627,
-0.051761310547590256,
0.02773214876651764,
0.011038522236049175,
-0.008593344129621983,
-0.013151640072464943,
0.02592090517282486,
-0.02408953756093979,
-0.005871447268873453,
0.06625126302242279,
0.05530329793691635,
-0.026967402547597885,
0.03596324473619461,
0.017830684781074524,
-0.02777239866554737,
-0.048581574112176895,
-0.006736819166690111,
-0.02115129865705967,
-0.054015304893255234,
0.034494124352931976,
0.009267528541386127,
0.019410492852330208,
-0.02272104285657406,
0.013604450970888138,
-0.014399385079741478,
-0.1207495629787445,
0.013735262677073479,
0.010615899227559566,
-0.013383076526224613,
-0.003531924681738019,
-0.02887926995754242,
-0.04648858308792114,
-0.018736306577920914,
-0.03252188116312027,
0.09941714257001877,
-0.03360862657427788,
-0.035842496901750565,
0.03988760709762573,
-0.06701600551605225,
-0.011511458083987236,
-0.0545385517179966,
0.00010832870611920953,
0.0322401337325573,
-0.012054831720888615,
-0.05228456109762192,
0.0746232271194458,
-0.0629105195403099,
0.023143665865063667,
-0.01025365013629198,
0.006112946663051844,
-0.02090979926288128,
-0.019058305770158768,
-0.0033684095833450556,
-0.01207495667040348,
-0.0067116632126271725,
0.028557270765304565,
0.0715239942073822,
0.019501054659485817,
0.03984735533595085,
0.00823612604290247,
-0.029483018442988396,
-0.07273148745298386,
0.027691898867487907,
0.004583452362567186,
-0.037532988935709,
0.025075659155845642,
0.020748799666762352,
-0.015133945271372795,
0.027611399069428444,
-0.01036433782428503,
-0.06383626908063889,
-0.025156158953905106,
0.040410853922367096,
0.04077310115098953,
0.001591127016581595,
-0.00415579741820693,
0.006123009137809277,
-0.06935049593448639,
-0.028818896040320396,
0.04008885473012924,
-0.009871277026832104,
0.03934423252940178,
-0.02183554507791996,
-0.010168119333684444,
0.030187390744686127,
0.0015194319421425462,
0.015053445473313332,
-0.045160334557294846,
0.02978489175438881,
0.03821723535656929,
0.09893414378166199,
0.005896603688597679,
-0.051519814878702164,
-0.05779879167675972,
0.026464279741048813,
0.010077557526528835,
-0.06741850823163986,
-0.08822768181562424,
-0.007325473241508007,
0.008326688781380653,
-0.08573219180107117,
-0.001243972103111446,
-0.006208539940416813,
-0.05373355373740196,
0.04938657209277153,
0.02300279214978218,
0.030589889734983444,
0.02346566505730152,
0.008759374730288982,
0.017870934680104256,
-0.016653377562761307,
0.015667255967855453,
0.02296254225075245,
0.0008370711584575474,
-0.041739098727703094,
0.01296045258641243,
0.008794592693448067,
0.017317499965429306,
-0.003763361368328333,
0.012376829981803894,
0.080378957092762,
-0.014379260130226612,
0.026585029438138008,
0.006123009137809277,
0.01852499507367611,
0.062025025486946106,
-0.04644833132624626,
0.026202654466032982,
-0.015103757381439209,
-0.012718954123556614,
-0.02481403574347496,
0.022177670150995255,
0.018887244164943695,
0.072409488260746,
-0.03851911053061485,
0.009936682879924774,
0.0030967232305556536,
0.009468778036534786,
-0.014540259726345539,
-0.005071481689810753,
-0.04821932688355446,
0.007722940761595964,
-0.022600293159484863,
0.04008885473012924,
-0.04773632809519768,
-0.018867118284106255,
-0.02408953756093979,
0.009997057728469372,
0.014902508817613125,
-0.00904112309217453,
0.02457253634929657,
0.008497750386595726,
0.05007081851363182,
-0.025820281356573105,
-0.007763190660625696,
0.07780297100543976,
-0.0514393150806427,
-0.03801598772406578,
-0.02362666465342045,
0.00931784138083458,
-0.015777943655848503,
-0.03302500396966934,
0.01571756787598133,
-0.06617075949907303,
-0.0582817904651165,
-0.014228323474526405,
-0.03646636754274368,
-0.024934785440564156,
-0.06444001942873001,
-0.07007499784231186,
0.007853752933442593,
-0.0026187561452388763,
0.04483833909034729,
0.050634317100048065,
0.037673864513635635,
-0.018907368183135986,
0.00041601998964324594,
-0.009810902178287506,
-0.05478005111217499,
-0.004935638513416052,
0.011913957074284554,
0.019410492852330208,
0.01455032266676426,
0.0366474911570549,
-0.023304665461182594,
0.03646636754274368,
0.020628049969673157,
0.018887244164943695,
0.0071191927418112755,
0.027229025959968567,
0.0008364422828890383,
0.02362666465342045,
-0.03574186936020851,
-0.004065235145390034,
0.009584496729075909,
0.004311765544116497,
0.012145393528044224,
-0.003816189244389534,
-0.02272104285657406,
-0.012235955335199833,
0.014530197717249393,
0.027229025959968567,
-0.010218432173132896,
0.011451083235442638,
-0.040410853922367096,
-0.027611399069428444,
-0.012618329375982285,
0.02503540925681591,
0.024492036551237106,
0.01593894138932228,
0.07635397464036942,
0.014791821129620075,
0.056068047881126404,
0.034011125564575195,
0.03429287672042847,
0.011451083235442638,
-0.007888971827924252,
-0.034494124352931976,
0.02686677686870098,
0.03427274897694588,
-0.050392817705869675,
-0.020789049565792084,
0.026746027171611786,
-0.017921248450875282,
0.024049287661910057,
-0.02296254225075245,
0.0393039807677269,
-0.03548024594783783,
-0.004248875193297863,
0.002807427430525422,
0.032864004373550415,
-0.022419169545173645,
-0.013815762475132942,
0.04185984656214714,
0.0030288014095276594,
0.017538873478770256,
0.028557270765304565,
0.00814556423574686,
-0.05989178270101547,
-0.015868505463004112,
-0.010726585984230042,
-0.04145735129714012,
0.006555695086717606,
0.003957063890993595,
-0.03998823091387749,
0.021996544674038887,
-0.048782821744680405,
-0.006092821713536978,
-0.01558675616979599,
-0.044516339898109436,
0.02891951985657215,
-0.023063166067004204,
-0.0472533293068409,
-0.02938239276409149,
-0.008281407877802849,
0.0001065206088242121,
0.02666552923619747,
0.07188624143600464,
0.05751704052090645,
0.01377551257610321,
0.02231854386627674,
-0.06914924830198288,
-0.021211672574281693,
0.06947124749422073,
0.017921248450875282,
0.007159442640841007,
0.03429287672042847,
-0.027893148362636566,
-0.0008207196951843798,
-0.03737198933959007,
-0.0020904766861349344,
-0.028114523738622665,
0.033991001546382904,
-0.017850810661911964,
0.005841260310262442,
0.07333523780107498,
-0.012950390577316284,
0.007994627580046654,
0.03159613534808159,
0.0022414138074964285,
-0.011612082831561565,
0.07744071632623672,
0.007964439690113068,
-0.05204306170344353,
-0.04024985432624817,
0.08017770946025848,
0.0582817904651165,
0.041296351701021194,
0.00908640492707491,
0.010218432173132896,
-0.029885517433285713,
-0.01673387736082077,
-0.003944485913962126,
0.07643447071313858,
-0.010525336489081383,
-0.006616069935262203,
0.034695375710725784,
-0.01640181615948677,
0.007546847686171532,
-0.020235614851117134,
0.0016842047916725278,
0.06411802023649216,
-0.10473012179136276,
0.043349094688892365,
0.020477112382650375,
0.023606538772583008,
0.0573962926864624,
-0.0005609823274426162,
0.019168993458151817,
0.10384462028741837,
0.017830684781074524,
0.0013886200031265616,
-0.04664958268404007,
0.006399726960808039,
-0.004533139988780022,
0.041296351701021194,
-0.05663154646754265,
-0.04825957491993904,
0.00757200364023447,
0.04544208571314812,
0.016552751883864403,
-0.04890357330441475,
0.029000019654631615,
0.04761557653546333,
0.021573921665549278,
-0.01640181615948677,
-0.03372937813401222,
0.008095252327620983,
0.04181959852576256,
-0.0030111921951174736,
-0.014258510433137417,
0.0153452567756176,
-0.0445968396961689,
0.03046914003789425,
-0.007687722332775593,
-0.036868866533041,
0.007667597383260727,
0.029664142057299614,
-0.069752998650074,
0.05582654848694801,
0.00013741551083512604,
0.018072184175252914,
0.054981302469968796,
-0.010263713076710701,
-0.03934423252940178,
-0.0007810987299308181,
-0.009775683283805847,
-0.0300263911485672,
0.06126027926802635,
-0.04737407714128494,
0.01443963497877121,
0.00710409926250577,
-0.01911868155002594,
0.013765450567007065,
0.059489283710718155,
-0.031072886660695076,
-0.007189630065113306,
0.042463596910238266,
-0.027229025959968567,
-0.05876478552818298,
-0.021976420655846596,
0.03483624756336212,
-0.005051356740295887,
-0.02233866974711418,
-0.0052576372399926186,
0.009735433384776115,
-0.027873024344444275,
0.027430275455117226,
-0.014037136919796467,
-0.08935467898845673,
0.003858954878523946,
-0.046045832335948944,
0.014399385079741478,
-0.01965199038386345,
0.05574604868888855,
-0.02342541515827179,
-0.028738396242260933,
-0.02616240456700325,
0.026323404163122177,
0.03594312071800232,
0.007043724413961172,
0.03773423656821251,
0.053129807114601135,
0.08420269191265106,
-0.008306563831865788,
-0.07764197140932083,
-0.018333809450268745,
0.0005895974463783205,
0.0015886113978922367,
-0.009227278642356396,
0.013191889971494675,
-0.002342038322240114,
-0.019420554861426353,
-0.035399746149778366,
0.03342750295996666,
-0.014167948625981808,
-0.015133945271372795,
-0.08613468706607819,
0.019923677667975426,
-0.06351426988840103,
-0.00020360766211524606,
-0.055625297129154205,
-0.014882383868098259,
-0.021755045279860497,
0.0017558998661115766,
-0.0030237704049795866,
0.015083632431924343,
0.0393039807677269,
-0.10811110585927963,
0.0540958046913147,
0.04137685149908066,
0.04898407310247421,
-0.011038522236049175,
0.025619031861424446,
-0.0034916747827082872,
0.018575306981801987,
0.00512682506814599,
-0.02801389805972576,
0.009901463985443115,
-0.03725124150514603,
-0.010324087925255299,
-0.0016049629775807261,
-0.07780297100543976,
-0.021533671766519547,
0.014258510433137417,
-0.0025910844560712576,
0.019269617274403572,
-0.019239429384469986,
0.019994115456938744,
0.07957395911216736,
-0.04095422476530075,
-0.02294241636991501,
0.0366474911570549,
0.08975717425346375,
-0.004354530945420265,
-0.044033341109752655,
-0.028114523738622665,
0.054498303681612015,
0.034675247967243195,
0.0582817904651165,
0.014389323070645332,
0.0153452567756176,
0.014429572969675064,
-0.052888307720422745,
0.02710827626287937,
-0.0011471208417788148,
-0.03248163312673569,
0.01719675026834011,
0.026705779135227203,
-0.01808224618434906,
-0.0040476261638104916,
-0.02567940764129162,
0.03318600356578827,
0.046045832335948944,
-0.006193446461111307,
0.042181845754384995,
0.020628049969673157,
0.032401133328676224,
0.046045832335948944,
0.0011534098302945495,
-0.03479599952697754,
0.09458715468645096,
0.02000417746603489,
-0.07486473023891449,
-0.006736819166690111,
0.06113952770829201,
-0.054256804287433624,
0.003614939982071519,
-0.008130470290780067,
0.03596324473619461,
-0.014661009423434734,
-0.011461146175861359,
-0.09112566709518433,
-0.011994456872344017,
-0.0003180681960657239,
0.031254012137651443,
-0.016170378774404526,
0.017055876553058624,
0.0218556709587574,
0.035540621727705,
-0.019108617678284645,
-0.05212356150150299,
0.0051318565383553505,
0.04624708369374275,
0.0184344332665205,
-0.0067116632126271725,
0.0009748011361807585,
0.0016074785962700844,
0.052002809941768646,
-0.038337986916303635,
0.026504529640078545,
-0.032220009714365005,
-0.03499724715948105,
-0.017518749460577965,
0.0019433132838457823,
-0.010163088329136372,
-0.025075659155845642,
0.007793378084897995,
-0.04761557653546333,
0.03409162536263466,
-0.07353648543357849,
0.02865789644420147,
-0.02340528927743435,
-0.016854627057909966,
0.07542822510004044,
0.01364470086991787,
-0.01172276958823204,
0.06013328209519386,
0.00020046313875354826,
0.018836932256817818,
0.01400694902986288,
0.022580167278647423,
-0.031998634338378906,
-0.008749311789870262,
-0.017116250470280647,
0.049950070679187775,
0.026504529640078545,
0.003217472694814205,
-0.042181845754384995,
-0.02459266036748886,
0.021996544674038887,
-0.03497712314128876,
-0.06113952770829201,
-0.06504376232624054,
-0.005197262391448021,
-0.03119363635778427,
-0.005735604092478752,
-0.020145051181316376,
-0.03483624756336212,
0.06210552528500557,
-0.041497599333524704,
0.03958573192358017,
0.04411384090781212,
-0.015073570422828197,
0.016834501177072525,
-0.007788346614688635,
-0.016663439571857452,
0.010676274076104164,
-0.060415029525756836,
-0.012487517669796944,
0.022238044068217278,
0.017518749460577965,
0.03006664104759693,
0.016311252489686012,
-0.025659281760454178,
-0.037875112146139145,
-0.019953865557909012,
-0.03417212516069412,
-0.04077310115098953,
-0.00945871602743864,
-0.06427901983261108,
0.015184257179498672,
-0.02688690274953842,
0.05300905928015709,
0.021272048354148865,
-0.05091606453061104,
-0.029241519048810005,
-0.03517837077379227,
0.13515901565551758,
0.028054147958755493,
-0.0014515103539451957,
-0.02893964573740959,
0.004530624020844698,
0.022419169545173645,
-0.06914924830198288,
0.021755045279860497,
-0.011752957478165627,
0.0035797213204205036,
-0.008950561285018921,
0.013503826223313808,
0.025136033073067665,
0.01704581268131733,
-0.0012295072665438056,
-0.04616658389568329,
0.01708606258034706,
-0.02867802046239376,
0.03543999791145325,
-0.0018363995477557182,
0.008140533231198788,
0.0019747584592550993,
-0.06605000793933868,
0.008935467340052128,
-0.011370583437383175,
-0.02795352414250374,
0.0029357236344367266,
0.04057185351848602,
-0.013674887828528881,
-0.03837823495268822,
-0.02048717625439167,
0.007692753337323666,
-0.036546867340803146,
0.006455070339143276,
0.029724517837166786,
0.05956978350877762,
-0.011461146175861359,
0.0042413282208144665,
-0.035138122737407684,
0.021734921261668205,
-0.02777239866554737,
0.007370754610747099,
-0.00448785861954093,
-0.053572554141283035,
-0.0015898692654445767,
-0.0041054850444197655,
-0.0653657615184784,
0.00727516133338213,
-0.03006664104759693,
-0.04528108611702919,
0.01492263376712799,
-0.0012043510796502233,
0.020648175850510597,
0.020235614851117134,
-0.04974881932139397,
0.009368153288960457,
-0.027007652446627617,
-0.04055172950029373,
-0.011209584772586823,
-0.0062689147889614105,
0.03358850255608559,
0.006857568863779306,
-0.013805699534714222,
-0.058362290263175964,
0.01604962907731533,
0.013081202283501625,
-0.013030890375375748,
-0.03048926405608654,
0.08078145980834961,
-0.010535399429500103,
0.09313816577196121,
0.010515274479985237,
-0.03737198933959007,
-0.0014930180041119456,
0.027852898463606834,
-0.03419225290417671,
-0.04161835089325905,
0.010867460630834103,
-0.06685500591993332,
-0.03145525977015495,
-0.0074411919340491295,
-0.04825957491993904,
0.014137761667370796,
0.011129084974527359,
-0.03075088933110237,
0.05687304213643074,
-0.00834681373089552,
-0.0065657575614750385,
0.011219646781682968,
0.02203679457306862,
0.02571965754032135,
0.047897327691316605,
-0.017498623579740524,
-0.04338934272527695,
0.003386019030585885,
0.07281198352575302,
-0.04978907108306885,
-0.0642387643456459,
-0.021714795380830765,
0.004467733670026064,
-0.03183763474225998,
-0.020426800474524498,
-0.05353230610489845,
-0.03459474816918373,
0.09241366386413574,
-0.049064572900533676,
0.06898824870586395,
-0.008382031694054604,
0.01580812968313694,
0.09973914176225662,
0.0218556709587574,
0.006782100535929203,
0.006928006187081337,
0.07148373872041702,
0.013664825819432735,
0.006233696360141039,
-0.006138102617114782,
-0.06874675303697586,
-0.025639157742261887,
-0.04367109015583992,
0.017317499965429306,
-0.06838450580835342,
-0.004062719643115997,
0.038780733942985535,
-0.03590286895632744,
-0.03226025775074959,
0.004817404318600893,
0.02233866974711418,
-0.038820985704660416,
-0.0027772400062531233,
0.019239429384469986,
0.04133659973740578,
0.0003061190072912723,
0.010676274076104164,
-0.036546867340803146,
-0.03914298489689827,
-0.04520058631896973,
0.03988760709762573,
-0.01629112847149372,
-0.043751589953899384,
0.02095004916191101,
-0.012195705436170101,
0.010142963379621506,
-0.06488276273012161,
0.01173283252865076,
-0.03757323697209358,
0.05981128290295601,
-0.03872035816311836,
0.016019441187381744,
0.045401833951473236,
-0.017247062176465988,
0.011088835075497627,
-0.018384121358394623,
0.004362077917903662,
0.01945074275135994,
0.009871277026832104,
0.010968085378408432,
0.024431660771369934,
-0.021050672978162766,
0.00636953953653574,
-0.06548651307821274,
-0.011622145771980286,
0.008205939084291458,
0.02551840804517269,
-0.03133451193571091,
0.011893832124769688,
-0.06162252649664879,
0.04411384090781212,
-0.02455241046845913,
0.04359059035778046,
0.04793757572770119,
0.07148373872041702,
-0.041054852306842804,
0.010817148722708225,
0.030831389129161835,
0.012004518881440163,
-0.026343530043959618,
0.07301323860883713,
-0.025357408449053764,
0.021976420655846596,
-0.037412241101264954,
0.046327583491802216,
-0.003939454443752766,
0.04226234555244446,
0.024753659963607788,
-0.028154773637652397,
-0.04262459650635719,
-0.0591672845184803,
0.007048755884170532,
0.010676274076104164,
0.012034706771373749,
0.021694671362638474,
0.059247784316539764,
-0.015606881119310856,
0.001719423453323543,
0.05212356150150299,
0.01817280985414982
]
|
32,047 | pingouin.power | power_corr |
Evaluate power, sample size, correlation coefficient or significance level of a correlation
test.
Parameters
----------
r : float
Correlation coefficient.
n : int
Number of observations (sample size).
power : float
Test power (= 1 - type II error).
alpha : float
Significance level (type I error probability). The default is 0.05.
alternative : string
Defines the alternative hypothesis, or tail of the correlation. Must be one of
"two-sided" (default), "greater" or "less". Both "greater" and "less" return a one-sided
p-value. "greater" tests against the alternative hypothesis that the correlation is
positive (greater than zero), "less" tests against the hypothesis that the correlation is
negative.
Notes
-----
Exactly ONE of the parameters ``r``, ``n``, ``power`` and ``alpha`` must be passed as None,
and that parameter is determined from the others.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to
compute it.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables (i.e.
sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
This function is a Python adaptation of the `pwr.r.test` function implemented in the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Examples
--------
1. Compute achieved power given ``r``, ``n`` and ``alpha``
>>> from pingouin import power_corr
>>> print('power: %.4f' % power_corr(r=0.5, n=20))
power: 0.6379
2. Same but one-sided test
>>> print('power: %.4f' % power_corr(r=0.5, n=20, alternative="greater"))
power: 0.7510
>>> print('power: %.4f' % power_corr(r=0.5, n=20, alternative="less"))
power: 0.0000
3. Compute required sample size given ``r``, ``power`` and ``alpha``
>>> print('n: %.4f' % power_corr(r=0.5, power=0.80))
n: 28.2484
4. Compute achieved ``r`` given ``n``, ``power`` and ``alpha`` level
>>> print('r: %.4f' % power_corr(n=20, power=0.80, alpha=0.05))
r: 0.5822
5. Compute achieved alpha level given ``r``, ``n`` and ``power``
>>> print('alpha: %.4f' % power_corr(r=0.5, n=20, power=0.80, alpha=None))
alpha: 0.1377
| def power_corr(r=None, n=None, power=None, alpha=0.05, alternative="two-sided"):
"""
Evaluate power, sample size, correlation coefficient or significance level of a correlation
test.
Parameters
----------
r : float
Correlation coefficient.
n : int
Number of observations (sample size).
power : float
Test power (= 1 - type II error).
alpha : float
Significance level (type I error probability). The default is 0.05.
alternative : string
Defines the alternative hypothesis, or tail of the correlation. Must be one of
"two-sided" (default), "greater" or "less". Both "greater" and "less" return a one-sided
p-value. "greater" tests against the alternative hypothesis that the correlation is
positive (greater than zero), "less" tests against the hypothesis that the correlation is
negative.
Notes
-----
Exactly ONE of the parameters ``r``, ``n``, ``power`` and ``alpha`` must be passed as None,
and that parameter is determined from the others.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to
compute it.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables (i.e.
sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
This function is a Python adaptation of the `pwr.r.test` function implemented in the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Examples
--------
1. Compute achieved power given ``r``, ``n`` and ``alpha``
>>> from pingouin import power_corr
>>> print('power: %.4f' % power_corr(r=0.5, n=20))
power: 0.6379
2. Same but one-sided test
>>> print('power: %.4f' % power_corr(r=0.5, n=20, alternative="greater"))
power: 0.7510
>>> print('power: %.4f' % power_corr(r=0.5, n=20, alternative="less"))
power: 0.0000
3. Compute required sample size given ``r``, ``power`` and ``alpha``
>>> print('n: %.4f' % power_corr(r=0.5, power=0.80))
n: 28.2484
4. Compute achieved ``r`` given ``n``, ``power`` and ``alpha`` level
>>> print('r: %.4f' % power_corr(n=20, power=0.80, alpha=0.05))
r: 0.5822
5. Compute achieved alpha level given ``r``, ``n`` and ``power``
>>> print('alpha: %.4f' % power_corr(r=0.5, n=20, power=0.80, alpha=None))
alpha: 0.1377
"""
# Check the number of arguments that are None
n_none = sum([v is None for v in [r, n, power, alpha]])
if n_none != 1:
raise ValueError("Exactly one of n, r, power, and alpha must be None")
# Safety checks
assert alternative in [
"two-sided",
"greater",
"less",
], "Alternative must be one of 'two-sided' (default), 'greater' or 'less'."
if r is not None:
assert -1 <= r <= 1
if alternative == "two-sided":
r = abs(r)
if alpha is not None:
assert 0 < alpha <= 1
if power is not None:
assert 0 < power <= 1
if n is not None:
if n <= 4:
warnings.warn("Sample size is too small to estimate power (n <= 4). Returning NaN.")
return np.nan
# Define main function
if alternative == "two-sided":
def func(r, n, power, alpha):
dof = n - 2
ttt = stats.t.ppf(1 - alpha / 2, dof)
rc = np.sqrt(ttt**2 / (ttt**2 + dof))
zr = np.arctanh(r) + r / (2 * (n - 1))
zrc = np.arctanh(rc)
power = stats.norm.cdf((zr - zrc) * np.sqrt(n - 3)) + stats.norm.cdf(
(-zr - zrc) * np.sqrt(n - 3)
)
return power
elif alternative == "greater":
def func(r, n, power, alpha):
dof = n - 2
ttt = stats.t.ppf(1 - alpha, dof)
rc = np.sqrt(ttt**2 / (ttt**2 + dof))
zr = np.arctanh(r) + r / (2 * (n - 1))
zrc = np.arctanh(rc)
power = stats.norm.cdf((zr - zrc) * np.sqrt(n - 3))
return power
else: # alternative == "less":
def func(r, n, power, alpha):
r = -r
dof = n - 2
ttt = stats.t.ppf(1 - alpha, dof)
rc = np.sqrt(ttt**2 / (ttt**2 + dof))
zr = np.arctanh(r) + r / (2 * (n - 1))
zrc = np.arctanh(rc)
power = stats.norm.cdf((zr - zrc) * np.sqrt(n - 3))
return power
# Evaluate missing variable
if power is None and n is not None and r is not None:
# Compute achieved power given r, n and alpha
return func(r, n, power=None, alpha=alpha)
elif n is None and power is not None and r is not None:
# Compute required sample size given r, power and alpha
def _eval_n(n, r, power, alpha):
return func(r, n, power, alpha) - power
try:
return brenth(_eval_n, 4 + 1e-10, 1e09, args=(r, power, alpha))
except ValueError: # pragma: no cover
return np.nan
elif r is None and power is not None and n is not None:
# Compute achieved r given sample size, power and alpha level
def _eval_r(r, n, power, alpha):
return func(r, n, power, alpha) - power
try:
if alternative == "two-sided":
return brenth(_eval_r, 1e-10, 1 - 1e-10, args=(n, power, alpha))
else:
return brenth(_eval_r, -1 + 1e-10, 1 - 1e-10, args=(n, power, alpha))
except ValueError: # pragma: no cover
return np.nan
else:
# Compute achieved alpha (significance) level given r, n and power
def _eval_alpha(alpha, r, n, power):
return func(r, n, power, alpha) - power
try:
return brenth(_eval_alpha, 1e-10, 1 - 1e-10, args=(r, n, power))
except ValueError: # pragma: no cover
return np.nan
| (r=None, n=None, power=None, alpha=0.05, alternative='two-sided') | [
-0.017228838056325912,
0.010601592250168324,
0.07520222663879395,
0.01207320112735033,
0.07111776620149612,
-0.0011374937603250146,
-0.07360047847032547,
-0.023185351863503456,
-0.02037227526307106,
0.019100885838270187,
0.03968339040875435,
0.09001842886209488,
0.05566086247563362,
0.033176276832818985,
-0.07396087050437927,
0.012713901698589325,
-0.0434875525534153,
0.00004622241613105871,
-0.02466697245836258,
0.0041170017793774605,
-0.01233348622918129,
0.03227528929710388,
0.02572813257575035,
0.08473265171051025,
-0.007368056569248438,
0.0860140472650528,
0.04168558120727539,
-0.006857498083263636,
-0.0715181976556778,
0.04236632585525513,
-0.01373501867055893,
-0.06479084491729736,
0.010561548173427582,
0.010591581463813782,
-0.0060065677389502525,
-0.038842473179101944,
-0.007428122218698263,
0.00042546523036435246,
-0.17379002273082733,
-0.016367897391319275,
-0.014836222864687443,
-0.0035113394260406494,
0.0014278112212195992,
-0.023465657606720924,
-0.0576230064034462,
-0.06286874413490295,
-0.020762702450156212,
0.029011722654104233,
-0.01937118172645569,
-0.055100247263908386,
0.07011666893959045,
-0.06014576554298401,
0.009705612435936928,
-0.043928030878305435,
-0.02728983946144581,
0.0723591223359108,
0.00433974526822567,
0.02222430147230625,
0.035919275134801865,
-0.05754292011260986,
0.011262314394116402,
-0.02362583391368389,
-0.06110681593418121,
-0.004159548319876194,
0.00965055264532566,
0.021543556824326515,
-0.03167463466525078,
-0.0073830727487802505,
0.057382743805646896,
0.04304707050323486,
0.007528231479227543,
0.03385702148079872,
0.027810409665107727,
-0.07107771933078766,
-0.06190769374370575,
0.029372116550803185,
-0.008594397455453873,
-0.06250835210084915,
0.04953416436910629,
-0.02198403887450695,
-0.043687768280506134,
0.017188794910907745,
0.045689959079027176,
-0.024566862732172012,
0.0032210219651460648,
-0.010010946542024612,
0.01018613763153553,
-0.00935022346675396,
0.010451427660882473,
0.005601124372333288,
-0.06102672964334488,
-0.002413889393210411,
0.023645855486392975,
0.019511334598064423,
-0.0052407304756343365,
-0.021363358944654465,
0.039843566715717316,
0.030953846871852875,
0.07572279870510101,
-0.0060215843841433525,
-0.03345658257603645,
0.012143277563154697,
-0.006662284955382347,
0.086734838783741,
0.015186605975031853,
0.004091974347829819,
-0.021303294226527214,
0.04268667474389076,
0.012503672391176224,
-0.020542461425065994,
-0.07239916175603867,
-0.022304387763142586,
0.020822769030928612,
-0.057903312146663666,
-0.034337546676397324,
0.032936014235019684,
-0.07460157573223114,
0.03752102702856064,
0.01928108185529709,
0.016558105126023293,
0.04793241247534752,
0.006602219305932522,
-0.004472390282899141,
0.01931111514568329,
0.0006213043816387653,
0.019110895693302155,
0.028551219031214714,
0.00749819865450263,
-0.016728291288018227,
0.02548786997795105,
0.047211624681949615,
0.03423743695020676,
0.024426709860563278,
0.07668384909629822,
-0.017639286816120148,
0.08681492507457733,
-0.008869698271155357,
0.033877041190862656,
0.036680106073617935,
-0.06078646704554558,
0.027790386229753494,
0.0016305329045280814,
-0.0048803361132740974,
-0.00005197088830755092,
0.05057530105113983,
0.009049895219504833,
0.07083745300769806,
-0.006902547553181648,
0.018129823729395866,
-0.008804627694189548,
0.016788357868790627,
-0.009215076453983784,
0.006161737255752087,
-0.042526498436927795,
0.02847113087773323,
0.001062411698512733,
0.028791481629014015,
-0.015847327187657356,
-0.03379695490002632,
-0.042005930095911026,
-0.005701234098523855,
0.008794615976512432,
0.008654463104903698,
-0.011352413333952427,
0.0427667610347271,
0.00597653491422534,
-0.007117782719433308,
-0.03914279863238335,
0.03185483068227768,
-0.030253080651164055,
0.0016755821416154504,
-0.03315625339746475,
-0.008274046704173088,
-0.03722069784998894,
-0.06126699224114418,
0.02987266331911087,
-0.0218639075756073,
-0.060466114431619644,
-0.04833284765481949,
-0.01347473356872797,
-0.007768494542688131,
-0.05718252435326576,
-0.047612059861421585,
0.007518220692873001,
0.0013251990312710404,
0.013534799218177795,
0.07760485261678696,
-0.032655708491802216,
-0.006101671606302261,
0.0029857647605240345,
-0.04064444079995155,
-0.030673539265990257,
-0.004207100253552198,
0.014716091565787792,
0.023986227810382843,
-0.03461785241961479,
0.03760111331939697,
-0.021623644977808,
0.054859984666109085,
-0.006131704431027174,
0.004867822863161564,
0.018310021609067917,
0.012323474511504173,
0.007518220692873001,
0.010211165063083172,
-0.0437278151512146,
0.013164394535124302,
0.01522664912045002,
0.016578126698732376,
0.024686994031071663,
-0.006296885199844837,
-0.024867190048098564,
0.05005473271012306,
0.013314558193087578,
0.003463787492364645,
-0.007678396068513393,
0.05886436626315117,
-0.03075362741947174,
0.009560453705489635,
0.007763488683849573,
0.020152034237980843,
-0.03425745666027069,
0.026448920369148254,
0.05353854224085808,
0.01183293852955103,
0.0255479346960783,
-0.012243387289345264,
0.03968339040875435,
0.00004720004653790966,
-0.030713584274053574,
-0.037621136754751205,
0.0028506170492619276,
0.02390613965690136,
-0.06891535222530365,
-0.04993459954857826,
-0.01008102297782898,
-0.008409194648265839,
0.043928030878305435,
0.010151099413633347,
0.02043234184384346,
-0.026529008522629738,
0.02999279461801052,
0.013084307312965393,
0.04192584380507469,
0.011272325180470943,
0.009740650653839111,
0.045569825917482376,
0.014215543866157532,
0.0060065677389502525,
-0.009320191107690334,
0.008103861473500729,
-0.08505299687385559,
-0.009109960868954659,
0.01668824814260006,
0.0016105109825730324,
0.022284366190433502,
0.0431271567940712,
-0.025207562372088432,
0.046330660581588745,
-0.04448864609003067,
0.0007827308727428317,
0.005340839736163616,
-0.035218510776758194,
0.007403094787150621,
-0.015707174316048622,
-0.07303986698389053,
-0.010811822488904,
-0.0067173452116549015,
0.01707867532968521,
0.036159537732601166,
0.07456152886152267,
0.09618517011404037,
-0.007112777326256037,
0.01858031563460827,
-0.03928295522928238,
-0.01903080940246582,
0.07832564413547516,
-0.010391362011432648,
0.017348969355225563,
0.017128728330135345,
-0.03251555189490318,
0.027930540964007378,
-0.047972455620765686,
0.03027310222387314,
-0.042406369000673294,
0.03397715091705322,
-0.009260125458240509,
-0.05401906743645668,
0.05566086247563362,
-0.011362424120306969,
0.03914279863238335,
0.013795084320008755,
0.035578902810811996,
0.008709522895514965,
0.09978911280632019,
-0.023525724187493324,
-0.012864066287875175,
-0.05686217546463013,
0.05373876169323921,
0.017098696902394295,
0.049133725464344025,
-0.04168558120727539,
0.09330201894044876,
-0.04512934759259224,
-0.040123872458934784,
-0.03547879308462143,
0.04661096632480621,
-0.008234003558754921,
-0.01845017448067665,
0.03748098388314247,
-0.014986386522650719,
0.035158444195985794,
-0.001989675685763359,
-0.02344563603401184,
0.062228042632341385,
-0.08176940679550171,
0.042646631598472595,
0.02338557131588459,
0.018860623240470886,
0.057743139564991,
-0.011032062582671642,
0.030433276668190956,
0.06727355718612671,
0.030433276668190956,
-0.0015541993780061603,
-0.04388798773288727,
0.0019333639647811651,
-0.024947278201580048,
0.029392138123512268,
-0.03133426234126091,
-0.04981447011232376,
-0.0008096352685242891,
0.015046452172100544,
0.02835099957883358,
-0.04949411749839783,
0.050615344196558,
0.029191918671131134,
-0.021583599969744682,
-0.01067166868597269,
-0.014045357704162598,
0.0358792319893837,
0.037961509078741074,
-0.0215635783970356,
0.015466911718249321,
-0.026569051668047905,
-0.006417016498744488,
0.07047706097364426,
-0.021823862567543983,
-0.05706239491701126,
0.004762707743793726,
0.003659000853076577,
-0.015336769632995129,
0.03063349612057209,
0.015597054734826088,
0.005230719689279795,
0.04216610640287399,
-0.017348969355225563,
0.015557010658085346,
0.01873048022389412,
-0.022784912958741188,
-0.04524947702884674,
0.0359392985701561,
-0.026208657771348953,
0.013014229945838451,
0.0034462683834135532,
-0.04160549119114876,
-0.0009435316896997392,
0.07067728042602539,
-0.0256080012768507,
-0.042126063257455826,
0.018990764394402504,
-0.06270857155323029,
-0.02086281217634678,
-0.01464601419866085,
-0.00971562322229147,
-0.0177594181150198,
-0.017789451405405998,
-0.02783043123781681,
0.0427667610347271,
-0.042526498436927795,
0.0016643197741359472,
0.016247766092419624,
-0.04897354915738106,
-0.005521036684513092,
-0.02951226942241192,
0.0031033933628350496,
-0.023525724187493324,
0.04765210300683975,
-0.019721563905477524,
-0.011452523060142994,
-0.02064257115125656,
-0.008974813856184483,
0.0290517657995224,
-0.012814011424779892,
-0.015727195888757706,
0.020262155681848526,
0.06467071175575256,
0.013314558193087578,
-0.0872153639793396,
-0.018340053036808968,
0.006802437826991081,
0.0034012189134955406,
-0.012543715536594391,
-0.027570147067308426,
0.028671350330114365,
-0.016027525067329407,
0.0257881972938776,
-0.003664006246253848,
-0.005656184628605843,
-0.027790386229753494,
-0.09089939296245575,
0.036499910056591034,
-0.014515872113406658,
-0.027610190212726593,
-0.05373876169323921,
0.014315653592348099,
-0.02432660013437271,
0.011422489769756794,
0.015126540325582027,
-0.03397715091705322,
0.03651993349194527,
-0.08401186019182205,
0.027550123631954193,
0.07159829139709473,
0.05413919687271118,
-0.030012818053364754,
0.03772124648094177,
-0.0218639075756073,
-0.014375719241797924,
0.03577912226319313,
-0.01172281801700592,
-0.03309618681669235,
-0.009205064736306667,
-0.0005136866820976138,
0.034878138452768326,
-0.05277770757675171,
-0.0364198237657547,
0.03507835417985916,
-0.036439843475818634,
-0.01982167363166809,
0.03145439177751541,
0.004307209514081478,
0.040304068475961685,
-0.06951601058244705,
-0.048493023961782455,
0.027550123631954193,
0.07780507206916809,
-0.040484268218278885,
-0.056621912866830826,
-0.054459549486637115,
0.021883929148316383,
0.027369927614927292,
0.06242826208472252,
0.046731095761060715,
-0.023465657606720924,
0.031013911589980125,
-0.08257028460502625,
0.029272006824612617,
-0.029312049970030785,
-0.045169390738010406,
0.011582665145397186,
0.017799463123083115,
-0.012693880125880241,
0.0055010151118040085,
-0.02019207924604416,
0.09322193264961243,
0.03976348042488098,
0.030433276668190956,
-0.013845139183104038,
0.005380883812904358,
0.03944312781095505,
-0.00013788514479529113,
-0.0365399532020092,
0.01175285130739212,
0.06971623003482819,
0.033416539430618286,
-0.0729597732424736,
0.010301264002919197,
0.01741904579102993,
-0.055220380425453186,
-0.050415124744176865,
0.010005940683186054,
-0.004647581838071346,
-0.0025577968917787075,
0.00005173625686438754,
-0.055861081928014755,
-0.0439680777490139,
0.03942310810089111,
0.02771029993891716,
-0.00018833093054126948,
-0.01634787581861019,
0.036620043218135834,
0.02308524213731289,
0.07079741358757019,
-0.07572279870510101,
0.01598748192191124,
0.043407462537288666,
-0.005606129765510559,
0.05754292011260986,
-0.031053954735398293,
0.010061001405119896,
0.043407462537288666,
-0.05457967892289162,
0.024707015603780746,
0.02753010205924511,
-0.02636883221566677,
-0.06274861097335815,
0.006497104186564684,
-0.02877146005630493,
0.011963080614805222,
0.0015704672550782561,
-0.013805095106363297,
0.0652313232421875,
-0.040183939039707184,
0.004549975041300058,
0.02712966501712799,
0.02001188136637211,
0.047852322459220886,
-0.024466753005981445,
-0.0027254801243543625,
0.046330660581588745,
0.04765210300683975,
-0.005681212060153484,
0.0034737982787191868,
0.03758109360933304,
-0.013765051029622555,
-0.02098294347524643,
-0.03327638655900955,
0.024426709860563278,
0.042005930095911026,
-0.006402000319212675,
-0.006767399609088898,
-0.04050428792834282,
0.011592675931751728,
-0.034637875854969025,
-0.04156544804573059,
-0.06419018656015396,
0.011792894452810287,
-0.008734550327062607,
-0.0060966662131249905,
0.0054009053856134415,
-0.007983730174601078,
0.10034972429275513,
-0.057022351771593094,
0.021843884140253067,
-0.006417016498744488,
0.030733605846762657,
0.006747378036379814,
0.018159857019782066,
0.010841854847967625,
0.08337116241455078,
-0.05582103505730629,
-0.01698857545852661,
0.030132949352264404,
-0.0025753160007297993,
0.01622774451971054,
-0.01790958270430565,
-0.018800556659698486,
-0.01820991188287735,
-0.04448864609003067,
-0.017168773338198662,
-0.03772124648094177,
-0.019361170008778572,
-0.07299982011318207,
0.00409697974100709,
0.00797872431576252,
0.07904643565416336,
0.009400278329849243,
-0.027429992333054543,
-0.017379002645611763,
-0.05646173655986786,
0.10611603409051895,
0.010196148417890072,
0.0019596428610384464,
-0.020122002810239792,
0.016157668083906174,
0.04733175411820412,
-0.09874797612428665,
-0.025928350165486336,
0.004745188634842634,
0.013965270482003689,
-0.04448864609003067,
0.02302517741918564,
-0.03239542245864868,
0.0024401680566370487,
0.007323007099330425,
-0.03219520300626755,
0.025567956268787384,
-0.04284685105085373,
0.013775061815977097,
-0.03149443864822388,
0.017399024218320847,
-0.024646949023008347,
-0.08289063721895218,
0.004387297201901674,
0.00939527340233326,
-0.0028155785985291004,
0.016518061980605125,
0.03257561847567558,
0.02859126217663288,
-0.05197683349251747,
-0.03069356083869934,
-0.018860623240470886,
-0.018470196053385735,
-0.024887213483452797,
-0.005220708437263966,
0.047371797263622284,
-0.022024082019925117,
0.013644919730722904,
-0.04789236560463905,
-0.0016305329045280814,
-0.03752102702856064,
-0.03914279863238335,
-0.0026128569152206182,
0.010246203280985355,
-0.031774744391441345,
-0.021443447098135948,
-0.031254176050424576,
0.042126063257455826,
0.005541058722883463,
-0.04905363544821739,
0.028150781989097595,
-0.015587043017148972,
0.030953846871852875,
0.014035346917808056,
0.006872514728456736,
0.029031744226813316,
-0.03255559876561165,
-0.02000187151134014,
-0.024566862732172012,
-0.0036564981564879417,
0.02658907324075699,
0.026328789070248604,
-0.0049804458394646645,
-0.035398706793785095,
-0.006206786725670099,
0.06274861097335815,
-0.009910836815834045,
-0.029251985251903534,
0.01625777594745159,
-0.04424838349223137,
0.04653088003396988,
0.002032221993431449,
-0.0359993614256382,
0.009340212680399418,
0.0671534314751625,
-0.034397613257169724,
-0.0033962135203182697,
0.048252761363983154,
-0.033296406269073486,
-0.06054620444774628,
0.02917189709842205,
-0.043928030878305435,
0.0023951188195496798,
-0.001070545520633459,
-0.008674484677612782,
0.05710243806242943,
0.008894725702702999,
-0.0020947905723005533,
0.0066322521306574345,
-0.014395740814507008,
0.009945875033736229,
0.018710458651185036,
-0.03261566162109375,
-0.04120505601167679,
-0.015827305614948273,
0.026609094813466072,
-0.03836194798350334,
-0.04973438009619713,
-0.00882965512573719,
-0.0014465817948803306,
-0.05029499530792236,
-0.0030708578415215015,
-0.027309861034154892,
0.017038630321621895,
0.06174751743674278,
-0.06847487390041351,
0.006241824943572283,
-0.004142029210925102,
-0.005085560958832502,
0.03447769954800606,
0.04296698048710823,
-0.013044263236224651,
-0.006176753900945187,
0.0579834021627903,
-0.002457687398418784,
-0.001844516838900745,
0.02086281217634678,
-0.029011722654104233,
0.0019421236356720328,
-0.007157826796174049,
0.016728291288018227,
-0.038021575659513474,
-0.03774126619100571,
0.011102139949798584,
-0.028571240603923798,
-0.05998558923602104,
0.019631465896964073,
0.050415124744176865,
-0.049013592302799225,
0.011542621068656445,
-0.0013314558891579509,
-0.007918658666312695,
0.012343497015535831,
-0.0009798214305192232,
-0.037501003593206406,
-0.021443447098135948,
-0.026929445564746857,
0.023365547880530357,
-0.017699353396892548,
-0.013164394535124302,
0.03956326097249985,
0.004580007866024971,
-0.008228997699916363,
-0.09210070967674255,
-0.003906772006303072,
-0.007448144257068634,
0.04845298081636429,
-0.059424977749586105,
0.01070170197635889,
-0.01510651782155037,
0.007693412248045206,
0.028751438483595848,
0.0027304855175316334,
0.0516965277493,
0.03051336482167244,
0.03021303564310074,
-0.009895820170640945,
-0.018810568377375603,
0.005250741261988878,
-0.014275609515607357,
-0.04661096632480621,
0.03914279863238335,
0.0010467695537954569,
0.017399024218320847,
-0.02384607493877411,
0.019331136718392372,
-0.03027310222387314,
0.03285592421889305,
-0.01927107200026512,
0.03243546560406685,
0.026168614625930786,
0.04905363544821739,
-0.0655917227268219,
0.018930699676275253,
0.045810092240571976,
-0.01175285130739212,
-0.016147656366229057,
0.0504952147603035,
-0.060706377029418945,
0.020202089101076126,
-0.06386984139680862,
0.024947278201580048,
0.034878138452768326,
-0.03297605738043785,
0.005260752514004707,
-0.005038008559495211,
-0.03824181482195854,
-0.037040501832962036,
0.007493193261325359,
0.016878455877304077,
-0.00774346711114049,
0.007533237338066101,
0.059945546090602875,
-0.034277480095624924,
-0.0002203972399001941,
0.020081957802176476,
0.01023118756711483
]
|
32,048 | pingouin.power | power_rm_anova |
Evaluate power, sample size, effect size or significance level of a balanced one-way
repeated measures ANOVA.
Parameters
----------
eta_squared : float
ANOVA effect size (eta-squared, :math:`\eta^2`).
m : int
Number of repeated measurements.
n : int
Sample size per measurement. All measurements must have the same sample size.
power : float
Test power (= 1 - type II error).
alpha : float
Significance level :math:`\alpha` (type I error probability). The default is 0.05.
corr : float
Average correlation coefficient among repeated measurements. The default is :math:`r=0.5`.
epsilon : float
Epsilon adjustement factor for sphericity. This can be calculated using the
:py:func:`pingouin.epsilon` function.
Notes
-----
Exactly ONE of the parameters ``eta_squared``, ``m``, ``n``, ``power`` and ``alpha`` must be
passed as None, and that parameter is determined from the others.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to
compute it.
Statistical power is the likelihood that a study will detect an effect when there is an effect
there to be detected. A high statistical power means that there is a low probability of
concluding that there is no effect when there is one. Statistical power is mainly affected by
the effect size and the sample size.
GPower uses the :math:`f` effect size instead of the :math:`\eta^2`. The formula to convert
from one to the other are given below:
.. math:: f = \sqrt{\frac{\eta^2}{1 - \eta^2}}
.. math:: \eta^2 = \frac{f^2}{1 + f^2}
Using :math:`\eta^2`, the sample size :math:`N`, the number of repeated measurements
:math:`m`, the epsilon correction factor :math:`\epsilon` (see :py:func:`pingouin.epsilon`),
and the average correlation between the repeated measures :math:`c`, one can then calculate the
non-centrality parameter as follow:
.. math:: \delta = \frac{f^2 * N * m * \epsilon}{1 - c}
Then the critical value of the non-central F-distribution is computed using the percentile
point function of the F-distribution with:
.. math:: q = 1 - \alpha
.. math:: v_1 = (m - 1) * \epsilon
.. math:: v_2 = (N - 1) * v_1
Finally, the power of the ANOVA is calculated using the survival function of the non-central
F-distribution using the previously computed critical value, non-centrality parameter,
and degrees of freedom.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables
(i.e. sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
Results have been tested against GPower and the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Examples
--------
1. Compute achieved power
>>> from pingouin import power_rm_anova
>>> print('power: %.4f' % power_rm_anova(eta_squared=0.1, m=3, n=20))
power: 0.8913
2. Compute required number of groups
>>> print('m: %.4f' % power_rm_anova(eta_squared=0.1, n=20, power=0.90))
m: 3.1347
3. Compute required sample size
>>> print('n: %.4f' % power_rm_anova(eta_squared=0.1, m=3, power=0.80))
n: 15.9979
4. Compute achieved effect size
>>> print('eta-squared: %.4f' % power_rm_anova(n=20, m=4, power=0.80, alpha=0.05))
eta-squared: 0.0680
5. Compute achieved alpha (significance)
>>> print('alpha: %.4f' % power_rm_anova(eta_squared=0.1, n=20, m=4, power=0.80, alpha=None))
alpha: 0.0081
Let's take a more concrete example. First, we'll load a repeated measures
dataset in wide-format. Each row is an observation (e.g. a subject), and
each column a successive repeated measurements (e.g t=0, t=1, ...).
>>> import pingouin as pg
>>> data = pg.read_dataset('rm_anova_wide')
>>> data.head()
Before 1 week 2 week 3 week
0 4.3 5.3 4.8 6.3
1 3.9 2.3 5.6 4.3
2 4.5 2.6 4.1 NaN
3 5.1 4.2 6.0 6.3
4 3.8 3.6 4.8 6.8
Note that this dataset has some missing values. We'll simply delete any row with one or more
missing values, and then compute a repeated measures ANOVA:
>>> data = data.dropna()
>>> pg.rm_anova(data, effsize="n2").round(3)
Source ddof1 ddof2 F p-unc n2 eps
0 Within 3 24 5.201 0.007 0.346 0.694
The repeated measures ANOVA is significant at the 0.05 level. Now, we can
easily compute the power of the ANOVA with the information in the ANOVA table:
>>> # n is the sample size and m is the number of repeated measures
>>> n, m = data.shape
>>> round(pg.power_rm_anova(eta_squared=0.346, m=m, n=n, epsilon=0.694), 3)
0.99
Our ANOVA has a very high statistical power. However, to be even more accurate in our power
calculation, we should also fill in the average correlation among repeated measurements.
Since our dataframe is in wide-format (with each column being a successive measurement), this
can be done by taking the mean of the superdiagonal of the correlation matrix, which is similar
to manually calculating the correlation between each successive pairwise measurements and then
taking the mean. Since correlation coefficients are not normally distributed, we use the
*r-to-z* transform prior to averaging (:py:func:`numpy.arctanh`), and then the *z-to-r*
transform (:py:func:`numpy.tanh`) to convert back to a correlation coefficient. This gives a
more precise estimate of the mean.
>>> import numpy as np
>>> corr = np.diag(data.corr(), k=1)
>>> avgcorr = np.tanh(np.arctanh(corr).mean())
>>> round(avgcorr, 4)
-0.1996
In this example, we're using a fake dataset and the average correlation is negative. However,
it will most likely be positive with real data. Let's now compute the final power of the
repeated measures ANOVA:
>>> round(pg.power_rm_anova(eta_squared=0.346, m=m, n=n, epsilon=0.694, corr=avgcorr), 3)
0.771
| def power_rm_anova(eta_squared=None, m=None, n=None, power=None, alpha=0.05, corr=0.5, epsilon=1):
"""
Evaluate power, sample size, effect size or significance level of a balanced one-way
repeated measures ANOVA.
Parameters
----------
eta_squared : float
ANOVA effect size (eta-squared, :math:`\\eta^2`).
m : int
Number of repeated measurements.
n : int
Sample size per measurement. All measurements must have the same sample size.
power : float
Test power (= 1 - type II error).
alpha : float
Significance level :math:`\\alpha` (type I error probability). The default is 0.05.
corr : float
Average correlation coefficient among repeated measurements. The default is :math:`r=0.5`.
epsilon : float
Epsilon adjustement factor for sphericity. This can be calculated using the
:py:func:`pingouin.epsilon` function.
Notes
-----
Exactly ONE of the parameters ``eta_squared``, ``m``, ``n``, ``power`` and ``alpha`` must be
passed as None, and that parameter is determined from the others.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to
compute it.
Statistical power is the likelihood that a study will detect an effect when there is an effect
there to be detected. A high statistical power means that there is a low probability of
concluding that there is no effect when there is one. Statistical power is mainly affected by
the effect size and the sample size.
GPower uses the :math:`f` effect size instead of the :math:`\\eta^2`. The formula to convert
from one to the other are given below:
.. math:: f = \\sqrt{\\frac{\\eta^2}{1 - \\eta^2}}
.. math:: \\eta^2 = \\frac{f^2}{1 + f^2}
Using :math:`\\eta^2`, the sample size :math:`N`, the number of repeated measurements
:math:`m`, the epsilon correction factor :math:`\\epsilon` (see :py:func:`pingouin.epsilon`),
and the average correlation between the repeated measures :math:`c`, one can then calculate the
non-centrality parameter as follow:
.. math:: \\delta = \\frac{f^2 * N * m * \\epsilon}{1 - c}
Then the critical value of the non-central F-distribution is computed using the percentile
point function of the F-distribution with:
.. math:: q = 1 - \\alpha
.. math:: v_1 = (m - 1) * \\epsilon
.. math:: v_2 = (N - 1) * v_1
Finally, the power of the ANOVA is calculated using the survival function of the non-central
F-distribution using the previously computed critical value, non-centrality parameter,
and degrees of freedom.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables
(i.e. sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
Results have been tested against GPower and the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Examples
--------
1. Compute achieved power
>>> from pingouin import power_rm_anova
>>> print('power: %.4f' % power_rm_anova(eta_squared=0.1, m=3, n=20))
power: 0.8913
2. Compute required number of groups
>>> print('m: %.4f' % power_rm_anova(eta_squared=0.1, n=20, power=0.90))
m: 3.1347
3. Compute required sample size
>>> print('n: %.4f' % power_rm_anova(eta_squared=0.1, m=3, power=0.80))
n: 15.9979
4. Compute achieved effect size
>>> print('eta-squared: %.4f' % power_rm_anova(n=20, m=4, power=0.80, alpha=0.05))
eta-squared: 0.0680
5. Compute achieved alpha (significance)
>>> print('alpha: %.4f' % power_rm_anova(eta_squared=0.1, n=20, m=4, power=0.80, alpha=None))
alpha: 0.0081
Let's take a more concrete example. First, we'll load a repeated measures
dataset in wide-format. Each row is an observation (e.g. a subject), and
each column a successive repeated measurements (e.g t=0, t=1, ...).
>>> import pingouin as pg
>>> data = pg.read_dataset('rm_anova_wide')
>>> data.head()
Before 1 week 2 week 3 week
0 4.3 5.3 4.8 6.3
1 3.9 2.3 5.6 4.3
2 4.5 2.6 4.1 NaN
3 5.1 4.2 6.0 6.3
4 3.8 3.6 4.8 6.8
Note that this dataset has some missing values. We'll simply delete any row with one or more
missing values, and then compute a repeated measures ANOVA:
>>> data = data.dropna()
>>> pg.rm_anova(data, effsize="n2").round(3)
Source ddof1 ddof2 F p-unc n2 eps
0 Within 3 24 5.201 0.007 0.346 0.694
The repeated measures ANOVA is significant at the 0.05 level. Now, we can
easily compute the power of the ANOVA with the information in the ANOVA table:
>>> # n is the sample size and m is the number of repeated measures
>>> n, m = data.shape
>>> round(pg.power_rm_anova(eta_squared=0.346, m=m, n=n, epsilon=0.694), 3)
0.99
Our ANOVA has a very high statistical power. However, to be even more accurate in our power
calculation, we should also fill in the average correlation among repeated measurements.
Since our dataframe is in wide-format (with each column being a successive measurement), this
can be done by taking the mean of the superdiagonal of the correlation matrix, which is similar
to manually calculating the correlation between each successive pairwise measurements and then
taking the mean. Since correlation coefficients are not normally distributed, we use the
*r-to-z* transform prior to averaging (:py:func:`numpy.arctanh`), and then the *z-to-r*
transform (:py:func:`numpy.tanh`) to convert back to a correlation coefficient. This gives a
more precise estimate of the mean.
>>> import numpy as np
>>> corr = np.diag(data.corr(), k=1)
>>> avgcorr = np.tanh(np.arctanh(corr).mean())
>>> round(avgcorr, 4)
-0.1996
In this example, we're using a fake dataset and the average correlation is negative. However,
it will most likely be positive with real data. Let's now compute the final power of the
repeated measures ANOVA:
>>> round(pg.power_rm_anova(eta_squared=0.346, m=m, n=n, epsilon=0.694, corr=avgcorr), 3)
0.771
"""
# Check the number of arguments that are None
n_none = sum([v is None for v in [eta_squared, m, n, power, alpha]])
if n_none != 1:
msg = "Exactly one of eta, m, n, power, and alpha must be None."
raise ValueError(msg)
# Safety checks
assert 0 < epsilon <= 1, "epsilon must be between 0 and 1."
assert -1 < corr < 1, "corr must be between -1 and 1."
if eta_squared is not None:
eta_squared = abs(eta_squared)
f_sq = eta_squared / (1 - eta_squared)
if alpha is not None:
assert 0 < alpha <= 1, "alpha must be between 0 and 1."
if power is not None:
assert 0 < power <= 1, "power must be between 0 and 1."
if n is not None:
assert n > 1, "The sample size n must be > 1."
if m is not None:
assert m > 1, "The number of repeated measures m must be > 1."
def func(f_sq, m, n, power, alpha, corr):
dof1 = (m - 1) * epsilon
dof2 = (n - 1) * dof1
nc = (f_sq * n * m * epsilon) / (1 - corr)
fcrit = stats.f.ppf(1 - alpha, dof1, dof2)
return stats.ncf.sf(fcrit, dof1, dof2, nc)
# Evaluate missing variable
if power is None:
# Compute achieved power
return func(f_sq, m, n, power, alpha, corr)
elif m is None:
# Compute required number of repeated measures
def _eval_m(m, f_sq, n, power, alpha, corr):
return func(f_sq, m, n, power, alpha, corr) - power
try:
return brenth(_eval_m, 2, 100, args=(f_sq, n, power, alpha, corr))
except ValueError: # pragma: no cover
return np.nan
elif n is None:
# Compute required sample size
def _eval_n(n, f_sq, m, power, alpha, corr):
return func(f_sq, m, n, power, alpha, corr) - power
try:
return brenth(_eval_n, 5, 1e6, args=(f_sq, m, power, alp | (eta_squared=None, m=None, n=None, power=None, alpha=0.05, corr=0.5, epsilon=1) | [
0.024374982342123985,
-0.002418131334707141,
0.0607956126332283,
-0.000979254487901926,
0.055427443236112595,
-0.02956857718527317,
-0.060359176248311996,
-0.053812626749277115,
0.019977882504463196,
0.03962843865156174,
-0.00475715845823288,
0.06271593272686005,
0.04792073369026184,
0.04309811070561409,
-0.06332694739103317,
0.031248856335878372,
-0.03419480472803116,
-0.0027863746508955956,
0.024134941399097443,
-0.010190793313086033,
-0.008876028470695019,
0.035416826605796814,
0.0017525654984638095,
0.04874996468424797,
0.0037233494222164154,
0.06838960945606232,
-0.0004947417764924467,
-0.0021999129094183445,
-0.03041962720453739,
0.010278080590069294,
-0.0047271535731852055,
-0.0825737938284874,
0.00164618412964046,
-0.004817168228328228,
0.0287175253033638,
-0.08139541745185852,
-0.005831883288919926,
0.008652354590594769,
-0.16855180263519287,
-0.00915425643324852,
0.008330482989549637,
-0.024920526891946793,
0.016726430505514145,
-0.0023963095154613256,
-0.01642092503607273,
-0.043425437062978745,
0.00818864069879055,
0.10535578429698944,
-0.011707410216331482,
-0.049011826515197754,
0.04301082342863083,
-0.02718999795615673,
0.01662823185324669,
-0.00896331574767828,
-0.008843295276165009,
0.08846569061279297,
-0.024091297760605812,
-0.012132936157286167,
0.07476158440113068,
-0.0769437626004219,
0.008586889132857323,
-0.009770723059773445,
-0.01148919202387333,
-0.03113974817097187,
0.008756007999181747,
-0.017577482387423515,
-0.033998407423496246,
0.011925628408789635,
0.03816637769341469,
0.01902863383293152,
-0.019737843424081802,
0.013671374879777431,
0.04866267740726471,
-0.05101943388581276,
-0.040239449590444565,
0.020719826221466064,
-0.017402907833456993,
-0.05813334882259369,
0.013071274384856224,
0.008532335050404072,
-0.03733714669942856,
0.012111114338040352,
0.0179484523832798,
-0.029219428077340126,
-0.03122703544795513,
0.01603904366493225,
0.018133938312530518,
-0.0037779039703309536,
0.05573294684290886,
-0.054598212242126465,
0.003595146117731929,
0.015329834073781967,
0.01743564009666443,
0.025771578773856163,
-0.03127067908644676,
-0.052110522985458374,
-0.004017943982034922,
0.009934387169778347,
0.05189230665564537,
-0.0329727828502655,
-0.05197959393262863,
-0.027299106121063232,
0.021374480798840523,
0.08715637773275375,
0.014915219508111477,
0.002261286834254861,
-0.04076317325234413,
0.018919523805379868,
0.04844445735216141,
-0.000564639805816114,
-0.09933295845985413,
0.007506708614528179,
-0.023436643183231354,
-0.06162483990192413,
-0.010627229698002338,
0.016191795468330383,
-0.02712453156709671,
0.04730972275137901,
0.009923475794494152,
0.014151454903185368,
0.0706590786576271,
0.026666274294257164,
-0.008565067313611507,
0.02241101674735546,
0.016977382823824883,
-0.005109035409986973,
0.028521127998828888,
-0.04235616698861122,
0.0031341600697487593,
-0.02200731262564659,
0.006944796536117792,
0.026928136125206947,
0.013769573532044888,
0.06433074921369553,
-0.031488899141550064,
0.044996608048677444,
0.05411813408136368,
-0.017042847350239754,
0.003622423391789198,
-0.0859343558549881,
0.013856860809028149,
0.026819026097655296,
-0.0182866919785738,
-0.04279260337352753,
0.011069121770560741,
-0.026055261492729187,
0.06559641659259796,
0.008346849121153355,
0.022138243541121483,
-0.02943764626979828,
0.009705257602036,
-0.018548553809523582,
-0.00299777346663177,
-0.029110318049788475,
0.04787708818912506,
-0.007877679541707039,
0.050670284777879715,
-0.02396036684513092,
-0.04235616698861122,
-0.05961723253130913,
-0.029197605326771736,
0.025356963276863098,
-0.010741794481873512,
0.002135811373591423,
0.013736840337514877,
0.02869570255279541,
0.028368376195430756,
0.004623499698936939,
0.00758854066953063,
-0.041025035083293915,
-0.006159211043268442,
-0.020588895305991173,
-0.022847453132271767,
-0.027342749759554863,
-0.05424906313419342,
0.04294535517692566,
-0.037097107619047165,
-0.0493609756231308,
-0.03358379378914833,
-0.010561764240264893,
-0.042508918792009354,
-0.009105158038437366,
-0.05245967209339142,
-0.024374982342123985,
-0.007397599518299103,
0.0004664415610022843,
0.08205007016658783,
-0.00011243355402257293,
-0.00457712821662426,
-0.017806611955165863,
-0.044996608048677444,
-0.031641650944948196,
0.03766447305679321,
0.037009820342063904,
-0.0011572388466447592,
-0.0446474589407444,
0.0232184249907732,
-0.024985993281006813,
0.06738580018281937,
0.005793695338070393,
-0.03810090944170952,
0.0032760018948465586,
0.01514434814453125,
-0.011260063387453556,
0.003357833717018366,
-0.04495296627283096,
-0.004137963987886906,
0.01567898318171501,
0.01551531907171011,
0.0247895959764719,
0.011156409047544003,
-0.022498304024338722,
0.04674235358834267,
0.033889297395944595,
0.03354014828801155,
-0.031467076390981674,
0.09461944550275803,
-0.014096900820732117,
0.0014525153674185276,
0.024113120511174202,
-0.04325086250901222,
-0.021887293085455894,
-0.057740554213523865,
0.04783344641327858,
0.016115419566631317,
0.04281442612409592,
-0.014478783123195171,
0.061930347234010696,
-0.011423726566135883,
-0.032994601875543594,
-0.017893899232149124,
0.028935743495821953,
-0.022869275882840157,
-0.05656217783689499,
-0.045782193541526794,
0.015275279060006142,
-0.020130636170506477,
0.004825351759791374,
-0.005177228711545467,
-0.005338164512068033,
-0.0247895959764719,
-0.028324732556939125,
0.02463684417307377,
0.07768570631742477,
0.020250655710697174,
-0.011183686554431915,
0.04770251363515854,
0.029721328988671303,
0.003349650651216507,
-0.025029636919498444,
0.04652413725852966,
-0.05403084680438042,
-0.0066611128859221935,
0.03528589382767677,
-0.019672377035021782,
-0.014697001315653324,
0.053812626749277115,
0.0006734079797752202,
0.05416177585721016,
-0.047571584582328796,
0.028128335252404213,
-0.004023399669677019,
-0.0028286543674767017,
-0.018046651035547256,
-0.0271463543176651,
-0.006721123121678829,
-0.01951962523162365,
-0.011003656312823296,
-0.0029841349460184574,
0.0163772813975811,
0.10308631509542465,
0.06773495674133301,
-0.005578204523772001,
0.01554805226624012,
-0.06145026534795761,
0.024113120511174202,
0.051499512046575546,
0.00230765831656754,
-0.022116422653198242,
-0.014904308132827282,
-0.0336492583155632,
0.018515821546316147,
-0.0019489619880914688,
0.011663766577839851,
-0.048400815576314926,
0.03661702573299408,
-0.0000304525310639292,
-0.03131432086229324,
0.06428710371255875,
-0.030746955424547195,
0.04495296627283096,
-0.012416619807481766,
0.03284185007214546,
-0.043469082564115524,
0.07140102237462997,
0.01824304834008217,
-0.03209991008043289,
0.00033329433063045144,
-0.013016720302402973,
0.05171773210167885,
0.049971986562013626,
-0.0017839344218373299,
0.07899501919746399,
-0.033802010118961334,
-0.05320161581039429,
0.014882486313581467,
0.08161363750696182,
-0.002213551662862301,
0.0358969047665596,
-0.03290731459856033,
-0.017151957377791405,
0.05433635041117668,
-0.012558462098240852,
0.007032083813101053,
0.021505411714315414,
-0.05573294684290886,
0.0477898009121418,
-0.009099702350795269,
0.07175017148256302,
0.057827841490507126,
-0.013780483976006508,
0.007719471585005522,
0.0881601870059967,
-0.01954144611954689,
0.03336557373404503,
-0.04857539013028145,
0.018766772001981735,
-0.03893014043569565,
0.022269174456596375,
-0.05660581961274147,
-0.025356963276863098,
-0.06607649475336075,
0.012252956628799438,
0.049055468291044235,
-0.052896108478307724,
0.02472413145005703,
0.01194745022803545,
-0.026709917932748795,
-0.011816519312560558,
-0.0055618383921682835,
0.054729145020246506,
0.08733095228672028,
-0.010534487664699554,
-0.020228834822773933,
-0.013431334868073463,
-0.03502403199672699,
0.06520362198352814,
-0.013474978506565094,
-0.05254695937037468,
0.009165167808532715,
0.012252956628799438,
0.026557164266705513,
0.04482203349471092,
0.03277638554573059,
0.06900061666965485,
0.0399339459836483,
0.0006594283622689545,
0.019661467522382736,
0.0009744809940457344,
-0.0157008059322834,
-0.07323405146598816,
0.049884699285030365,
-0.015569874085485935,
-0.012176579795777798,
0.012874878011643887,
-0.0652909055352211,
-0.015613517723977566,
0.025946153327822685,
-0.0004739428113680333,
-0.06354515999555588,
0.012569372542202473,
-0.04469110444188118,
-0.00439164275303483,
-0.03646427392959595,
0.02858659438788891,
-0.003262363141402602,
-0.023633038625121117,
-0.017021026462316513,
0.03969390317797661,
0.0006004412425681949,
0.05254695937037468,
-0.003295095870271325,
-0.05110672116279602,
-0.017021026462316513,
0.022061867639422417,
0.017151957377791405,
0.015231635421514511,
0.05328890308737755,
-0.03026687540113926,
-0.028412019833922386,
0.0022053683642297983,
-0.015820825472474098,
0.03450030833482742,
-0.0031314322259277105,
0.01242753118276596,
0.01648639142513275,
-0.0010426741791889071,
0.002722273115068674,
-0.140445277094841,
-0.012503907084465027,
0.027604611590504646,
-0.009148801676928997,
-0.03912653774023056,
-0.025029636919498444,
-0.020916221663355827,
-0.07589631527662277,
-0.0365733839571476,
-0.016159063205122948,
-0.025946153327822685,
0.01092728041112423,
-0.07480522245168686,
0.02703724429011345,
-0.00174847396556288,
-0.018297603353857994,
-0.030768776312470436,
0.02723364159464836,
0.010687240399420261,
-0.04305446520447731,
-0.0025026907678693533,
-0.011685588397085667,
0.05490371957421303,
-0.056300316005945206,
0.014587892219424248,
0.05603845417499542,
0.08763646334409714,
-0.020130636170506477,
-0.025269675999879837,
-0.03847188130021095,
-0.020305210724473,
0.00397702818736434,
0.020588895305991173,
-0.027255462482571602,
-0.019312318414449692,
-0.01193653978407383,
0.008843295276165009,
-0.056867681443691254,
-0.053157974034547806,
-0.018166672438383102,
-0.03255816549062729,
0.019214119762182236,
0.021319925785064697,
-0.008363215252757072,
0.06110111624002457,
-0.02079620212316513,
-0.02627347968518734,
0.03257998824119568,
0.06961163133382797,
-0.038777388632297516,
-0.006699301302433014,
-0.019268672913312912,
0.04857539013028145,
0.03519860655069351,
0.06965527683496475,
0.014118722639977932,
0.006666568573564291,
0.029153961688280106,
-0.043556369841098785,
0.0003491492534521967,
-0.038799211382865906,
-0.04141782969236374,
0.023785792291164398,
0.020534340292215347,
-0.05237238481640816,
0.003960661590099335,
-0.016202706843614578,
0.08733095228672028,
0.04224705696105957,
0.0540744885802269,
-0.0006560186739079654,
-0.00015283803804777563,
0.02559700421988964,
-0.05817699432373047,
-0.024091297760605812,
-0.015897201374173164,
0.05822063609957695,
0.017762968316674232,
-0.04634956270456314,
-0.009028781205415726,
0.01943233795464039,
-0.03484945744276047,
-0.004721697885543108,
0.011761965230107307,
0.025989796966314316,
-0.005196322686970234,
0.018930435180664062,
-0.01276576891541481,
0.009088790975511074,
-0.03805726766586304,
-0.010469022206962109,
-0.02241101674735546,
-0.008488691411912441,
0.025771578773856163,
0.013747751712799072,
0.10771254450082779,
-0.05259060487151146,
0.011598301120102406,
0.027342749759554863,
0.022116422653198242,
0.05760962516069412,
-0.03519860655069351,
0.015308012254536152,
0.03692253306508064,
-0.0542927086353302,
-0.012372976168990135,
0.0015179809415712953,
-0.0022271901834756136,
-0.06044646352529526,
-0.019214119762182236,
-0.0329727828502655,
0.003917017951607704,
0.0005482734413817525,
-0.05420542135834694,
0.05359441041946411,
-0.010316269472241402,
0.010021674446761608,
0.034718528389930725,
0.020556161180138588,
0.03535136207938194,
0.010278080590069294,
0.015438943170011044,
0.06533455103635788,
-0.014664268121123314,
-0.033932942897081375,
-0.013856860809028149,
-0.007190292235463858,
-0.008979681879281998,
-0.04971012473106384,
-0.004334360361099243,
0.03890831768512726,
0.026775382459163666,
0.04198519513010979,
-0.012776680290699005,
-0.00956887099891901,
0.012165669351816177,
0.005133585073053837,
-0.061930347234010696,
-0.03137978911399841,
-0.05119400843977928,
0.03251452371478081,
0.03524225205183029,
-0.012492996640503407,
-0.005853705108165741,
0.012743947096168995,
-0.05643124505877495,
-0.023502107709646225,
0.05237238481640816,
0.05180501937866211,
-0.026011617854237556,
-0.013354958966374397,
-0.012198401615023613,
0.062497712671756744,
-0.05516558140516281,
0.010278080590069294,
0.05887529253959656,
0.020076081156730652,
0.03965026140213013,
0.022912919521331787,
-0.04233434423804283,
-0.016595499590039253,
-0.0542927086353302,
0.01559169590473175,
-0.056256670504808426,
-0.002820471301674843,
-0.07035357505083084,
-0.0060282801277935505,
0.02699360065162182,
0.04290171340107918,
0.049971986562013626,
-0.046698711812496185,
-0.006682934705168009,
-0.057827841490507126,
0.06145026534795761,
-0.0008844659314490855,
-0.057827841490507126,
-0.03354014828801155,
0.02943764626979828,
0.027277285233139992,
-0.06891333311796188,
-0.023589394986629486,
0.0019530535209923983,
0.006322874687612057,
-0.05245967209339142,
0.004009760916233063,
-0.03268909826874733,
0.005662764422595501,
0.03526407480239868,
-0.022170977666974068,
0.044341955333948135,
-0.033845655620098114,
0.07074636220932007,
-0.028542950749397278,
0.03290731459856033,
-0.04392733797430992,
-0.07624546438455582,
-0.03886467590928078,
0.024331338703632355,
0.032296303659677505,
-0.0023690322414040565,
0.014849754050374031,
0.04056677594780922,
-0.016104508191347122,
0.021679986268281937,
0.01431511901319027,
-0.029001209884881973,
-0.009699802845716476,
0.01603904366493225,
0.056125741451978683,
-0.023567574098706245,
0.048357170075178146,
-0.018166672438383102,
-0.011434637941420078,
0.00617557717487216,
-0.032339949160814285,
-0.0271463543176651,
-0.014675179496407509,
0.008057709783315659,
-0.06040281802415848,
-0.011347350664436817,
0.008723275735974312,
0.019672377035021782,
-0.03827548399567604,
0.02178909443318844,
-0.03600601479411125,
0.017697501927614212,
-0.00012973758566658944,
-0.009028781205415726,
0.01750110648572445,
-0.01119459792971611,
-0.05328890308737755,
-0.056998614221811295,
-0.0015002506552264094,
0.05660581961274147,
0.010190793313086033,
-0.024440446868538857,
-0.019617823883891106,
-0.028346553444862366,
0.024178585037589073,
0.02236737310886383,
-0.07834035903215408,
0.018723128363490105,
-0.04220341518521309,
-0.001883496530354023,
-0.010316269472241402,
0.002722273115068674,
0.0017252882244065404,
0.08541063219308853,
-0.048182595521211624,
-0.033911120146512985,
0.018232136964797974,
-0.004909911192953587,
-0.004937188699841499,
-0.0018357612425461411,
-0.08427590131759644,
0.014042345806956291,
-0.020512517541646957,
-0.00009964733180822805,
0.036398809403181076,
0.008799651637673378,
-0.016497300937771797,
-0.004748975392431021,
-0.02880481258034706,
-0.027713721618056297,
-0.028826633468270302,
-0.04879360646009445,
0.03917017951607704,
0.015253457240760326,
0.05433635041117668,
0.02474595233798027,
-0.011336439289152622,
0.06703665107488632,
-0.010599953122437,
-0.021374480798840523,
0.0031696204096078873,
0.012482085265219212,
0.020916221663355827,
0.06254135817289352,
-0.06110111624002457,
0.022934740409255028,
-0.024876883253455162,
0.022629234939813614,
0.02793193981051445,
0.06197398900985718,
-0.0012738491641357541,
-0.045127540826797485,
0.007010261993855238,
-0.0010044859955087304,
0.023633038625121117,
0.03179440274834633,
-0.018875880166888237,
-0.0374680794775486,
-0.03912653774023056,
0.0009649339481256902,
-0.008248650468885899,
0.01471882313489914,
0.001633909298107028,
0.015057060867547989,
-0.020512517541646957,
-0.002354029566049576,
0.030005013570189476,
-0.025116924196481705,
0.010136239230632782,
0.010076228529214859,
0.015318922698497772,
-0.0036906166933476925,
0.002690904075279832,
0.012983987107872963,
-0.049055468291044235,
0.016933739185333252,
-0.007419421337544918,
-0.011358261108398438,
-0.02701542340219021,
0.06930612772703171,
0.015297100879251957,
-0.003237813711166382,
-0.030485093593597412,
-0.028455663472414017,
-0.00317780370824039,
0.030659668147563934,
-0.05512193590402603,
0.029328536242246628,
-0.018155761063098907,
0.04255256429314613,
0.007157559506595135,
-0.020305210724473,
0.007435787934809923,
0.03827548399567604,
-0.001087681739591062,
0.0027072704397141933,
-0.011467370204627514,
-0.03450030833482742,
0.03216537460684776,
-0.041897907853126526,
0.04674235358834267,
0.005542744416743517,
0.004833534825593233,
0.0008067257003858685,
-0.005019020289182663,
-0.03135796636343002,
0.01193653978407383,
0.0076976497657597065,
0.0525033175945282,
0.021909115836024284,
0.016300905495882034,
-0.05411813408136368,
-0.01956326887011528,
0.025160567834973335,
0.014435138553380966,
0.026949957013130188,
0.04752793908119202,
-0.08266108483076096,
0.003172348253428936,
-0.06542184203863144,
0.03676978126168251,
0.06009731441736221,
-0.02553153783082962,
0.035569578409194946,
0.018984990194439888,
-0.054510924965143204,
-0.013813217170536518,
-0.025029636919498444,
0.007795847952365875,
-0.047440651804208755,
0.005919170565903187,
0.06598920375108719,
-0.023349355906248093,
0.0025736119132488966,
0.0036251512356102467,
-0.004421647638082504
]
|
32,049 | pingouin.power | power_ttest |
Evaluate power, sample size, effect size or significance level of a one-sample T-test,
a paired T-test or an independent two-samples T-test with equal sample sizes.
Parameters
----------
d : float
Cohen d effect size
n : int
Sample size
In case of a two-sample T-test, sample sizes are assumed to be equal.
Otherwise, see the :py:func:`power_ttest2n` function.
power : float
Test power (= 1 - type II error).
alpha : float
Significance level (type I error probability).
The default is 0.05.
contrast : str
Can be `"one-sample"`, `"two-samples"` or `"paired"`.
Note that `"one-sample"` and `"paired"` have the same behavior.
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of
"two-sided" (default), "greater" or "less".
Notes
-----
Exactly ONE of the parameters ``d``, ``n``, ``power`` and ``alpha`` must be passed as None, and
that parameter is determined from the others.
For a paired T-test, the sample size ``n`` corresponds to the number of pairs. For an
independent two-sample T-test with equal sample sizes, ``n`` corresponds to the sample size of
each group (i.e. number of observations in one group). If the sample sizes are unequal, please
use the :py:func:`power_ttest2n` function instead.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to
compute it.
This function is a Python adaptation of the `pwr.t.test` function implemented in the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Statistical power is the likelihood that a study will detect an effect when there is an effect
there to be detected. A high statistical power means that there is a low probability of
concluding that there is no effect when there is one. Statistical power is mainly affected by
the effect size and the sample size.
The first step is to use the Cohen's d to calculate the non-centrality parameter
:math:`\delta` and degrees of freedom :math:`v`. In case of paired groups, this is:
.. math:: \delta = d * \sqrt n
.. math:: v = n - 1
and in case of independent groups with equal sample sizes:
.. math:: \delta = d * \sqrt{\frac{n}{2}}
.. math:: v = (n - 1) * 2
where :math:`d` is the Cohen d and :math:`n` the sample size.
The critical value is then found using the percent point function of the T distribution with
:math:`q = 1 - alpha` and :math:`v` degrees of freedom.
Finally, the power of the test is given by the survival function of the non-central
distribution using the previously calculated critical value, degrees of freedom and
non-centrality parameter.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables (i.e.
sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
Results have been tested against GPower and the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Examples
--------
1. Compute power of a one-sample T-test given ``d``, ``n`` and ``alpha``
>>> from pingouin import power_ttest
>>> print('power: %.4f' % power_ttest(d=0.5, n=20, contrast='one-sample'))
power: 0.5645
2. Compute required sample size given ``d``, ``power`` and ``alpha``
>>> print('n: %.4f' % power_ttest(d=0.5, power=0.80, alternative='greater'))
n: 50.1508
3. Compute achieved ``d`` given ``n``, ``power`` and ``alpha`` level
>>> print('d: %.4f' % power_ttest(n=20, power=0.80, alpha=0.05, contrast='paired'))
d: 0.6604
4. Compute achieved alpha level given ``d``, ``n`` and ``power``
>>> print('alpha: %.4f' % power_ttest(d=0.5, n=20, power=0.80, alpha=None))
alpha: 0.4430
5. One-sided tests
>>> from pingouin import power_ttest
>>> print('power: %.4f' % power_ttest(d=0.5, n=20, alternative='greater'))
power: 0.4634
>>> print('power: %.4f' % power_ttest(d=0.5, n=20, alternative='less'))
power: 0.0007
| def power_ttest(
d=None, n=None, power=None, alpha=0.05, contrast="two-samples", alternative="two-sided"
):
"""
Evaluate power, sample size, effect size or significance level of a one-sample T-test,
a paired T-test or an independent two-samples T-test with equal sample sizes.
Parameters
----------
d : float
Cohen d effect size
n : int
Sample size
In case of a two-sample T-test, sample sizes are assumed to be equal.
Otherwise, see the :py:func:`power_ttest2n` function.
power : float
Test power (= 1 - type II error).
alpha : float
Significance level (type I error probability).
The default is 0.05.
contrast : str
Can be `"one-sample"`, `"two-samples"` or `"paired"`.
Note that `"one-sample"` and `"paired"` have the same behavior.
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of
"two-sided" (default), "greater" or "less".
Notes
-----
Exactly ONE of the parameters ``d``, ``n``, ``power`` and ``alpha`` must be passed as None, and
that parameter is determined from the others.
For a paired T-test, the sample size ``n`` corresponds to the number of pairs. For an
independent two-sample T-test with equal sample sizes, ``n`` corresponds to the sample size of
each group (i.e. number of observations in one group). If the sample sizes are unequal, please
use the :py:func:`power_ttest2n` function instead.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to
compute it.
This function is a Python adaptation of the `pwr.t.test` function implemented in the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Statistical power is the likelihood that a study will detect an effect when there is an effect
there to be detected. A high statistical power means that there is a low probability of
concluding that there is no effect when there is one. Statistical power is mainly affected by
the effect size and the sample size.
The first step is to use the Cohen's d to calculate the non-centrality parameter
:math:`\\delta` and degrees of freedom :math:`v`. In case of paired groups, this is:
.. math:: \\delta = d * \\sqrt n
.. math:: v = n - 1
and in case of independent groups with equal sample sizes:
.. math:: \\delta = d * \\sqrt{\\frac{n}{2}}
.. math:: v = (n - 1) * 2
where :math:`d` is the Cohen d and :math:`n` the sample size.
The critical value is then found using the percent point function of the T distribution with
:math:`q = 1 - alpha` and :math:`v` degrees of freedom.
Finally, the power of the test is given by the survival function of the non-central
distribution using the previously calculated critical value, degrees of freedom and
non-centrality parameter.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables (i.e.
sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
Results have been tested against GPower and the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Examples
--------
1. Compute power of a one-sample T-test given ``d``, ``n`` and ``alpha``
>>> from pingouin import power_ttest
>>> print('power: %.4f' % power_ttest(d=0.5, n=20, contrast='one-sample'))
power: 0.5645
2. Compute required sample size given ``d``, ``power`` and ``alpha``
>>> print('n: %.4f' % power_ttest(d=0.5, power=0.80, alternative='greater'))
n: 50.1508
3. Compute achieved ``d`` given ``n``, ``power`` and ``alpha`` level
>>> print('d: %.4f' % power_ttest(n=20, power=0.80, alpha=0.05, contrast='paired'))
d: 0.6604
4. Compute achieved alpha level given ``d``, ``n`` and ``power``
>>> print('alpha: %.4f' % power_ttest(d=0.5, n=20, power=0.80, alpha=None))
alpha: 0.4430
5. One-sided tests
>>> from pingouin import power_ttest
>>> print('power: %.4f' % power_ttest(d=0.5, n=20, alternative='greater'))
power: 0.4634
>>> print('power: %.4f' % power_ttest(d=0.5, n=20, alternative='less'))
power: 0.0007
"""
# Check the number of arguments that are None
n_none = sum([v is None for v in [d, n, power, alpha]])
if n_none != 1:
raise ValueError("Exactly one of n, d, power, and alpha must be None.")
# Safety checks
assert alternative in [
"two-sided",
"greater",
"less",
], "Alternative must be one of 'two-sided' (default), 'greater' or 'less'."
assert contrast.lower() in ["one-sample", "paired", "two-samples"]
tsample = 2 if contrast.lower() == "two-samples" else 1
tside = 2 if alternative == "two-sided" else 1
if d is not None and tside == 2:
d = abs(d)
if alpha is not None:
assert 0 < alpha <= 1
if power is not None:
assert 0 < power <= 1
if alternative == "less":
def func(d, n, power, alpha):
dof = (n - 1) * tsample
nc = d * np.sqrt(n / tsample)
tcrit = stats.t.ppf(alpha / tside, dof)
return stats.nct.cdf(tcrit, dof, nc)
elif alternative == "two-sided":
def func(d, n, power, alpha):
dof = (n - 1) * tsample
nc = d * np.sqrt(n / tsample)
tcrit = stats.t.ppf(1 - alpha / tside, dof)
return stats.nct.sf(tcrit, dof, nc) + stats.nct.cdf(-tcrit, dof, nc)
else: # Alternative = 'greater'
def func(d, n, power, alpha):
dof = (n - 1) * tsample
nc = d * np.sqrt(n / tsample)
tcrit = stats.t.ppf(1 - alpha / tside, dof)
return stats.nct.sf(tcrit, dof, nc)
# Evaluate missing variable
if power is None:
# Compute achieved power given d, n and alpha
return func(d, n, power=None, alpha=alpha)
elif n is None:
# Compute required sample size given d, power and alpha
def _eval_n(n, d, power, alpha):
return func(d, n, power, alpha) - power
try:
return brenth(_eval_n, 2 + 1e-10, 1e07, args=(d, power, alpha))
except ValueError: # pragma: no cover
return np.nan
elif d is None:
# Compute achieved d given sample size, power and alpha level
if alternative == "two-sided":
b0, b1 = 1e-07, 10
elif alternative == "less":
b0, b1 = -10, 5
else:
b0, b1 = -5, 10
def _eval_d(d, n, power, alpha):
return func(d, n, power, alpha) - power
try:
return brenth(_eval_d, b0, b1, args=(n, power, alpha))
except ValueError: # pragma: no cover
return np.nan
else:
# Compute achieved alpha (significance) level given d, n and power
def _eval_alpha(alpha, d, n, power):
return func(d, n, power, alpha) - power
try:
return brenth(_eval_alpha, 1e-10, 1 - 1e-10, args=(d, n, power))
except ValueError: # pragma: no cover
return np.nan
| (d=None, n=None, power=None, alpha=0.05, contrast='two-samples', alternative='two-sided') | [
-0.00035136373480781913,
0.03268812224268913,
0.07561837881803513,
-0.017944395542144775,
0.06934093683958054,
-0.00775904068723321,
-0.07908749580383301,
-0.024923916906118393,
-0.016178864985704422,
0.003115489613264799,
0.009462621994316578,
0.09986086934804916,
0.03165564686059952,
0.031779542565345764,
-0.0553818941116333,
0.01843998208642006,
-0.03136655315756798,
0.01796504482626915,
0.0025411760434508324,
0.005606332793831825,
-0.01099584624171257,
0.02711276151239872,
0.04319870471954346,
0.06450895965099335,
-0.021620001643896103,
0.05575358495116234,
0.01161533035337925,
-0.04724600166082382,
-0.0434051975607872,
0.013845473527908325,
-0.0028470465913414955,
-0.06545884162187576,
-0.013256963342428207,
0.02046363055706024,
-0.011873448267579079,
-0.03109811060130596,
-0.0276496484875679,
-0.010355711914598942,
-0.15701861679553986,
0.019245311617851257,
0.00849209725856781,
-0.046461321413517,
0.004101502243429422,
-0.0031645321287214756,
-0.03846997395157814,
-0.04390078783035278,
-0.02486196905374527,
0.04183583706617355,
-0.03361734747886658,
-0.05534059554338455,
0.06397207826375961,
-0.0733056366443634,
0.009514246135950089,
-0.027339905500411987,
-0.07359473407268524,
0.06075076013803482,
0.03113940916955471,
-0.01173922698944807,
0.04708080366253853,
-0.03310111165046692,
0.02203299105167389,
0.02548145316541195,
-0.03708646073937416,
0.009023820981383324,
-0.0479893833398819,
-0.0034020012244582176,
-0.04633742570877075,
-0.0010292473016306758,
0.006762703415006399,
0.04703950509428978,
0.0037298116367310286,
0.011914747767150402,
0.021496104076504707,
-0.04670911654829979,
-0.05418422445654869,
0.03626047819852829,
-0.011574030853807926,
-0.07838541269302368,
0.008326901122927666,
-0.009787851944565773,
-0.03981218859553337,
0.012967870570719242,
0.02990044094622135,
-0.019627327099442482,
-0.015590354800224304,
0.01204896904528141,
0.03285331651568413,
0.01324663870036602,
0.0061896806582808495,
0.013515082187950611,
-0.03200668841600418,
-0.010469283908605576,
0.01999901793897152,
0.009374862536787987,
0.005389513447880745,
-0.03749945014715195,
0.023602351546287537,
0.035661645233631134,
-0.0026947567239403725,
0.000874376273714006,
0.005239804740995169,
-0.003541385056450963,
0.029301606118679047,
0.06909314543008804,
0.006499422714114189,
-0.01789277046918869,
-0.05356474220752716,
0.06587182730436325,
0.009911748580634594,
-0.027938740327954292,
-0.06810197234153748,
-0.03332825377583504,
0.0167983490973711,
-0.06587182730436325,
-0.0037427174393087626,
0.006267115939408541,
-0.025027165189385414,
0.045387547463178635,
-0.03452592343091965,
-0.005508247762918472,
0.06934093683958054,
0.03568229451775551,
-0.019647976383566856,
0.03799503669142723,
-0.02155805379152298,
0.019617002457380295,
0.06116374954581261,
0.02841367945075035,
-0.01750043034553528,
0.008032646030187607,
0.03132525458931923,
0.04753509536385536,
0.02558470144867897,
0.1287701278924942,
-0.0261628869920969,
0.06017257273197174,
-0.0015745225828140974,
0.04980653524398804,
0.05629047006368637,
-0.09688734263181686,
0.028909265995025635,
-0.01293689664453268,
-0.002875439589843154,
0.00024279266654048115,
0.06818456947803497,
-0.010603506118059158,
0.03966764360666275,
-0.02011258900165558,
0.02046363055706024,
0.032254479825496674,
-0.00917869247496128,
-0.020886944606900215,
-0.019720248878002167,
-0.06818456947803497,
0.018202513456344604,
0.004137638956308365,
0.033947739750146866,
-0.043240003287792206,
-0.021929742768406868,
-0.035620346665382385,
0.0035955901257693768,
-0.006907249800860882,
0.0029141572304069996,
0.031345903873443604,
0.026369381695985794,
0.003876939183101058,
-0.027773546054959297,
0.015043143182992935,
0.022735072299838066,
-0.06306350231170654,
0.024159887805581093,
0.012007670477032661,
-0.001241549733094871,
0.0060915956273674965,
-0.01683964766561985,
-0.0172010138630867,
-0.012565205805003643,
-0.07214926928281784,
-0.025543401017785072,
-0.04761769250035286,
-0.018791023641824722,
-0.029528750106692314,
-0.0659957230091095,
0.030457977205514908,
-0.006582020316272974,
-0.0014519162941724062,
0.05930529534816742,
0.014464957639575005,
-0.05901620164513588,
0.012059293687343597,
-0.02428378351032734,
-0.051086802035570145,
-0.010195679031312466,
0.009576194919645786,
0.04699820652604103,
0.009839475154876709,
0.025274958461523056,
-0.01377320010215044,
0.06075076013803482,
0.025791196152567863,
0.013990020379424095,
0.013742226175963879,
0.04245532304048538,
-0.01890459470450878,
0.02682366967201233,
-0.04571793973445892,
-0.004313159268349409,
0.010087269358336926,
-0.04460286721587181,
-0.023024166002869606,
-0.0006685268017463386,
-0.036095283925533295,
0.035145409405231476,
0.05050861835479736,
0.019142065197229385,
-0.04315740615129471,
0.042228177189826965,
-0.025956392288208008,
-0.00673172902315855,
-0.03991543874144554,
-0.004225398879498243,
-0.027918091043829918,
0.03498021140694618,
0.0867277979850769,
0.050136927515268326,
0.027319256216287613,
0.04028712958097458,
0.05352344363927841,
0.004994592163711786,
-0.009885936975479126,
-0.014031318947672844,
0.03915140777826309,
0.012978196144104004,
-0.041175056248903275,
-0.03774724155664444,
0.003660119604319334,
-0.004277022555470467,
-0.032977212220430374,
-0.00976203940808773,
0.008874112740159035,
-0.028289781883358955,
0.012885273434221745,
0.015838148072361946,
0.019038816913962364,
-0.0005130104254931211,
-0.013618329539895058,
0.045676641166210175,
0.010515745729207993,
-0.0034407188650220633,
0.002898670267313719,
0.01435138564556837,
-0.07541188597679138,
0.010298926383256912,
0.015321911312639713,
-0.028475627303123474,
0.03506280854344368,
0.06099855154752731,
-0.015136065892875195,
0.023974042385816574,
-0.051045503467321396,
-0.010964871384203434,
-0.02721600979566574,
-0.05909879878163338,
0.041649993509054184,
-0.046585217118263245,
-0.058561913669109344,
-0.0006814327207393944,
-0.015290937386453152,
-0.0016313085798174143,
0.002798004075884819,
0.0702495202422142,
0.08106984198093414,
-0.02601834014058113,
-0.005283684469759464,
-0.05596008151769638,
0.003876939183101058,
0.10043904930353165,
-0.009586519561707973,
0.011192016303539276,
-0.0065613710321486,
-0.038882963359355927,
0.01032473798841238,
-0.022879619151353836,
0.008079107850790024,
-0.04555274546146393,
0.020855970680713654,
-0.02109343931078911,
-0.052532266825437546,
0.08226751536130905,
-0.003977605141699314,
-0.011315912939608097,
0.012389685958623886,
0.042372725903987885,
-0.0008505003061145544,
0.07590747624635696,
-0.040596868842840195,
-0.05054991692304611,
-0.056414369493722916,
0.04580053687095642,
0.018378034234046936,
0.06488065421581268,
-0.05422552302479744,
0.0614941380918026,
-0.01468177791684866,
-0.07995477318763733,
-0.013835148885846138,
0.05984218046069145,
-0.014609504491090775,
-0.016994519159197807,
0.001759077189490199,
0.0034458814188838005,
0.03911010921001434,
-0.005812827497720718,
-0.02577054686844349,
0.04253792017698288,
-0.08226751536130905,
0.010515745729207993,
0.0027721922378987074,
0.003662700764834881,
0.047741588205099106,
-0.013205340132117271,
0.013855798169970512,
0.09135328233242035,
0.03444332629442215,
0.04720470309257507,
-0.05397773161530495,
0.03277071937918663,
-0.04262051731348038,
0.013318912126123905,
-0.026844318956136703,
-0.04150544852018356,
-0.014950220473110676,
0.03675606846809387,
0.020267460495233536,
-0.05236707255244255,
0.036343079060316086,
-0.0004104083345737308,
-0.008497259579598904,
-0.024655474349856377,
-0.043281301856040955,
0.029590699821710587,
0.05364733934402466,
-0.023127412423491478,
-0.003564615733921528,
0.027422504499554634,
-0.011501758359372616,
0.03607463464140892,
-0.021475454792380333,
0.008053295314311981,
0.0509629063308239,
0.021785197779536247,
0.004093758761882782,
0.02261117659509182,
0.0021965880878269672,
0.022115588188171387,
0.029384205117821693,
0.0261628869920969,
-0.013597680255770683,
0.015311586670577526,
-0.010820325464010239,
-0.03690061345696449,
0.04198038578033447,
-0.023106763139367104,
0.006060621235519648,
0.054349422454833984,
-0.07214926928281784,
0.03018953464925289,
0.04695690795779228,
-0.025935741141438484,
-0.006964035797864199,
0.024779371917247772,
-0.0763617604970932,
-0.02496521733701229,
0.004421568941324949,
0.031738243997097015,
-0.0614115409553051,
-0.030313430353999138,
-0.015993019565939903,
0.029570050537586212,
0.008874112740159035,
0.028806019574403763,
0.009199341759085655,
-0.0598834790289402,
0.02399469166994095,
-0.0291777104139328,
0.009865286760032177,
0.00035297698923386633,
0.05860321223735809,
-0.013071117922663689,
-0.0336792953312397,
0.008486934937536716,
-0.016994519159197807,
0.024985866621136665,
0.011026820167899132,
0.018130239099264145,
0.039254654198884964,
0.043281301856040955,
-0.00218755379319191,
-0.06467416137456894,
0.0021359301172196865,
0.00019262089335825294,
0.012565205805003643,
-0.025419505313038826,
-0.016963545233011246,
0.02428378351032734,
-0.026803020387887955,
0.0232306607067585,
0.0018868459155783057,
-0.031056812033057213,
-0.03382384032011032,
-0.07078640162944794,
0.05509280040860176,
-0.06013127416372299,
-0.01865680143237114,
-0.03958504647016525,
0.0008092013304121792,
-0.06768897920846939,
0.030623173341155052,
-0.00818235520273447,
-0.013060793280601501,
0.05199538171291351,
-0.07978957891464233,
0.005508247762918472,
0.023065464571118355,
0.07718773931264877,
-0.03578554093837738,
0.0035749406088143587,
0.003118070773780346,
-0.02294156700372696,
0.04377688840031624,
0.008837975561618805,
-0.03248162567615509,
-0.020566878840327263,
0.016282111406326294,
0.041897788643836975,
-0.041939087212085724,
-0.04761769250035286,
0.01228643860667944,
-0.0014157796977087855,
-0.003936306573450565,
-0.0076196566224098206,
0.00967427995055914,
0.0717775821685791,
-0.048030681908130646,
-0.007072445470839739,
0.04111310839653015,
0.05662086233496666,
-0.020773373544216156,
-0.057612039148807526,
-0.04670911654829979,
0.01796504482626915,
0.02878537029027939,
0.0672759935259819,
0.05141719430685043,
-0.0479893833398819,
0.008853462524712086,
-0.08185452222824097,
0.021186362951993942,
-0.024593526497483253,
-0.010603506118059158,
-0.019751224666833878,
-0.013360210694372654,
-0.028041988611221313,
0.0076919300481677055,
0.0061845178715884686,
0.03182084113359451,
-0.0007362829055637121,
-0.0005952856736257672,
-0.007609331980347633,
0.009189017117023468,
0.01821283809840679,
0.016375035047531128,
-0.027484452351927757,
0.020164214074611664,
0.08540623635053635,
0.0382634773850441,
-0.06847365945577621,
-0.019286610186100006,
0.04024582728743553,
-0.04257921874523163,
0.029157059267163277,
-0.015043143182992935,
0.0389862097799778,
0.011233314871788025,
-0.0035207357723265886,
-0.027277957648038864,
-0.034938912838697433,
0.038924261927604675,
0.05389513075351715,
-0.03213058412075043,
-0.01370092760771513,
0.004630644805729389,
0.04526365175843239,
0.051954083144664764,
-0.10820325464010239,
-0.0055856830440461636,
-0.0007859706529416144,
-0.017293935641646385,
0.040369726717472076,
0.005399838089942932,
0.025213010609149933,
0.06496325135231018,
-0.041278302669525146,
-0.009555544704198837,
0.03846997395157814,
0.010221490636467934,
-0.03458787128329277,
0.01782049797475338,
-0.024552227929234505,
0.0031877628061920404,
-0.008569533005356789,
-0.02122766152024269,
0.05211927741765976,
-0.01789277046918869,
0.02366429939866066,
-0.003897588700056076,
0.02318936213850975,
0.03640502691268921,
0.022879619151353836,
-0.023148061707615852,
0.04315740615129471,
0.050756413489580154,
0.009937560185790062,
-0.002266279887408018,
0.04090661182999611,
-0.020783698186278343,
-0.040369726717472076,
0.01630276069045067,
0.019441481679677963,
0.06417857110500336,
0.032977212220430374,
-0.028537575155496597,
-0.0037633669562637806,
0.009725903160870075,
-0.0239120926707983,
-0.04224882647395134,
-0.07437941431999207,
0.020670125260949135,
0.010954546742141247,
-0.02769094705581665,
0.01995771937072277,
-0.031056812033057213,
0.08804936707019806,
-0.05447331815958023,
0.02682366967201233,
0.020184863358736038,
0.00605029659345746,
0.03915140777826309,
-0.019173039123415947,
0.017231987789273262,
0.06252661347389221,
-0.055216699838638306,
-0.0056837680749595165,
0.03161434829235077,
0.024696772918105125,
-0.011243639513850212,
0.009080607444047928,
0.016891270875930786,
-0.032646819949150085,
-0.033699944615364075,
-0.039254654198884964,
-0.02109343931078911,
0.002524398500099778,
-0.07739423960447311,
0.029983039945364,
-0.03146980330348015,
0.054060328751802444,
0.010810000821948051,
-0.049889132380485535,
-0.024614175781607628,
-0.043529096990823746,
0.0898665189743042,
0.013380860909819603,
0.010474447160959244,
-0.02736055664718151,
0.02725730836391449,
-0.0052965907379984856,
-0.06203102692961693,
-0.010861624032258987,
-0.0025231079198420048,
0.0024947149213403463,
-0.024800021201372147,
0.012059293687343597,
-0.00040847243508324027,
0.003714324440807104,
0.005838639568537474,
-0.01444430835545063,
0.015838148072361946,
-0.07702254503965378,
0.01484697312116623,
-0.04741119593381882,
0.015404509380459785,
-0.022115588188171387,
-0.04039037600159645,
0.00838368758559227,
-0.009514246135950089,
0.00012163831706857309,
0.029301606118679047,
0.05381253361701965,
0.005905750207602978,
-0.05364733934402466,
0.003159369807690382,
-0.01094422210007906,
-0.0041557070799171925,
-0.006958873476833105,
-0.01694289594888687,
0.06859756261110306,
-0.0180063433945179,
0.0016648640157654881,
-0.09143587946891785,
0.03632242977619171,
0.006401337683200836,
-0.04315740615129471,
-0.01636471040546894,
0.015611004084348679,
-0.022012341767549515,
-0.023602351546287537,
-0.0269269160926342,
0.06265050917863846,
-0.02050492912530899,
-0.045387547463178635,
0.07545318454504013,
-0.00921999104321003,
0.042992208153009415,
0.011770200915634632,
-0.04072076827287674,
0.020628826692700386,
-0.011078444309532642,
-0.016591854393482208,
-0.09085769206285477,
-0.010159541852772236,
0.03838737681508064,
-0.00011228152288822457,
-0.002310160081833601,
-0.03853192180395126,
-0.0254401545971632,
0.04613092914223671,
-0.03900685906410217,
-0.015311586670577526,
0.04177388921380043,
-0.04761769250035286,
0.05666216090321541,
0.05620787292718887,
-0.025274958461523056,
0.03208928555250168,
0.04902185499668121,
-0.01596204563975334,
-0.017768874764442444,
0.014630153775215149,
-0.008698591962456703,
-0.029817843809723854,
0.03999803587794304,
-0.03578554093837738,
-0.030003689229488373,
-0.02086629532277584,
-0.00605029659345746,
0.05575358495116234,
0.0007027274696156383,
0.0025424666237086058,
0.016612503677606583,
-0.005874775815755129,
0.023684948682785034,
0.007790014613419771,
0.003716905601322651,
0.020484279841184616,
-0.005802502855658531,
0.038924261927604675,
0.004411244299262762,
-0.03785048797726631,
-0.003794341115280986,
-0.01257553044706583,
-0.040121931582689285,
-0.016602179035544395,
-0.027236659079790115,
0.021764548495411873,
0.019792523235082626,
-0.02453157678246498,
0.029590699821710587,
0.017428157851099968,
-0.026803020387887955,
0.04551144689321518,
0.028289781883358955,
0.003038054099306464,
-0.0284549780189991,
0.04753509536385536,
-0.01173922698944807,
-0.020350059494376183,
-0.036776717752218246,
-0.0493522472679615,
-0.02195039391517639,
-0.02405663952231407,
-0.011233314871788025,
-0.04918705299496651,
-0.03153175115585327,
-0.0043338085524737835,
-0.03549645096063614,
-0.012802675366401672,
0.04144349694252014,
0.01694289594888687,
-0.08206101506948471,
-0.009230315685272217,
-0.030829668045043945,
-0.01669510081410408,
0.03270877152681351,
0.014196515083312988,
-0.016860296949744225,
-0.029631998389959335,
-0.044437672942876816,
0.03948179632425308,
-0.05695125460624695,
-0.009478109888732433,
0.0025760221760720015,
-0.011357211507856846,
0.018130239099264145,
-0.0614941380918026,
-0.013504757545888424,
-0.027918091043829918,
0.03865581750869751,
-0.0538538321852684,
0.0239120926707983,
-0.0014828904531896114,
-0.017903095111250877,
0.012730401940643787,
0.021186362951993942,
0.011057794094085693,
0.020122913643717766,
0.01966862566769123,
-0.022735072299838066,
-0.007103419862687588,
0.007309914566576481,
-0.006107082590460777,
-0.02659652568399906,
0.01662282831966877,
-0.038738418370485306,
0.007309914566576481,
-0.018491605296730995,
0.01016470417380333,
-0.0322338305413723,
0.0539364330470562,
0.0004549337609205395,
0.02975589409470558,
0.03357604891061783,
0.045057155191898346,
-0.07264485955238342,
0.013783525675535202,
0.04423117637634277,
-0.00814621802419424,
-0.009369699284434319,
0.05629047006368637,
-0.05414292588829994,
0.054927606135606766,
-0.054638512432575226,
-0.043281301856040955,
-0.009297426789999008,
0.06360038369894028,
0.021207012236118317,
0.03171759471297264,
-0.0761965662240982,
-0.027092112228274345,
-0.010092431679368019,
0.022094938904047012,
-0.01379385031759739,
0.051375895738601685,
0.049889132380485535,
-0.041939087212085724,
0.024758722633123398,
-0.00017229406512342393,
0.019327908754348755
]
|
32,050 | pingouin.power | power_ttest2n |
Evaluate power, effect size or significance level of an independent two-samples T-test
with unequal sample sizes.
Parameters
----------
nx, ny : int
Sample sizes. Must be specified. If the sample sizes are equal, you should use the
:py:func:`power_ttest` function instead.
d : float
Cohen d effect size
power : float
Test power (= 1 - type II error).
alpha : float
Significance level (type I error probability). The default is 0.05.
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of "two-sided"
(default), "greater" or "less".
Notes
-----
Exactly ONE of the parameters ``d``, ``power`` and ``alpha`` must be passed as None, and that
parameter is determined from the others.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to compute
it.
This function is a Python adaptation of the `pwr.t2n.test` function implemented in the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Statistical power is the likelihood that a study will detect an effect when there is an effect
there to be detected. A high statistical power means that there is a low probability of
concluding that there is no effect when there is one. Statistical power is mainly affected by
the effect size and the sample size.
The first step is to use the Cohen's d to calculate the non-centrality parameter
:math:`\delta` and degrees of freedom :math:`v`.cIn case of two independent groups with
unequal sample sizes, this is:
.. math:: \delta = d * \sqrt{\frac{n_i * n_j}{n_i + n_j}}
.. math:: v = n_i + n_j - 2
where :math:`d` is the Cohen d, :math:`n` the sample size,
:math:`n_i` the sample size of the first group and
:math:`n_j` the sample size of the second group,
The critical value is then found using the percent point function of the T distribution with
:math:`q = 1 - alpha` and :math:`v` degrees of freedom.
Finally, the power of the test is given by the survival function of the non-central
distribution using the previously calculated critical value, degrees of freedom and
non-centrality parameter.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables (i.e.
sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
Results have been tested against GPower and the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Examples
--------
1. Compute achieved power of a T-test given ``d``, ``n`` and ``alpha``
>>> from pingouin import power_ttest2n
>>> print('power: %.4f' % power_ttest2n(nx=20, ny=15, d=0.5, alternative='greater'))
power: 0.4164
2. Compute achieved ``d`` given ``n``, ``power`` and ``alpha`` level
>>> print('d: %.4f' % power_ttest2n(nx=20, ny=15, power=0.80, alpha=0.05))
d: 0.9859
3. Compute achieved alpha level given ``d``, ``n`` and ``power``
>>> print('alpha: %.4f' % power_ttest2n(nx=20, ny=15, d=0.5, power=0.80, alpha=None))
alpha: 0.5000
| def power_ttest2n(nx, ny, d=None, power=None, alpha=0.05, alternative="two-sided"):
"""
Evaluate power, effect size or significance level of an independent two-samples T-test
with unequal sample sizes.
Parameters
----------
nx, ny : int
Sample sizes. Must be specified. If the sample sizes are equal, you should use the
:py:func:`power_ttest` function instead.
d : float
Cohen d effect size
power : float
Test power (= 1 - type II error).
alpha : float
Significance level (type I error probability). The default is 0.05.
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of "two-sided"
(default), "greater" or "less".
Notes
-----
Exactly ONE of the parameters ``d``, ``power`` and ``alpha`` must be passed as None, and that
parameter is determined from the others.
``alpha`` has a default value of 0.05 so None must be explicitly passed if you want to compute
it.
This function is a Python adaptation of the `pwr.t2n.test` function implemented in the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Statistical power is the likelihood that a study will detect an effect when there is an effect
there to be detected. A high statistical power means that there is a low probability of
concluding that there is no effect when there is one. Statistical power is mainly affected by
the effect size and the sample size.
The first step is to use the Cohen's d to calculate the non-centrality parameter
:math:`\\delta` and degrees of freedom :math:`v`.cIn case of two independent groups with
unequal sample sizes, this is:
.. math:: \\delta = d * \\sqrt{\\frac{n_i * n_j}{n_i + n_j}}
.. math:: v = n_i + n_j - 2
where :math:`d` is the Cohen d, :math:`n` the sample size,
:math:`n_i` the sample size of the first group and
:math:`n_j` the sample size of the second group,
The critical value is then found using the percent point function of the T distribution with
:math:`q = 1 - alpha` and :math:`v` degrees of freedom.
Finally, the power of the test is given by the survival function of the non-central
distribution using the previously calculated critical value, degrees of freedom and
non-centrality parameter.
:py:func:`scipy.optimize.brenth` is used to solve power equations for other variables (i.e.
sample size, effect size, or significance level). If the solving fails, a nan value is
returned.
Results have been tested against GPower and the
`pwr <https://cran.r-project.org/web/packages/pwr/pwr.pdf>`_ R package.
Examples
--------
1. Compute achieved power of a T-test given ``d``, ``n`` and ``alpha``
>>> from pingouin import power_ttest2n
>>> print('power: %.4f' % power_ttest2n(nx=20, ny=15, d=0.5, alternative='greater'))
power: 0.4164
2. Compute achieved ``d`` given ``n``, ``power`` and ``alpha`` level
>>> print('d: %.4f' % power_ttest2n(nx=20, ny=15, power=0.80, alpha=0.05))
d: 0.9859
3. Compute achieved alpha level given ``d``, ``n`` and ``power``
>>> print('alpha: %.4f' % power_ttest2n(nx=20, ny=15, d=0.5, power=0.80, alpha=None))
alpha: 0.5000
"""
# Check the number of arguments that are None
n_none = sum([v is None for v in [d, power, alpha]])
if n_none != 1:
raise ValueError("Exactly one of d, power, and alpha must be None")
# Safety checks
assert alternative in [
"two-sided",
"greater",
"less",
], "Alternative must be one of 'two-sided' (default), 'greater' or 'less'."
tside = 2 if alternative == "two-sided" else 1
if d is not None and tside == 2:
d = abs(d)
if alpha is not None:
assert 0 < alpha <= 1
if power is not None:
assert 0 < power <= 1
if alternative == "less":
def func(d, nx, ny, power, alpha):
dof = nx + ny - 2
nc = d * (1 / np.sqrt(1 / nx + 1 / ny))
tcrit = stats.t.ppf(alpha / tside, dof)
return stats.nct.cdf(tcrit, dof, nc)
elif alternative == "two-sided":
def func(d, nx, ny, power, alpha):
dof = nx + ny - 2
nc = d * (1 / np.sqrt(1 / nx + 1 / ny))
tcrit = stats.t.ppf(1 - alpha / tside, dof)
return stats.nct.sf(tcrit, dof, nc) + stats.nct.cdf(-tcrit, dof, nc)
else: # Alternative = 'greater'
def func(d, nx, ny, power, alpha):
dof = nx + ny - 2
nc = d * (1 / np.sqrt(1 / nx + 1 / ny))
tcrit = stats.t.ppf(1 - alpha / tside, dof)
return stats.nct.sf(tcrit, dof, nc)
# Evaluate missing variable
if power is None:
# Compute achieved power given d, n and alpha
return func(d, nx, ny, power=None, alpha=alpha)
elif d is None:
# Compute achieved d given sample size, power and alpha level
if alternative == "two-sided":
b0, b1 = 1e-07, 10
elif alternative == "less":
b0, b1 = -10, 5
else:
b0, b1 = -5, 10
def _eval_d(d, nx, ny, power, alpha):
return func(d, nx, ny, power, alpha) - power
try:
return brenth(_eval_d, b0, b1, args=(nx, ny, power, alpha))
except ValueError: # pragma: no cover
return np.nan
else:
# Compute achieved alpha (significance) level given d, n and power
def _eval_alpha(alpha, d, nx, ny, power):
return func(d, nx, ny, power, alpha) - power
try:
return brenth(_eval_alpha, 1e-10, 1 - 1e-10, args=(d, nx, ny, power))
except ValueError: # pragma: no cover
return np.nan
| (nx, ny, d=None, power=None, alpha=0.05, alternative='two-sided') | [
-0.008456583134829998,
0.030253710225224495,
0.07896941155195236,
-0.02294325828552246,
0.05860752984881401,
-0.009871176443994045,
-0.0940033346414566,
-0.021497687324881554,
-0.004228291567414999,
0.006174648180603981,
0.028333168476819992,
0.0892949104309082,
0.023521484807133675,
0.02343888208270073,
-0.06195298954844475,
0.014166584238409996,
-0.03066672943532467,
0.013784540817141533,
-0.007558264769613743,
0.023934505879878998,
-0.02719736285507679,
0.01569475792348385,
0.07029599696397781,
0.06839609891176224,
-0.021848754957318306,
0.04477136209607124,
0.03231881186366081,
-0.04964499548077583,
-0.04088897258043289,
-0.0005456380313262343,
-0.020743926987051964,
-0.07401317358016968,
-0.0067632016725838184,
0.012400923296809196,
0.010227406397461891,
-0.01026354543864727,
-0.015828989446163177,
0.009809223935008049,
-0.1568649709224701,
0.01090372633188963,
-0.006804503500461578,
-0.057285863906145096,
0.004104385618120432,
-0.008580489084124565,
-0.04406922683119774,
-0.05856622755527496,
-0.03079063631594181,
0.015529549680650234,
-0.036139246076345444,
-0.04183891788125038,
0.04956239089369774,
-0.0987117663025856,
0.019824957475066185,
-0.011884648352861404,
-0.059763986617326736,
0.0689743310213089,
0.029468972235918045,
0.0018250318244099617,
0.03892713040113449,
-0.046464741230010986,
0.0030124641489237547,
-0.003466786118224263,
-0.05724456161260605,
0.0009970559040084481,
-0.0524948351085186,
0.008084865286946297,
-0.05943356826901436,
-0.01197757851332426,
0.01464155688881874,
0.07260890305042267,
0.000521437672432512,
0.024079062044620514,
0.03977381810545921,
-0.04423443600535393,
-0.0372750498354435,
0.053238268941640854,
-0.016613727435469627,
-0.06657881289720535,
0.022179171442985535,
-0.015488247387111187,
-0.04406922683119774,
0.018647849559783936,
0.0325666218996048,
-0.013887795619666576,
0.0016766027547419071,
0.013154684565961361,
0.0364077091217041,
0.031761232763528824,
-0.011533581651747227,
-0.003015045542269945,
-0.046464741230010986,
-0.01971137709915638,
0.014620905742049217,
-0.008472071029245853,
-0.008002261631190777,
-0.015581177547574043,
0.033351361751556396,
0.029634181410074234,
0.008621791377663612,
-0.010666240006685257,
0.029407018795609474,
-0.008657930418848991,
0.017594648525118828,
0.07983675599098206,
-0.002572339726611972,
-0.024884451180696487,
-0.050553638488054276,
0.06864391267299652,
0.006143671460449696,
-0.029345067217946053,
-0.07492181658744812,
-0.016624052077531815,
0.015446946024894714,
-0.06628970056772232,
-0.01915379986166954,
-0.004824589006602764,
-0.04196282476186752,
0.04609302431344986,
-0.003815271658822894,
-0.0025452354457229376,
0.05076014995574951,
0.04010423645377159,
-0.027672335505485535,
0.03948470577597618,
-0.021332480013370514,
0.008162306621670723,
0.06785917282104492,
0.031203655526041985,
-0.010392613708972931,
-0.0030692543368786573,
0.030769985169172287,
0.034404560923576355,
0.030769985169172287,
0.13728782534599304,
-0.023129116743803024,
0.04811682179570198,
-0.018875010311603546,
0.03874127194285393,
0.07946503907442093,
-0.09739010035991669,
0.027073455974459648,
-0.03851410746574402,
-0.01607680134475231,
-0.01657242514193058,
0.05047103762626648,
-0.012659060768783092,
0.0626964271068573,
-0.016159405931830406,
0.03913363814353943,
0.02517356537282467,
-0.014466023072600365,
-0.016489820554852486,
-0.021125970408320427,
-0.06253121793270111,
0.02422362007200718,
-0.004359941929578781,
0.03795653209090233,
-0.04299537464976311,
0.0021773895714432,
-0.020836856216192245,
-0.0064999014139175415,
-0.02327367290854454,
0.0062779029831290245,
0.02304651215672493,
0.03696528449654579,
-0.005642884876579046,
-0.03411544859409332,
0.003195741679519415,
0.029881993308663368,
-0.0532795712351799,
-0.006205624435096979,
0.0019205426797270775,
-0.015395318157970905,
-0.01140967570245266,
-0.01758432388305664,
-0.018554920330643654,
-0.0036578078288584948,
-0.0579879991710186,
-0.03628380224108696,
-0.017171304672956467,
-0.014806765131652355,
-0.03262857347726822,
-0.060713931918144226,
0.040620509535074234,
-0.013578030280768871,
0.03349591791629791,
0.07541744410991669,
-0.005937161389738321,
-0.06880912184715271,
0.0042902445420622826,
-0.007929982617497444,
-0.02882879227399826,
-0.02105369046330452,
0.022736746817827225,
0.04576260969042778,
0.021125970408320427,
0.031038448214530945,
0.0036758773494511843,
0.0455147959291935,
0.031244957819581032,
0.010883075185120106,
0.031761232763528824,
0.036820728331804276,
0.0009880211437121034,
0.040290094912052155,
-0.0383695513010025,
-0.010310010053217411,
0.010248057544231415,
-0.037873927503824234,
-0.008554675616323948,
-0.014125281944870949,
-0.019205426797270775,
0.01492034550756216,
0.03390893712639809,
0.02647457830607891,
-0.034920834004879,
0.033888284116983414,
0.004669706802815199,
-0.017109351232647896,
-0.026433276012539864,
0.004334127996116877,
-0.02798210084438324,
0.026040907949209213,
0.06554626673460007,
0.046010419726371765,
0.033454615622758865,
0.051338378340005875,
0.07033729553222656,
0.02259219065308571,
-0.013144359923899174,
-0.035457760095596313,
0.035354506224393845,
0.01614907942712307,
-0.03442521020770073,
-0.02095043659210205,
0.004359941929578781,
-0.01690284162759781,
-0.027403872460126877,
-0.010268707759678364,
0.03341331332921982,
-0.045680005103349686,
-0.016644703224301338,
-0.0015062320744618773,
0.004770380444824696,
0.0012190541019663215,
-0.00054951012134552,
0.04278886690735817,
0.010779820382595062,
0.005446700379252434,
0.02072327584028244,
0.010340986773371696,
-0.08202575892210007,
0.018885336816310883,
0.026619134470820427,
-0.045680005103349686,
0.03043956868350506,
0.028684234246611595,
-0.030542824417352676,
0.029468972235918045,
-0.06083783507347107,
-0.003642319468781352,
-0.014445371925830841,
-0.08566033840179443,
0.044110529124736786,
-0.031079750508069992,
-0.06079653650522232,
-0.005947486963123083,
-0.0011835602344945073,
0.013330218382179737,
0.006484413053840399,
0.03981512039899826,
0.0907817855477333,
-0.017594648525118828,
0.007284638937562704,
-0.04361490532755852,
0.00921550765633583,
0.08896449208259583,
-0.021683545783162117,
0.006298554129898548,
-0.006303716916590929,
-0.04369750991463661,
0.006355344317853451,
-0.04873635247349739,
0.0016288473270833492,
-0.05042973533272743,
-0.011182514950633049,
-0.012493853457272053,
-0.0493558831512928,
0.06253121793270111,
-0.018905987963080406,
-0.005555117968469858,
0.012246041558682919,
0.0364077091217041,
0.02674304135143757,
0.07533483952283859,
-0.032731831073760986,
-0.06542235612869263,
-0.049603693187236786,
0.04642344266176224,
0.024017108604311943,
0.05988788977265358,
-0.025442028418183327,
0.05546857789158821,
-0.02837446890771389,
-0.030708031728863716,
-0.012163436971604824,
0.04832333326339722,
-0.004791031125932932,
-0.005870045628398657,
0.013505752198398113,
0.0039133639074862,
0.015622478909790516,
-0.006417297292500734,
-0.030295012518763542,
0.04497786983847618,
-0.08437997102737427,
0.002891139592975378,
0.020062442868947983,
0.01393942255526781,
0.06377027928829193,
-0.005087889265269041,
0.015271412208676338,
0.08747762441635132,
0.040414001792669296,
0.03543711081147194,
-0.037873927503824234,
0.028973348438739777,
-0.014486674219369888,
0.039278194308280945,
-0.018875010311603546,
-0.02500835806131363,
-0.006339855957776308,
0.03171993046998978,
0.008941881358623505,
-0.047745104879140854,
0.022860653698444366,
0.017697904258966446,
-0.014600254595279694,
-0.01276231650263071,
-0.029737435281276703,
0.0034616233315318823,
0.045680005103349686,
-0.03079063631594181,
-0.010568147525191307,
0.027011504396796227,
-0.014693183824419975,
0.031265608966350555,
-0.031162355095148087,
-0.006143671460449696,
0.06633099913597107,
0.009086438454687595,
0.002567176939919591,
0.03428065404295921,
0.0036887843161821365,
0.0051988884806632996,
0.04886025935411453,
0.009881502017378807,
-0.01934998482465744,
0.03351656720042229,
-0.01485839206725359,
-0.06744615733623505,
0.046506043523550034,
-0.019329333677887917,
0.002133506117388606,
0.06038351356983185,
-0.0688917264342308,
0.036696821451187134,
0.0564185231924057,
-0.010883075185120106,
-0.025586584582924843,
0.019422262907028198,
-0.07149375230073929,
-0.03200904652476311,
-0.006153997033834457,
0.011420001275837421,
-0.04526698589324951,
-0.0408063679933548,
-0.02804405428469181,
0.029799388721585274,
0.007837053388357162,
0.024347525089979172,
0.009344575926661491,
-0.06343986093997955,
0.034177400171756744,
-0.0014649301301687956,
0.009282623417675495,
0.008663092739880085,
0.0641832947731018,
-0.022778049111366272,
-0.034734975546598434,
-0.001353931031189859,
0.00002573307756392751,
0.04373881220817566,
0.006468924693763256,
0.013443798758089542,
0.02337692864239216,
0.054146911948919296,
-0.001413302612490952,
-0.049149371683597565,
0.0010099628707394004,
-0.027734288945794106,
0.02882879227399826,
0.009778247214853764,
-0.010501031763851643,
0.01774953119456768,
-0.022344378754496574,
0.023789947852492332,
0.013454124331474304,
-0.01738813892006874,
-0.021745499223470688,
-0.07963024079799652,
0.05232962593436241,
-0.049273278564214706,
-0.03264922648668289,
-0.045349590480327606,
0.03508604317903519,
-0.06178778409957886,
0.03275248035788536,
0.0028679072856903076,
-0.028229912742972374,
0.02500835806131363,
-0.09441635757684708,
0.022344378754496574,
0.01585996523499489,
0.062283407896757126,
-0.06005309894680977,
-0.0017979274271056056,
-0.022798700258135796,
-0.03229815885424614,
0.04791031405329704,
0.0015514061087742448,
-0.03442521020770073,
-0.02327367290854454,
-0.004669706802815199,
0.04687776416540146,
-0.06063132733106613,
-0.035251252353191376,
-0.011564558371901512,
0.017873438075184822,
-0.005513816140592098,
-0.021786801517009735,
0.04340839385986328,
0.08359523862600327,
-0.052412230521440506,
-0.022530237212777138,
0.021580291911959648,
0.0681895911693573,
-0.02412036433815956,
-0.06220080330967903,
-0.052081815898418427,
0.025503981858491898,
0.02787884511053562,
0.092433862388134,
0.04886025935411453,
-0.04435834288597107,
0.0002257089363411069,
-0.07136984169483185,
0.013103057630360126,
-0.0336611233651638,
0.003523576306179166,
-0.01663437858223915,
-0.019897235557436943,
-0.025111611932516098,
0.035870783030986786,
0.0005233737174421549,
0.0035855292808264494,
0.006985199637711048,
0.0006724480772390962,
0.00492009986191988,
0.005926836282014847,
0.003229299560189247,
-0.006050742231309414,
-0.03318615257740021,
0.006200461648404598,
0.0847516879439354,
0.03931949660181999,
-0.0626138225197792,
-0.02098141238093376,
0.033227454870939255,
-0.05047103762626648,
-0.010552659630775452,
0.0002073166542686522,
0.028519026935100555,
-0.001724358182400465,
-0.009447830729186535,
-0.03252531960606575,
-0.015777362510561943,
0.035478413105010986,
0.04576260969042778,
-0.031100401654839516,
-0.005400235764682293,
0.004961402155458927,
0.03820434585213661,
0.0408063679933548,
-0.091029591858387,
0.0008060341933742166,
0.007398219779133797,
-0.010955354198813438,
0.02412036433815956,
-0.01505457703024149,
0.021910708397626877,
0.046629950404167175,
-0.02853967808187008,
0.007005850784480572,
0.043367091566324234,
0.012958500534296036,
-0.03442521020770073,
0.025586584582924843,
-0.025256169959902763,
0.00453547528013587,
-0.008363653905689716,
-0.026061557233333588,
0.05294915661215782,
-0.03454911708831787,
0.028457073494791985,
0.0123389707878232,
0.014992623589932919,
0.05332087352871895,
0.02798210084438324,
-0.023087814450263977,
0.03890647739171982,
0.025545282289385796,
0.021435733884572983,
-0.004096641670912504,
0.05220571905374527,
0.0067632016725838184,
-0.02915920689702034,
0.03925754502415657,
0.024719243869185448,
0.049273278564214706,
0.018585897982120514,
-0.04262365773320198,
0.006205624435096979,
-0.0007853832212276757,
-0.037667419761419296,
-0.059970494359731674,
-0.052081815898418427,
0.030047200620174408,
0.00004715042086900212,
-0.016159405931830406,
0.02725931629538536,
-0.024326873943209648,
0.07120463997125626,
-0.053981706500053406,
0.01758432388305664,
0.036923982203006744,
-0.0025181309320032597,
0.03624249994754791,
-0.012628084979951382,
0.0018521363381296396,
0.06529845297336578,
-0.039112988859415054,
0.005751302465796471,
0.037481557577848434,
0.010717866942286491,
0.009788572788238525,
-0.027094107121229172,
0.006463761907070875,
-0.03236011043190956,
-0.03337201103568077,
-0.05245353281497955,
-0.01945323869585991,
-0.013330218382179737,
-0.054601237177848816,
0.008337840437889099,
-0.004891704767942429,
0.060300908982753754,
0.01160586066544056,
-0.05191660672426224,
-0.006412134505808353,
-0.03723374754190445,
0.08210836350917816,
0.027073455974459648,
-0.01312370877712965,
-0.02843642234802246,
0.02641262486577034,
0.005503490567207336,
-0.0846690908074379,
-0.003100230824202299,
-0.015550200827419758,
0.004463196732103825,
-0.010800471529364586,
0.026040907949209213,
0.005797767546027899,
0.007289801724255085,
-0.003647482255473733,
-0.05501425638794899,
0.011151538230478764,
-0.04530828818678856,
0.004801356699317694,
-0.023583438247442245,
0.023686693981289864,
-0.000993829220533371,
-0.05579899251461029,
-0.008322351612150669,
-0.02376929670572281,
-0.011182514950633049,
0.05534467101097107,
0.059185758233070374,
-0.014342117123305798,
-0.059474870562553406,
-0.004713590256869793,
-0.01686153933405876,
-0.009866014122962952,
0.006561854388564825,
-0.03351656720042229,
0.06158127263188362,
-0.04216933622956276,
-0.004323802422732115,
-0.06129216030240059,
0.045845214277505875,
0.0010661077685654163,
-0.01578768715262413,
-0.023624740540981293,
0.0020276696886867285,
-0.014734486117959023,
-0.004692939110100269,
-0.03795653209090233,
0.04278886690735817,
-0.034074146300554276,
-0.05270134285092354,
0.07529353350400925,
0.0015307551948353648,
0.03409479558467865,
0.017512045800685883,
-0.025111611932516098,
0.04530828818678856,
-0.022055264562368393,
0.002525875112041831,
-0.062159501016139984,
-0.018152225762605667,
0.03461107239127159,
0.0007137500797398388,
-0.011853672564029694,
-0.0470016673207283,
-0.03304159641265869,
0.05034713074564934,
-0.03673812374472618,
-0.020475463941693306,
0.05030582845211029,
-0.03372307866811752,
0.044606152921915054,
0.03341331332921982,
-0.017987018451094627,
0.022055264562368393,
0.03372307866811752,
-0.006468924693763256,
-0.011234141886234283,
0.02719736285507679,
0.003972735721617937,
-0.029303764924407005,
0.04902546480298042,
-0.040620509535074234,
-0.0059784636832773685,
-0.03663486987352371,
0.015736060217022896,
0.052123114466667175,
0.012400923296809196,
0.012297668494284153,
0.014445371925830841,
0.005046587437391281,
0.018875010311603546,
0.012246041558682919,
0.014868717640638351,
0.00002420038617856335,
-0.006567017175257206,
0.053692590445280075,
-0.012731339782476425,
-0.0422932431101799,
-0.015230109915137291,
0.005947486963123083,
-0.03729569911956787,
-0.013898121193051338,
-0.04095092788338661,
0.018379386514425278,
0.014176908880472183,
-0.03043956868350506,
0.03554036468267441,
-0.002000565407797694,
-0.0018082528840750456,
0.028229912742972374,
0.03527190163731575,
-0.014620905742049217,
-0.030976494774222374,
0.04227259010076523,
-0.009814386256039143,
-0.004326384048908949,
-0.021033041179180145,
-0.03985642269253731,
-0.008952206932008266,
-0.01749139465391636,
-0.0013694192748516798,
-0.04518438130617142,
-0.009566574357450008,
0.0040708277374506,
-0.03791522979736328,
-0.016613727435469627,
0.055881597101688385,
0.003794620744884014,
-0.0838843509554863,
-0.0031828349456191063,
-0.0387619212269783,
-0.010186104103922844,
0.032442715018987656,
0.032050348818302155,
-0.013784540817141533,
-0.05439472571015358,
-0.051710095256567,
0.026268068701028824,
-0.050099316984415054,
-0.03171993046998978,
-0.005529304500669241,
0.0139084467664361,
-0.003939177840948105,
-0.07558264583349228,
-0.0008486268925480545,
-0.007661520037800074,
0.050842754542827606,
-0.0743848904967308,
0.032050348818302155,
0.0014481511898338795,
-0.022117218002676964,
0.01575671136379242,
0.018740778788924217,
0.0037042726762592793,
0.04194217547774315,
0.017243582755327225,
-0.0493558831512928,
0.004607753828167915,
0.0065412032417953014,
-0.003079579910263419,
-0.020795553922653198,
0.015601827763020992,
-0.03341331332921982,
-0.015550200827419758,
-0.028725536540150642,
0.002400678349658847,
-0.03043956868350506,
0.04782770946621895,
0.008151981048285961,
0.04340839385986328,
0.02490510232746601,
0.04886025935411453,
-0.06703313440084457,
-0.012008554302155972,
0.05538597330451012,
-0.0005656437133438885,
-0.004347034730017185,
0.039112988859415054,
-0.04675385728478432,
0.05707935616374016,
-0.0439453199505806,
-0.02281935140490532,
-0.007258825469762087,
0.06364636868238449,
0.014290490187704563,
0.04753859341144562,
-0.08264528959989548,
-0.04811682179570198,
-0.01764627732336521,
0.0403313972055912,
0.0010506194084882736,
0.02831251733005047,
0.05881403759121895,
-0.04204542934894562,
0.024409478530287743,
0.011956927366554737,
0.037254396826028824
]
|
32,051 | pingouin.utils | print_table | Pretty display of table.
Parameters
----------
df : :py:class:`pandas.DataFrame`
Dataframe to print (e.g. ANOVA summary)
floatfmt : string
Decimal number formatting
tablefmt : string
Table format (e.g. 'simple', 'plain', 'html', 'latex', 'grid', 'rst').
For a full list of available formats, please refer to
https://pypi.org/project/tabulate/
| def print_table(df, floatfmt=".3f", tablefmt="simple"):
"""Pretty display of table.
Parameters
----------
df : :py:class:`pandas.DataFrame`
Dataframe to print (e.g. ANOVA summary)
floatfmt : string
Decimal number formatting
tablefmt : string
Table format (e.g. 'simple', 'plain', 'html', 'latex', 'grid', 'rst').
For a full list of available formats, please refer to
https://pypi.org/project/tabulate/
"""
if "F" in df.keys():
print("\n=============\nANOVA SUMMARY\n=============\n")
if "A" in df.keys():
print("\n==============\nPOST HOC TESTS\n==============\n")
print(tabulate(df, headers="keys", showindex=False, floatfmt=floatfmt, tablefmt=tablefmt))
print("")
| (df, floatfmt='.3f', tablefmt='simple') | [
0.020420458167791367,
0.0006551261758431792,
-0.03027736209332943,
-0.05624232813715935,
0.014160238206386566,
-0.033683791756629944,
0.011840966530144215,
-0.045841846615076065,
-0.06493959575891495,
0.019242703914642334,
-0.045841846615076065,
-0.027595704421401024,
-0.03044043481349945,
0.005644164048135281,
-0.03319456800818443,
-0.025548221543431282,
0.03362943232059479,
-0.03841292858123779,
0.07820292562246323,
0.02920832298696041,
0.03895650804042816,
0.00886940024793148,
-0.022866565734148026,
-0.07472401857376099,
0.005635104142129421,
0.00265221344307065,
-0.023627575486898422,
-0.05997490510344505,
0.01650668866932392,
0.06040976941585541,
0.04613175615668297,
-0.013362988829612732,
-0.008547782897949219,
0.03078470192849636,
-0.05359691008925438,
-0.01216711476445198,
-0.02312023565173149,
-0.02259477600455284,
-0.04754506051540375,
0.05780058726668358,
-0.021815644577145576,
0.025983085855841637,
0.020583532750606537,
-0.05519140884280205,
-0.04345009848475456,
-0.0004948835703544319,
0.05758315697312355,
0.028845936059951782,
-0.018209902569651604,
-0.051603786647319794,
-0.0024279870558530092,
-0.009884081780910492,
0.008860341273248196,
-0.005458441097289324,
-0.023373905569314957,
-0.020945917814970016,
-0.0027858433313667774,
-0.06780244410037994,
0.044827163219451904,
-0.038557883352041245,
0.015781916677951813,
0.036782193928956985,
-0.021362662315368652,
0.04102211073040962,
-0.008067620918154716,
-0.08508826047182083,
0.03636544942855835,
0.0182552020996809,
-0.01841827481985092,
-0.029135845601558685,
-0.05892398580908775,
0.034390442073345184,
0.023790650069713593,
0.04674781113862991,
-0.04595056176185608,
0.025874370709061623,
-0.06595427542924881,
-0.07602860778570175,
-0.009920320473611355,
0.013263332657516003,
0.024406705051660538,
-0.04859597980976105,
0.06762125343084335,
-0.011125254444777966,
0.02938951551914215,
-0.018916556611657143,
0.01566413976252079,
0.025874370709061623,
0.07157126069068909,
0.0806671530008316,
0.010463899932801723,
-0.020076191052794456,
0.00964853074401617,
-0.04500835761427879,
-0.041819360107183456,
0.013915627263486385,
0.006459532771259546,
-0.004022486042231321,
-0.05522764474153519,
-0.0014631339581683278,
0.03377438709139824,
0.040985871106386185,
0.03082093968987465,
0.015419529750943184,
-0.04076844081282616,
-0.03357507660984993,
-0.026562903076410294,
0.019623208791017532,
0.042217984795570374,
0.05841664597392082,
-0.04250789433717728,
-0.005118703935295343,
0.041855599731206894,
-0.038521647453308105,
0.09081396460533142,
-0.02018490806221962,
-0.016642583534121513,
0.003481171792373061,
0.014857831411063671,
-0.05069781839847565,
0.043232664465904236,
-0.013245212845504284,
0.04145697504281998,
-0.038195498287677765,
-0.035749390721321106,
0.012647275812923908,
-0.01201310008764267,
-0.024406705051660538,
0.023174593225121498,
0.02138078212738037,
0.06849098205566406,
0.01634361408650875,
-0.0271427221596241,
0.032995257526636124,
0.08958185464143753,
-0.0022445290815085173,
0.04939322918653488,
0.002076925477012992,
0.03466223180294037,
-0.005752879660576582,
-0.01201310008764267,
-0.068998321890831,
-0.0382317379117012,
-0.04457349330186844,
0.031020252034068108,
0.008239754475653172,
-0.026200518012046814,
0.055590033531188965,
0.00983878318220377,
-0.017684442922472954,
0.044790927320718765,
0.013018721714615822,
0.006477652117609978,
-0.04801616072654724,
0.0709189623594284,
-0.002159594791010022,
0.014114939607679844,
-0.10117820650339127,
0.014513564296066761,
0.027758777141571045,
0.03589434549212456,
0.030204884707927704,
0.00271563115529716,
0.03308585286140442,
-0.047037720680236816,
0.020456697791814804,
-0.05221984162926674,
0.0445372574031353,
-0.002831141697242856,
-0.011560117825865746,
0.018309559673070908,
-0.02400808036327362,
-0.021290184929966927,
0.06859969347715378,
0.03728953376412392,
0.035260170698165894,
-0.020601650699973106,
0.003413224359974265,
-0.01453168410807848,
-0.07175245136022568,
0.024098677560687065,
-0.018825959414243698,
-0.042725324630737305,
-0.000654559931717813,
-0.029878737404942513,
-0.01859040930867195,
-0.01878972165286541,
0.003372455947101116,
0.000724772282410413,
0.004532091785222292,
-0.06754877418279648,
-0.03391934186220169,
0.012040278874337673,
0.007832069881260395,
0.03808678314089775,
-0.016914373263716698,
0.021145230159163475,
-0.025167716667056084,
0.033502597361803055,
-0.04232669994235039,
0.04265284910798073,
-0.018717244267463684,
0.002767723985016346,
0.01505714375525713,
0.028972771018743515,
0.0057936483062803745,
0.008987176232039928,
-0.04127578064799309,
-0.04500835761427879,
-0.05685838311910629,
-0.010944060981273651,
-0.06925199180841446,
-0.03569503501057625,
-0.022504178807139397,
-0.0017349235713481903,
0.021090872585773468,
0.002688452135771513,
-0.01200404018163681,
-0.0755937471985817,
0.018844079226255417,
0.061678119003772736,
-0.05899646133184433,
-0.00040088966488838196,
0.026490425691008568,
0.006187743041664362,
0.05794554203748703,
0.056314803659915924,
0.016407031565904617,
-0.00046600590576417744,
-0.03339388221502304,
-0.021272065117955208,
0.005594335962086916,
-0.05120516195893288,
0.03895650804042816,
0.04493588209152222,
-0.014341430738568306,
0.0070302910171449184,
0.015428589656949043,
-0.029625065624713898,
0.013716314919292927,
0.04374000430107117,
0.013815971091389656,
0.035604435950517654,
-0.015926869586110115,
-0.003372455947101116,
-0.03805054351687431,
0.011406103149056435,
-0.03114708885550499,
-0.033122092485427856,
-0.005046227015554905,
-0.04326890408992767,
-0.039427611976861954,
0.03094777651131153,
-0.04171064496040344,
-0.033828746527433395,
-0.01668788120150566,
-0.02400808036327362,
0.07229603081941605,
0.03585810586810112,
0.04508083313703537,
-0.053669385612010956,
-0.050371672958135605,
0.006785680539906025,
0.02469661459326744,
0.022304866462945938,
-0.017883755266666412,
-0.05131387710571289,
-0.029190203174948692,
0.023736292496323586,
0.014595101587474346,
0.12582045793533325,
0.011333626694977283,
0.02958882786333561,
0.0008997368277050555,
-0.005168532021343708,
-0.021453259512782097,
0.05359691008925438,
0.01702308841049671,
-0.007216013967990875,
-0.01009245403110981,
0.009684769436717033,
-0.062040504068136215,
-0.004797086585313082,
0.019405776634812355,
0.01114337332546711,
-0.03549572080373764,
-0.016280196607112885,
0.049864333122968674,
0.05464782938361168,
-0.011270208284258842,
0.02681657299399376,
-0.009621351957321167,
0.01269257441163063,
-0.004040605388581753,
-0.020076191052794456,
0.032959017902612686,
0.014549802988767624,
-0.02069224789738655,
-0.00006777045200578868,
0.0009750452009029686,
-0.027541346848011017,
-0.012955304235219955,
0.1130644753575325,
0.048088639974594116,
0.010636032558977604,
0.02331954799592495,
0.014468266628682613,
-0.01757572777569294,
0.01443202793598175,
-0.08530569821596146,
0.028483549132943153,
0.03214364871382713,
-0.013951865956187248,
0.033665671944618225,
0.0068128593266010284,
0.00639158533886075,
-0.028103044256567955,
-0.05145883187651634,
-0.005227420013397932,
-0.014259894378483295,
-0.015247396193444729,
0.0566771924495697,
0.043232664465904236,
0.036111779510974884,
0.07871026545763016,
-0.06888960301876068,
0.01601746678352356,
0.0009246508707292378,
0.017358295619487762,
0.04337761923670769,
-0.017349235713481903,
-0.04718267545104027,
0.0679474025964737,
0.03641980513930321,
-0.026943407952785492,
0.017883755266666412,
-0.04142073541879654,
0.019025271758437157,
-0.07341942936182022,
0.008497954346239567,
0.016461389139294624,
0.011759430170059204,
0.0400436669588089,
-0.015084322541952133,
-0.030531032010912895,
-0.0013204445131123066,
-0.03779687359929085,
0.00801779329776764,
0.022920923307538033,
-0.008941877633333206,
0.0078048910945653915,
0.02993309497833252,
0.03145511448383331,
0.027251437306404114,
-0.010509197600185871,
0.0032909191213548183,
0.030059929937124252,
-0.020130550488829613,
-0.023228950798511505,
0.022069314494729042,
0.03844916820526123,
-0.012312068603932858,
-0.0341186560690403,
-0.001635267399251461,
-0.03997119143605232,
0.009467337280511856,
-0.006464062724262476,
-0.011786608956754208,
0.015365172177553177,
0.06124325469136238,
-0.014758175238966942,
-0.0008963394211605191,
0.03217988833785057,
-0.007451565004885197,
-0.0037959946785122156,
0.05098772794008255,
-0.004332778975367546,
0.007773182354867458,
0.014984666369855404,
-0.046349186450242996,
0.0455881766974926,
0.020764725282788277,
0.0029489172156900167,
0.02455165982246399,
-0.0341186560690403,
-0.03165442869067192,
-0.07972495257854462,
0.041819360107183456,
-0.018681004643440247,
-0.012565739452838898,
-0.049864333122968674,
0.026725977659225464,
0.005050756502896547,
0.0037982596550136805,
0.006459532771259546,
-0.01210369635373354,
-0.017485130578279495,
0.00748327374458313,
-0.046349186450242996,
-0.021815644577145576,
0.024261752143502235,
-0.019949356094002724,
-0.034517280757427216,
-0.06620794534683228,
-0.03910146281123161,
0.053850580006837845,
0.0068128593266010284,
-0.052835896611213684,
-0.029679425060749054,
0.031563833355903625,
0.008769744075834751,
-0.015165859833359718,
-0.02610992081463337,
0.03203493356704712,
0.05135011300444603,
0.03863036260008812,
-0.03511521592736244,
0.024316109716892242,
0.0007627095328643918,
0.008584021590650082,
0.02768629975616932,
-0.04975561425089836,
-0.03337576240301132,
0.08356624096632004,
0.07950751483440399,
-0.019949356094002724,
-0.041855599731206894,
0.027233317494392395,
0.09516260027885437,
0.0184454545378685,
0.0006879674037918448,
-0.014785354025661945,
0.0007496863254345953,
0.006858157459646463,
0.06548317521810532,
-0.0320168137550354,
0.013027781620621681,
0.0039862473495304585,
0.019188346341252327,
0.07135383039712906,
0.04489964246749878,
-0.07943504303693771,
-0.000028983813535887748,
0.008751625195145607,
-0.021870002150535583,
0.049501944333314896,
0.045298267155885696,
-0.02350074052810669,
-0.039572566747665405,
0.041167065501213074,
0.055590033531188965,
-0.01243890356272459,
-0.030132407322525978,
0.004806146025657654,
-0.025330791249871254,
-0.03881155326962471,
0.01846357248723507,
0.021978719159960747,
-0.03600306063890457,
0.06182307377457619,
0.036818429827690125,
0.01210369635373354,
-0.008507014252245426,
0.02226862870156765,
-0.033122092485427856,
-0.06280151754617691,
0.026417948305606842,
0.0005141353467479348,
-0.02732391469180584,
-0.056097373366355896,
0.03308585286140442,
0.015039024874567986,
-0.04997304826974869,
-0.0013589479494839907,
-0.009965619072318077,
0.048813410103321075,
0.011351745575666428,
-0.034535396844148636,
-0.11219474673271179,
0.00564869400113821,
-0.08378367125988007,
-0.0059068938717246056,
0.010563556104898453,
0.009027944877743721,
0.023808768019080162,
0.04058724641799927,
-0.0028809697832912207,
-0.021888121962547302,
0.034517280757427216,
-0.058054257184267044,
-0.030059929937124252,
-0.014214595779776573,
-0.0069261048920452595,
-0.0017451157327741385,
0.004289745818823576,
-0.01427801325917244,
0.04511707276105881,
0.020148668438196182,
-0.04700148105621338,
0.026725977659225464,
0.06849098205566406,
0.04384872317314148,
-0.02228674665093422,
0.00466119172051549,
0.01019211020320654,
-0.00030179970781318843,
0.05356067046523094,
0.020637890323996544,
-0.030132407322525978,
-0.004865034017711878,
0.03372003138065338,
-0.03636544942855835,
-0.027813134714961052,
0.03895650804042816,
-0.03587622568011284,
-0.019713805988430977,
-0.017467010766267776,
-0.061170779168605804,
0.02052917517721653,
0.02330142818391323,
-0.006106206215918064,
-0.005798178259283304,
-0.01166883297264576,
0.01086252462118864,
-0.01723146066069603,
0.031255804002285004,
0.0980616882443428,
0.08088458329439163,
0.012457023374736309,
-0.05624232813715935,
-0.01792905293405056,
0.05301709100604057,
0.006323637906461954,
-0.013933747075498104,
-0.00853872299194336,
0.050915252417325974,
0.02469661459326744,
-0.012158054858446121,
0.022178031504154205,
-0.03442668169736862,
0.022558536380529404,
0.0027360152453184128,
-0.016923433169722557,
-0.07457906752824783,
0.035042740404605865,
-0.029461992904543877,
-0.012574798427522182,
-0.041167065501213074,
0.029153963550925255,
-0.03323080763220787,
0.016660701483488083,
0.00999279785901308,
0.0956699401140213,
0.012221472337841988,
-0.03527829051017761,
0.11473144590854645,
0.05899646133184433,
0.048813410103321075,
0.04192807525396347,
-0.04250789433717728,
-0.005367844365537167,
-0.005145883187651634,
0.06414234638214111,
0.0036487753968685865,
0.04555193707346916,
-0.007102768402546644,
0.005820827092975378,
0.06830978393554688,
-0.029516350477933884,
-0.0410945862531662,
0.004683840554207563,
-0.004393931943923235,
-0.00421726843342185,
-0.05551755428314209,
-0.058742791414260864,
-0.035078976303339005,
-0.0508427731692791,
0.05011800304055214,
0.00692157493904233,
-0.012484202161431313,
-0.07914513349533081,
-0.05149506777524948,
-0.0320168137550354,
-0.018735362216830254,
-0.03578563034534454,
0.030204884707927704,
-0.002942122519016266,
-0.015736617147922516,
0.02560258097946644,
-0.022395463660359383,
-0.061678119003772736,
-0.07023043185472488,
-0.006464062724262476,
-0.006187743041664362,
0.0032229716889560223,
-0.008484365418553352,
-0.031400758773088455,
0.009684769436717033,
0.031056491658091545,
0.016832835972309113,
-0.03290466219186783,
0.06171435862779617,
0.007668996695429087,
-0.03326704725623131,
0.03181750327348709,
0.004092698451131582,
0.04580560699105263,
0.008606670424342155,
-0.03188997879624367,
-0.027233317494392395,
-0.030186764895915985,
0.10530941188335419,
-0.03359319269657135,
-0.03462599590420723,
-0.029262680560350418,
-0.03596682474017143,
-0.014667578972876072,
-0.023228950798511505,
-0.06533821672201157,
-0.03790558874607086,
-0.018345797434449196,
0.043232664465904236,
-0.039427611976861954,
0.032089293003082275,
0.003741636872291565,
-0.007370028179138899,
-0.008135568350553513,
-0.058525361120700836,
0.009956559166312218,
-0.10349748283624649,
0.02038422040641308,
0.03953632712364197,
-0.02085532248020172,
-0.022848445922136307,
-0.0309658944606781,
-0.06055472418665886,
-0.028103044256567955,
-0.01443202793598175,
-0.06040976941585541,
0.02194247953593731,
-0.00385035271756351,
-0.000015332401744672097,
-0.002255853731185198,
0.00010050553100882098,
0.040985871106386185,
-0.010500137694180012,
-0.06341757625341415,
-0.0410945862531662,
0.04522578790783882,
-0.02295716106891632,
-0.01828237995505333,
0.012275829911231995,
-0.011940622702240944,
0.014903130009770393,
0.002978360978886485,
0.02052917517721653,
0.02261289395391941,
0.002618239726871252,
0.02085532248020172,
0.02297528088092804,
-0.014694757759571075,
-0.06965061277151108,
0.004076844081282616,
0.017276758328080177,
0.017621025443077087,
0.0008414153126068413,
0.016434211283922195,
0.007895488291978836,
-0.06787492334842682,
0.0177750401198864,
0.0072477227076888084,
0.08327633142471313,
-0.011378924362361431,
-0.00005612738459603861,
0.019768163561820984,
0.034028057008981705,
-0.003096136497333646,
0.027613822370767593,
0.003012334695085883,
-0.0595400407910347,
0.027595704421401024,
0.009104951284825802,
0.021326424553990364,
-0.04283403977751732,
-0.027015885338187218,
0.026164278388023376,
0.005195711273699999,
0.03152759373188019,
-0.050734058022499084,
-0.07258594036102295,
-0.04076844081282616,
-0.05066158249974251,
-0.012130876071751118,
0.005934073124080896,
-0.019605088979005814,
0.018844079226255417,
-0.000954094750341028,
0.007057469803839922,
0.0344085618853569,
0.031581953167915344,
-0.005558097269386053,
0.008751625195145607,
0.023772530257701874,
0.07602860778570175,
0.003014599671587348,
0.053850580006837845,
0.033158332109451294,
0.0059612519107759,
-0.04953818395733833,
-0.057365722954273224,
-0.014477325603365898,
0.033665671944618225,
0.010681331157684326,
-0.01042766124010086,
-0.03460787609219551,
0.06106206402182579,
0.0010237408569082618,
0.00877880398184061,
0.002769988961517811,
-0.055734988301992416,
-0.009295204654335976,
0.012837528251111507,
-0.005499209742993116,
-0.016986850649118423,
0.012248651124536991,
0.007379087619483471,
-0.05711205303668976,
0.029860617592930794,
-0.0069261048920452595,
-0.007505922578275204,
0.07240474969148636,
0.023953722789883614,
0.010065275244414806,
-0.025330791249871254,
-0.021797526627779007,
-0.0009705153643153608,
-0.021000275388360023,
-0.04363128915429115,
0.0782754048705101,
-0.0227940883487463,
0.016425151377916336,
0.0234645027667284,
0.0201667882502079,
-0.03754320368170738,
0.01685095578432083,
0.04660285636782646,
-0.018046829849481583,
0.024134917184710503,
0.026001205667853355,
0.032977137714624405,
0.0070393504574894905,
-0.011378924362361431,
-0.03319456800818443,
-0.0011103737633675337,
0.09219103306531906,
-0.002302284352481365,
-0.010907822288572788,
-0.015935929492115974,
0.00426936149597168,
-0.03464411571621895,
-0.02958882786333561,
-0.022757848724722862,
0.009240846149623394,
0.05066158249974251,
0.0032569454051554203,
-0.007854719646275043,
-0.011759430170059204,
-0.007963434793055058
]
|
32,052 | pingouin.pairwise | ptests |
Pairwise T-test between columns of a dataframe.
T-values are reported on the lower triangle of the output pairwise matrix and p-values on the
upper triangle. This method is a faster, but less exhaustive, matrix-version of the
:py:func:`pingouin.pairwise_test` function. Missing values are automatically removed from each
pairwise T-test.
.. versionadded:: 0.5.3
Parameters
----------
self : :py:class:`pandas.DataFrame`
Input dataframe.
paired : boolean
Specify whether the two observations are related (i.e. repeated measures) or independent.
decimals : int
Number of decimals to display in the output matrix.
padjust : string or None
P-values adjustment for multiple comparison
* ``'none'``: no correction
* ``'bonf'``: one-step Bonferroni correction
* ``'sidak'``: one-step Sidak correction
* ``'holm'``: step-down method using Bonferroni adjustments
* ``'fdr_bh'``: Benjamini/Hochberg FDR correction
* ``'fdr_by'``: Benjamini/Yekutieli FDR correction
stars : boolean
If True, only significant p-values are displayed as stars using the pre-defined thresholds
of ``pval_stars``. If False, all the raw p-values are displayed.
pval_stars : dict
Significance thresholds. Default is 3 stars for p-values <0.001, 2 stars for
p-values <0.01 and 1 star for p-values <0.05.
**kwargs : optional
Optional argument(s) passed to the lower-level scipy functions, i.e.
:py:func:`scipy.stats.ttest_ind` for independent T-test and
:py:func:`scipy.stats.ttest_rel` for paired T-test.
Returns
-------
mat : :py:class:`pandas.DataFrame`
Pairwise T-test matrix, of dtype str, with T-values on the lower triangle and p-values on
the upper triangle.
Examples
--------
>>> import numpy as np
>>> import pandas as pd
>>> import pingouin as pg
>>> # Load an example dataset of personality dimensions
>>> df = pg.read_dataset('pairwise_corr').iloc[:30, 1:]
>>> df.columns = ["N", "E", "O", 'A', "C"]
>>> # Add some missing values
>>> df.iloc[[2, 5, 20], 2] = np.nan
>>> df.iloc[[1, 4, 10], 3] = np.nan
>>> df.head().round(2)
N E O A C
0 2.48 4.21 3.94 3.96 3.46
1 2.60 3.19 3.96 NaN 3.23
2 2.81 2.90 NaN 2.75 3.50
3 2.90 3.56 3.52 3.17 2.79
4 3.02 3.33 4.02 NaN 2.85
Independent pairwise T-tests
>>> df.ptests()
N E O A C
N - *** *** *** ***
E -8.397 - ***
O -8.332 -0.596 - ***
A -8.804 0.12 0.72 - ***
C -4.759 3.753 4.074 3.787 -
Let's compare with SciPy
>>> from scipy.stats import ttest_ind
>>> np.round(ttest_ind(df["N"], df["E"]), 3)
array([-8.397, 0. ])
Passing custom parameters to the lower-level :py:func:`scipy.stats.ttest_ind` function
>>> df.ptests(alternative="greater", equal_var=True)
N E O A C
N -
E -8.397 - ***
O -8.332 -0.596 - ***
A -8.804 0.12 0.72 - ***
C -4.759 3.753 4.074 3.787 -
Paired T-test, showing the actual p-values instead of stars
>>> df.ptests(paired=True, stars=False, decimals=4)
N E O A C
N - 0.0000 0.0000 0.0000 0.0002
E -7.0773 - 0.8776 0.7522 0.0012
O -8.0568 -0.1555 - 0.8137 0.0008
A -8.3994 0.3191 0.2383 - 0.0009
C -4.2511 3.5953 3.7849 3.7652 -
Adjusting for multiple comparisons using the Holm-Bonferroni method
>>> df.ptests(paired=True, stars=False, padjust="holm")
N E O A C
N - 0.000 0.000 0.000 0.001
E -7.077 - 1. 1. 0.005
O -8.057 -0.155 - 1. 0.005
A -8.399 0.319 0.238 - 0.005
C -4.251 3.595 3.785 3.765 -
| @pf.register_dataframe_method
def ptests(
self,
paired=False,
decimals=3,
padjust=None,
stars=True,
pval_stars={0.001: "***", 0.01: "**", 0.05: "*"},
**kwargs,
):
"""
Pairwise T-test between columns of a dataframe.
T-values are reported on the lower triangle of the output pairwise matrix and p-values on the
upper triangle. This method is a faster, but less exhaustive, matrix-version of the
:py:func:`pingouin.pairwise_test` function. Missing values are automatically removed from each
pairwise T-test.
.. versionadded:: 0.5.3
Parameters
----------
self : :py:class:`pandas.DataFrame`
Input dataframe.
paired : boolean
Specify whether the two observations are related (i.e. repeated measures) or independent.
decimals : int
Number of decimals to display in the output matrix.
padjust : string or None
P-values adjustment for multiple comparison
* ``'none'``: no correction
* ``'bonf'``: one-step Bonferroni correction
* ``'sidak'``: one-step Sidak correction
* ``'holm'``: step-down method using Bonferroni adjustments
* ``'fdr_bh'``: Benjamini/Hochberg FDR correction
* ``'fdr_by'``: Benjamini/Yekutieli FDR correction
stars : boolean
If True, only significant p-values are displayed as stars using the pre-defined thresholds
of ``pval_stars``. If False, all the raw p-values are displayed.
pval_stars : dict
Significance thresholds. Default is 3 stars for p-values <0.001, 2 stars for
p-values <0.01 and 1 star for p-values <0.05.
**kwargs : optional
Optional argument(s) passed to the lower-level scipy functions, i.e.
:py:func:`scipy.stats.ttest_ind` for independent T-test and
:py:func:`scipy.stats.ttest_rel` for paired T-test.
Returns
-------
mat : :py:class:`pandas.DataFrame`
Pairwise T-test matrix, of dtype str, with T-values on the lower triangle and p-values on
the upper triangle.
Examples
--------
>>> import numpy as np
>>> import pandas as pd
>>> import pingouin as pg
>>> # Load an example dataset of personality dimensions
>>> df = pg.read_dataset('pairwise_corr').iloc[:30, 1:]
>>> df.columns = ["N", "E", "O", 'A', "C"]
>>> # Add some missing values
>>> df.iloc[[2, 5, 20], 2] = np.nan
>>> df.iloc[[1, 4, 10], 3] = np.nan
>>> df.head().round(2)
N E O A C
0 2.48 4.21 3.94 3.96 3.46
1 2.60 3.19 3.96 NaN 3.23
2 2.81 2.90 NaN 2.75 3.50
3 2.90 3.56 3.52 3.17 2.79
4 3.02 3.33 4.02 NaN 2.85
Independent pairwise T-tests
>>> df.ptests()
N E O A C
N - *** *** *** ***
E -8.397 - ***
O -8.332 -0.596 - ***
A -8.804 0.12 0.72 - ***
C -4.759 3.753 4.074 3.787 -
Let's compare with SciPy
>>> from scipy.stats import ttest_ind
>>> np.round(ttest_ind(df["N"], df["E"]), 3)
array([-8.397, 0. ])
Passing custom parameters to the lower-level :py:func:`scipy.stats.ttest_ind` function
>>> df.ptests(alternative="greater", equal_var=True)
N E O A C
N -
E -8.397 - ***
O -8.332 -0.596 - ***
A -8.804 0.12 0.72 - ***
C -4.759 3.753 4.074 3.787 -
Paired T-test, showing the actual p-values instead of stars
>>> df.ptests(paired=True, stars=False, decimals=4)
N E O A C
N - 0.0000 0.0000 0.0000 0.0002
E -7.0773 - 0.8776 0.7522 0.0012
O -8.0568 -0.1555 - 0.8137 0.0008
A -8.3994 0.3191 0.2383 - 0.0009
C -4.2511 3.5953 3.7849 3.7652 -
Adjusting for multiple comparisons using the Holm-Bonferroni method
>>> df.ptests(paired=True, stars=False, padjust="holm")
N E O A C
N - 0.000 0.000 0.000 0.001
E -7.077 - 1. 1. 0.005
O -8.057 -0.155 - 1. 0.005
A -8.399 0.319 0.238 - 0.005
C -4.251 3.595 3.785 3.765 -
"""
from itertools import combinations
from numpy import triu_indices_from as tif
from numpy import format_float_positional as ffp
from scipy.stats import ttest_ind, ttest_rel
assert isinstance(pval_stars, dict), "pval_stars must be a dictionary."
assert isinstance(decimals, int), "decimals must be an int."
if paired:
func = ttest_rel
else:
func = ttest_ind
# Get T-values and p-values
# We cannot use pandas.DataFrame.corr here because it will incorrectly remove rows missing
# values, even when using an independent T-test!
cols = self.columns
combs = list(combinations(cols, 2))
mat = pd.DataFrame(columns=cols, index=cols, dtype=np.float64)
mat_upper = mat.copy()
for a, b in combs:
t, p = func(self[a], self[b], **kwargs, nan_policy="omit")
mat.loc[b, a] = np.round(t, decimals)
# Do not round p-value here, or we'll lose precision for multicomp
mat_upper.loc[a, b] = p
if padjust is not None:
pvals = mat_upper.to_numpy()[tif(mat, k=1)]
mat_upper.to_numpy()[tif(mat, k=1)] = multicomp(pvals, alpha=0.05, method=padjust)[1]
# Convert T-values to str, and fill the diagonal with "-"
mat = mat.astype(str)
np.fill_diagonal(mat.to_numpy(), "-")
def replace_pval(x):
for key, value in pval_stars.items():
if x < key:
return value
return ""
if stars:
# Replace p-values by stars
mat_upper = mat_upper.applymap(replace_pval)
else:
mat_upper = mat_upper.applymap(lambda x: ffp(x, precision=decimals))
# Replace upper triangle by p-values
mat.to_numpy()[tif(mat, k=1)] = mat_upper.to_numpy()[tif(mat, k=1)]
return mat
| (self, paired=False, decimals=3, padjust=None, stars=True, pval_stars={0.001: '***', 0.01: '**', 0.05: '*'}, **kwargs) | [
0.021256335079669952,
-0.008758585900068283,
0.04482932761311531,
0.006640064530074596,
0.02145954966545105,
-0.03383537009358406,
-0.021276656538248062,
-0.0009087540674954653,
0.061167847365140915,
0.007310675457119942,
-0.0008700161124579608,
0.048080772161483765,
0.021805016323924065,
0.04009440541267395,
-0.03113260492682457,
0.005552861839532852,
0.022536592558026314,
-0.009403794072568417,
0.028551768511533737,
0.011491833254694939,
-0.008936398662626743,
0.012253890745341778,
0.0059745339676737785,
0.02033170498907566,
-0.023755885660648346,
-0.018055692315101624,
-0.03655845671892166,
-0.07575871795415878,
0.04409775137901306,
0.022475628182291985,
0.0027459487318992615,
-0.035684630274772644,
-0.0485684908926487,
0.0320267528295517,
-0.018980322405695915,
-0.010577363893389702,
-0.04901556298136711,
-0.018807588145136833,
-0.016694149002432823,
0.07010933011770248,
0.004790803883224726,
-0.05950148031115532,
-0.0249142125248909,
-0.05373016372323036,
-0.0262757558375597,
0.0030380708631128073,
0.0011195900151506066,
0.003635016269981861,
0.007717106491327286,
-0.028104694560170174,
0.03991151228547096,
-0.00833183340728283,
-0.005044823512434959,
0.026397686451673508,
-0.036822639405727386,
0.0785224437713623,
0.004760321695357561,
-0.01561710610985756,
0.028836270794272423,
-0.05165736377239227,
0.01452990435063839,
0.038285788148641586,
0.0024208039976656437,
0.03450598195195198,
-0.008555370382964611,
-0.05023485794663429,
0.017954085022211075,
-0.02824694663286209,
0.007315755821764469,
-0.029141094535589218,
-0.010216656140983105,
-0.005547781474888325,
-0.03676167130470276,
0.015271640382707119,
-0.000319588027196005,
0.01109556294977665,
0.00042706995736807585,
-0.04763370007276535,
-0.011898264288902283,
-0.015667909756302834,
-0.03521723672747612,
0.027352798730134964,
0.004381833132356405,
0.01662302389740944,
-0.027373120188713074,
-0.0009671784937381744,
0.036924246698617935,
0.05056000128388405,
0.06722366809844971,
0.026458650827407837,
-0.00637080380693078,
-0.03038070909678936,
0.04344746097922325,
-0.04279717057943344,
0.006619743071496487,
-0.0067772348411381245,
0.026478972285985947,
0.021947268396615982,
-0.05312051624059677,
-0.023735564202070236,
0.02210984006524086,
0.03298186510801315,
0.02566611021757126,
0.03755421191453934,
0.048731062561273575,
-0.007905080914497375,
-0.05881054699420929,
0.0443822517991066,
0.001201511244289577,
0.005715434439480305,
-0.0523482970893383,
0.02290238067507744,
0.01249774917960167,
-0.04990971088409424,
0.03395729884505272,
-0.030075885355472565,
-0.014844887889921665,
0.02045363374054432,
-0.03930186480283737,
-0.02753569185733795,
0.05177929252386093,
0.06726431101560593,
0.0024512861855328083,
-0.026418007910251617,
-0.05665646493434906,
-0.010648488998413086,
0.048609133809804916,
0.03529852256178856,
-0.04698340967297554,
-0.0031625402625650167,
0.025442572310566902,
0.027820194140076637,
0.020758457481861115,
0.09494225680828094,
-0.04340681806206703,
0.010953311808407307,
0.03987086936831474,
-0.011684888042509556,
0.049421995878219604,
-0.050722572952508926,
0.03781839460134506,
0.022374019026756287,
-0.01861453428864479,
0.029527204111218452,
0.051576077938079834,
0.01237582042813301,
-0.005232797469943762,
0.04401646554470062,
0.03296154364943504,
0.02137826383113861,
-0.016551896929740906,
-0.026661865413188934,
-0.005375048611313105,
-0.04990971088409424,
0.06161492317914963,
-0.023003987967967987,
0.08303382992744446,
-0.022333376109600067,
0.0009081190219148993,
-0.05368952080607414,
0.00623871386051178,
-0.08112360537052155,
-0.012406302616000175,
0.0638502910733223,
0.0048314472660422325,
0.00008573151717428118,
-0.008855112828314304,
0.003995723556727171,
-0.008850032463669777,
-0.04629247635602951,
0.03198610991239548,
-0.0014250482199713588,
-0.017486687749624252,
-0.021622123196721077,
-0.010115048848092556,
-0.020189454779028893,
0.003228585235774517,
-0.043203603476285934,
0.01381864957511425,
-0.05921697989106178,
-0.0032768489327281713,
-0.014631511643528938,
-0.05921697989106178,
0.027352798730134964,
-0.008367395959794521,
0.04169980809092522,
0.015017621219158173,
-0.010577363893389702,
-0.04143562912940979,
0.00194197753444314,
-0.061940066516399384,
-0.014865209348499775,
-0.02682443894445896,
0.08043266832828522,
0.06450057774782181,
0.00886527355760336,
0.03320540115237236,
0.01697864942252636,
0.027759229764342308,
0.034201160073280334,
0.004282765556126833,
-0.013483344577252865,
-0.00250463024713099,
0.017344437539577484,
0.0024423955474048853,
-0.03854996711015701,
-0.03934250771999359,
-0.01521067600697279,
-0.02977106161415577,
-0.012589196674525738,
0.06206199526786804,
-0.05872926115989685,
0.026478972285985947,
0.006721350830048323,
-0.0035588103346526623,
0.036233313381671906,
0.03373376280069351,
-0.030075885355472565,
-0.007071897387504578,
0.009784823283553123,
0.04966585338115692,
-0.03160000219941139,
-0.007234469521790743,
0.05165736377239227,
0.055518459528684616,
0.04714598134160042,
0.010841543786227703,
0.04913749173283577,
0.00010359224688727409,
0.011705209501087666,
0.015373247675597668,
0.017659422010183334,
-0.016490932554006577,
-0.037696465849876404,
-0.012284372933208942,
-0.060558199882507324,
-0.020595883950591087,
-0.0554778166115284,
-0.07218212634325027,
-0.0037112219724804163,
-0.009449518285691738,
0.01913273334503174,
0.018086174502968788,
0.004757781513035297,
0.00859601330012083,
-0.06393157690763474,
0.030136849731206894,
-0.025970933958888054,
0.03373376280069351,
0.014164116233587265,
0.0370664969086647,
-0.043122317641973495,
0.012010032311081886,
0.002596077276393771,
-0.0002775160828605294,
-0.032819293439388275,
0.043244246393442154,
0.04917813464999199,
0.06677659600973129,
0.01377800665795803,
0.012873698025941849,
-0.057835113257169724,
0.016470611095428467,
0.004983858671039343,
-0.016358843073248863,
-0.018685659393668175,
-0.025828681886196136,
-0.004254823084920645,
-0.009794984012842178,
-0.013727203011512756,
-0.033428940922021866,
-0.01551549881696701,
-0.05251086875796318,
0.016724631190299988,
-0.011126045137643814,
0.029181737452745438,
0.024446817114949226,
0.003380996873602271,
-0.01907176896929741,
-0.07604321837425232,
0.007397042121738195,
-0.02011832781136036,
0.011908425018191338,
-0.010043922811746597,
-0.013015949167311192,
0.010358907282352448,
-0.03779807314276695,
0.0030431512277573347,
0.08153003454208374,
-0.010953311808407307,
-0.04649569094181061,
-0.03824514523148537,
-0.013727203011512756,
0.015728874132037163,
0.019965916872024536,
0.010516398586332798,
-0.03263640031218529,
-0.03757453337311745,
0.0034038585145026445,
-0.06372836232185364,
0.011369903571903706,
-0.04885299131274223,
0.02698701061308384,
0.0640535056591034,
-0.03310379385948181,
0.07100347429513931,
0.008275948464870453,
-0.018370674923062325,
0.009078649803996086,
-0.02979138307273388,
0.03456694632768631,
0.05137286335229874,
-0.037046175450086594,
0.02485324814915657,
0.03544077277183533,
-0.009231061674654484,
-0.040460195392370224,
-0.0347498394548893,
0.0540146641433239,
-0.0014364791568368673,
-0.0360097773373127,
-0.03048231638967991,
0.03609106317162514,
0.025442572310566902,
0.04409775137901306,
0.01798456721007824,
-0.015627266839146614,
-0.023308811709284782,
-0.0387328639626503,
0.025442572310566902,
0.005037202499806881,
0.019732220098376274,
0.03940347209572792,
0.03312411531805992,
0.0009779742686077952,
0.03381504863500595,
-0.00670610973611474,
-0.021764373406767845,
0.03129517659544945,
0.0026290996465831995,
0.06380964815616608,
-0.04263459891080856,
-0.017507009208202362,
-0.032229967415332794,
0.033489905297756195,
0.009322508238255978,
-0.036253634840250015,
0.04409775137901306,
0.056331321597099304,
-0.012223408557474613,
0.03775743022561073,
0.02755601331591606,
-0.0018213184084743261,
0.030116528272628784,
0.022678842768073082,
0.051413506269454956,
-0.013442701660096645,
0.04222816973924637,
0.03877350687980652,
0.05523395538330078,
0.026702508330345154,
-0.0019813505932688713,
0.05181993544101715,
-0.022597556933760643,
-0.0030025080777704716,
-0.028165660798549652,
0.005817041732370853,
0.039159614592790604,
-0.04828398674726486,
0.01525131892412901,
0.02336977608501911,
-0.06998739391565323,
0.03462791070342064,
-0.02499549835920334,
0.03430276736617088,
-0.008270868100225925,
-0.03818418085575104,
0.007585016079246998,
-0.007259871810674667,
-0.03450598195195198,
0.021114084869623184,
-0.039708297699689865,
0.012050675228238106,
0.04824334383010864,
-0.03178289532661438,
-0.03123421221971512,
0.020992154255509377,
0.008148939348757267,
0.015667909756302834,
-0.031396783888339996,
-0.04377260431647301,
0.00004616006845026277,
-0.0038306110072880983,
-0.009022765792906284,
0.016826238483190536,
0.005629067774862051,
-0.04430096596479416,
0.013310611248016357,
-0.026682186871767044,
0.022963345050811768,
0.01879742741584778,
-0.08303382992744446,
-0.0016879582544788718,
-0.03430276736617088,
-0.018167460337281227,
-0.0010027411626651883,
0.021764373406767845,
-0.04625183343887329,
-0.02686508186161518,
0.01664334535598755,
-0.029872668907046318,
0.05368952080607414,
0.012335177510976791,
-0.028185982257127762,
-0.014103151857852936,
0.048162057995796204,
-0.07929466664791107,
0.028856592252850533,
0.04507318511605263,
0.026682186871767044,
0.0908779427409172,
-0.05816026031970978,
-0.03462791070342064,
0.02005736343562603,
0.039809904992580414,
-0.025158071890473366,
-0.011654405854642391,
0.02349170483648777,
-0.012650161050260067,
0.06576051563024521,
-0.005141350440680981,
-0.025361286476254463,
-0.018451962620019913,
0.032920900732278824,
0.026478972285985947,
0.019457878544926643,
-0.05852604657411575,
-0.004018585197627544,
0.01417427696287632,
0.020545080304145813,
0.023044630885124207,
-0.01930546760559082,
0.004882250912487507,
-0.015078585594892502,
0.011308939196169376,
0.0011507074814289808,
-0.0075697749853134155,
-0.04706469550728798,
-0.0799855962395668,
-0.02686508186161518,
0.041191767901182175,
0.028633056208491325,
0.0441790372133255,
0.023979421705007553,
-0.034262124449014664,
0.017618779093027115,
-0.0025224117562174797,
-0.025361286476254463,
-0.08746392279863358,
0.049421995878219604,
-0.02009800635278225,
0.026702508330345154,
-0.020189454779028893,
-0.03863125666975975,
0.011705209501087666,
-0.009779742918908596,
-0.027942122891545296,
-0.033489905297756195,
-0.06880874931812286,
0.008458842523396015,
-0.018126817420125008,
-0.023207202553749084,
-0.05027550086379051,
0.0014834727626293898,
0.0036985210608690977,
0.036822639405727386,
-0.07193826884031296,
0.0029618649277836084,
-0.028694020584225655,
-0.022353697568178177,
-0.029303666204214096,
-0.023044630885124207,
0.06714238226413727,
0.03336797654628754,
0.012507909908890724,
-0.027840515598654747,
0.003142218803986907,
0.00939871370792389,
-0.008093055337667465,
-0.08713877946138382,
0.02145954966545105,
-0.030665209516882896,
0.018512926995754242,
0.06714238226413727,
-0.0805952399969101,
0.030868425965309143,
0.03792000189423561,
-0.03304282948374748,
0.011613762006163597,
-0.006142186466604471,
0.06750816851854324,
0.04552025720477104,
0.004132893867790699,
-0.03812321648001671,
0.0816519632935524,
-0.04283781349658966,
-0.002094389172270894,
0.01005916390568018,
-0.04641440510749817,
0.00812353752553463,
-0.0017336817691102624,
-0.0690932497382164,
0.029567847028374672,
-0.014824566431343555,
0.00997787807136774,
-0.018584052100777626,
0.039748940616846085,
-0.07169440388679504,
0.00011184787581441924,
-0.046617623418569565,
0.01654173620045185,
-0.028897235170006752,
-0.004874630365520716,
0.05397402122616768,
0.009937235154211521,
0.03155935928225517,
0.03403858467936516,
0.061899423599243164,
0.00006021051376592368,
0.0007722186855971813,
-0.011187009513378143,
0.017791511490941048,
0.022374019026756287,
0.018787266686558723,
-0.014936334453523159,
0.019193697720766068,
-0.020128488540649414,
-0.04230945557355881,
0.09770598262548447,
-0.010790740139782429,
0.04328488931059837,
0.009739100001752377,
0.02341041900217533,
-0.061086561530828476,
0.04495125636458397,
-0.03932218626141548,
-0.03253479301929474,
-0.013300450518727303,
0.01760861836373806,
0.017466366291046143,
0.03928154334425926,
-0.04332553222775459,
0.052876658737659454,
0.015139549970626831,
-0.013879614882171154,
0.0318235382437706,
0.034262124449014664,
0.023816850036382675,
0.0036400966346263885,
-0.025340965017676353,
-0.03330701217055321,
-0.06754881143569946,
0.056331321597099304,
-0.060598842799663544,
-0.015749197453260422,
-0.00044326367788016796,
0.006436849012970924,
0.021093763411045074,
-0.06299678981304169,
-0.05096643045544624,
0.025158071890473366,
-0.006091382820159197,
-0.038997042924165726,
-0.0326567217707634,
-0.012385981157422066,
-0.059826623648405075,
-0.010597685351967812,
0.01249774917960167,
-0.007061736658215523,
-0.02137826383113861,
-0.05661582201719284,
0.016734791919589043,
0.054217878729104996,
-0.01974238082766533,
-0.04612990468740463,
0.0341198705136776,
-0.028125016018748283,
0.03306315094232559,
0.012680643238127232,
-0.04995035380125046,
-0.07104411721229553,
-0.038285788148641586,
-0.002837395528331399,
-0.05755061283707619,
0.007264952175319195,
0.016846559941768646,
-0.036253634840250015,
0.014306367374956608,
0.07933530956506729,
-0.019823666661977768,
-0.015363086946308613,
0.045357685536146164,
-0.02359331212937832,
-0.06539472937583923,
-0.006960128899663687,
-0.06157427653670311,
0.017954085022211075,
0.04625183343887329,
0.004122733138501644,
-0.008016848936676979,
0.07059704512357712,
0.06291549652814865,
0.011278457008302212,
-0.0760025754570961,
0.06100527569651604,
-0.018035370856523514,
-0.07953852415084839,
0.03229093179106712,
0.02202855423092842,
-0.05181993544101715,
-0.05177929252386093,
0.072873055934906,
-0.003856013063341379,
0.05787575617432594,
-0.01719202660024166,
0.006883922964334488,
0.010851704515516758,
-0.06750816851854324,
-0.00604565953835845,
-0.09429196268320084,
0.01599305495619774,
0.00589832803234458,
0.02357299067080021,
-0.01865517720580101,
-0.010140450671315193,
-0.08461891114711761,
0.03808257356286049,
-0.03304282948374748,
-0.016572218388319016,
0.050722572952508926,
-0.03409954905509949,
-0.05177929252386093,
0.043162960559129715,
0.001022427692078054,
0.018208103254437447,
-0.021764373406767845,
-0.006756913382560015,
-0.039078328758478165,
0.040378909558057785,
-0.0011570579372346401,
0.022943023592233658,
0.006863601505756378,
-0.013351254165172577,
-0.04848720505833626,
-0.005979614332318306,
-0.017141222953796387,
0.027108939364552498,
0.046658266335725784,
-0.00912945345044136,
0.02905980870127678,
-0.01601337641477585,
0.006035498343408108,
-0.033489905297756195,
0.041821736842393875,
0.06409414857625961,
0.02286173775792122,
0.03316475823521614,
0.06795524060726166,
-0.0035994534846395254,
0.05685967952013016,
0.029242701828479767,
0.09055279940366745,
-0.05986727029085159,
0.017872797325253487,
0.0745394229888916,
-0.021581480279564857,
-0.020260579884052277,
-0.0066299038007855415,
-0.05104772001504898,
-0.02288205921649933,
0.04726791009306908,
0.042512670159339905,
-0.0009024035534821451,
-0.033428940922021866,
0.003723922884091735,
-0.005278521217405796,
0.06840232014656067,
0.003914437256753445,
-0.04495125636458397,
-0.09640540182590485,
-0.036212991923093796,
-0.04673955217003822,
0.06206199526786804,
0.023349454626441002,
-0.02615382708609104,
0.04076501727104187,
-0.023329133167862892,
0.012010032311081886,
0.02076861821115017,
-0.05320180207490921,
-0.0454389713704586,
-0.017740707844495773,
0.005258199293166399,
0.03365247696638107,
0.02282109297811985,
0.06872746348381042,
0.020758457481861115,
-0.01911241188645363,
0.005314083769917488,
-0.11193106323480606,
-0.05515266954898834,
0.006909324787557125,
0.003706141607835889,
-0.02282109297811985,
-0.027860837057232857,
0.040378909558057785,
0.018116656690835953,
0.012426624074578285,
0.012426624074578285,
-0.023959100246429443,
0.018370674923062325,
0.0024411254562437534,
0.01578984037041664,
-0.011745852418243885,
-0.03942379355430603,
0.024406174197793007,
-0.03038070909678936,
-0.004828907083719969,
-0.021053120493888855,
-0.013910097070038319,
-0.0007607878069393337,
-0.0038179100956767797,
0.04547961428761482,
0.0024309647269546986,
-0.036314599215984344,
-0.025869324803352356,
0.03466855362057686,
-0.023837171494960785,
0.032250288873910904,
0.03111228346824646,
-0.007097299210727215,
0.016033697873353958,
-0.006411447189748287,
-0.07486456632614136,
0.03544077277183533,
0.07352334260940552,
-0.03865157812833786,
-0.008733183145523071,
0.005964373238384724,
-0.03869222104549408,
0.08518791198730469,
-0.008027009665966034,
-0.04747112840414047,
-0.033571191132068634,
0.033571191132068634,
0.04848720505833626,
0.057835113257169724,
-0.04344746097922325,
-0.035704951733350754,
-0.02619447000324726,
-0.07571807503700256,
0.04058212414383888,
0.05543717369437218,
0.08230224996805191,
0.0127720907330513,
0.05368952080607414,
-0.05970469489693642,
0.07169440388679504
]
|
32,053 | pingouin.plotting | qqplot | Quantile-Quantile plot.
Parameters
----------
x : array_like
Sample data.
dist : str or stats.distributions instance, optional
Distribution or distribution function name. The default is `'norm'`
for a normal probability plot.
sparams : tuple, optional
Distribution-specific shape parameters (shape parameters, location,
and scale). See :py:func:`scipy.stats.probplot` for more details.
confidence : float
Confidence level (.95 = 95%) for point-wise confidence envelope.
Can be disabled by passing False.
square: bool
If True (default), ensure equal aspect ratio between X and Y axes.
ax : matplotlib axes
Axis on which to draw the plot
**kwargs : optional
Optional argument(s) passed to :py:func:`matplotlib.pyplot.scatter`.
Returns
-------
ax : Matplotlib Axes instance
Returns the Axes object with the plot for further tweaking.
Raises
------
ValueError
If ``sparams`` does not contain the required parameters for ``dist``.
(e.g. :py:class:`scipy.stats.t` has a mandatory degrees of
freedom parameter *df*.)
Notes
-----
This function returns a scatter plot of the quantile of the sample data
``x`` against the theoretical quantiles of the distribution given in
``dist`` (default = *'norm'*).
The points plotted in a Q–Q plot are always non-decreasing when viewed
from left to right. If the two distributions being compared are identical,
the Q–Q plot follows the 45° line y = x. If the two distributions agree
after linearly transforming the values in one of the distributions,
then the Q–Q plot follows some line, but not necessarily the line y = x.
If the general trend of the Q–Q plot is flatter than the line y = x,
the distribution plotted on the horizontal axis is more dispersed than
the distribution plotted on the vertical axis. Conversely, if the general
trend of the Q–Q plot is steeper than the line y = x, the distribution
plotted on the vertical axis is more dispersed than the distribution
plotted on the horizontal axis. Q–Q plots are often arced, or "S" shaped,
indicating that one of the distributions is more skewed than the other,
or that one of the distributions has heavier tails than the other.
In addition, the function also plots a best-fit line (linear regression)
for the data and annotates the plot with the coefficient of
determination :math:`R^2`. Note that the intercept and slope of the
linear regression between the quantiles gives a measure of the relative
location and relative scale of the samples.
.. warning:: Be extra careful when using fancier distributions with several
parameters. Always double-check your results with another
software or package.
References
----------
* https://github.com/cran/car/blob/master/R/qqPlot.R
* Fox, J. (2008), Applied Regression Analysis and Generalized Linear
Models, 2nd Ed., Sage Publications, Inc.
Examples
--------
Q-Q plot using a normal theoretical distribution:
.. plot::
>>> import numpy as np
>>> import pingouin as pg
>>> np.random.seed(123)
>>> x = np.random.normal(size=50)
>>> ax = pg.qqplot(x, dist='norm')
Two Q-Q plots using two separate axes:
.. plot::
>>> import numpy as np
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> np.random.seed(123)
>>> x = np.random.normal(size=50)
>>> x_exp = np.random.exponential(size=50)
>>> fig, (ax1, ax2) = plt.subplots(1, 2, figsize=(9, 4))
>>> ax1 = pg.qqplot(x, dist='norm', ax=ax1, confidence=False)
>>> ax2 = pg.qqplot(x_exp, dist='expon', ax=ax2)
Using custom location / scale parameters as well as another Seaborn style
.. plot::
>>> import numpy as np
>>> import seaborn as sns
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> np.random.seed(123)
>>> x = np.random.normal(size=50)
>>> mean, std = 0, 0.8
>>> sns.set_style('darkgrid')
>>> ax = pg.qqplot(x, dist='norm', sparams=(mean, std))
| def qqplot(x, dist="norm", sparams=(), confidence=0.95, square=True, ax=None, **kwargs):
"""Quantile-Quantile plot.
Parameters
----------
x : array_like
Sample data.
dist : str or stats.distributions instance, optional
Distribution or distribution function name. The default is `'norm'`
for a normal probability plot.
sparams : tuple, optional
Distribution-specific shape parameters (shape parameters, location,
and scale). See :py:func:`scipy.stats.probplot` for more details.
confidence : float
Confidence level (.95 = 95%) for point-wise confidence envelope.
Can be disabled by passing False.
square: bool
If True (default), ensure equal aspect ratio between X and Y axes.
ax : matplotlib axes
Axis on which to draw the plot
**kwargs : optional
Optional argument(s) passed to :py:func:`matplotlib.pyplot.scatter`.
Returns
-------
ax : Matplotlib Axes instance
Returns the Axes object with the plot for further tweaking.
Raises
------
ValueError
If ``sparams`` does not contain the required parameters for ``dist``.
(e.g. :py:class:`scipy.stats.t` has a mandatory degrees of
freedom parameter *df*.)
Notes
-----
This function returns a scatter plot of the quantile of the sample data
``x`` against the theoretical quantiles of the distribution given in
``dist`` (default = *'norm'*).
The points plotted in a Q–Q plot are always non-decreasing when viewed
from left to right. If the two distributions being compared are identical,
the Q–Q plot follows the 45° line y = x. If the two distributions agree
after linearly transforming the values in one of the distributions,
then the Q–Q plot follows some line, but not necessarily the line y = x.
If the general trend of the Q–Q plot is flatter than the line y = x,
the distribution plotted on the horizontal axis is more dispersed than
the distribution plotted on the vertical axis. Conversely, if the general
trend of the Q–Q plot is steeper than the line y = x, the distribution
plotted on the vertical axis is more dispersed than the distribution
plotted on the horizontal axis. Q–Q plots are often arced, or "S" shaped,
indicating that one of the distributions is more skewed than the other,
or that one of the distributions has heavier tails than the other.
In addition, the function also plots a best-fit line (linear regression)
for the data and annotates the plot with the coefficient of
determination :math:`R^2`. Note that the intercept and slope of the
linear regression between the quantiles gives a measure of the relative
location and relative scale of the samples.
.. warning:: Be extra careful when using fancier distributions with several
parameters. Always double-check your results with another
software or package.
References
----------
* https://github.com/cran/car/blob/master/R/qqPlot.R
* Fox, J. (2008), Applied Regression Analysis and Generalized Linear
Models, 2nd Ed., Sage Publications, Inc.
Examples
--------
Q-Q plot using a normal theoretical distribution:
.. plot::
>>> import numpy as np
>>> import pingouin as pg
>>> np.random.seed(123)
>>> x = np.random.normal(size=50)
>>> ax = pg.qqplot(x, dist='norm')
Two Q-Q plots using two separate axes:
.. plot::
>>> import numpy as np
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> np.random.seed(123)
>>> x = np.random.normal(size=50)
>>> x_exp = np.random.exponential(size=50)
>>> fig, (ax1, ax2) = plt.subplots(1, 2, figsize=(9, 4))
>>> ax1 = pg.qqplot(x, dist='norm', ax=ax1, confidence=False)
>>> ax2 = pg.qqplot(x_exp, dist='expon', ax=ax2)
Using custom location / scale parameters as well as another Seaborn style
.. plot::
>>> import numpy as np
>>> import seaborn as sns
>>> import pingouin as pg
>>> import matplotlib.pyplot as plt
>>> np.random.seed(123)
>>> x = np.random.normal(size=50)
>>> mean, std = 0, 0.8
>>> sns.set_style('darkgrid')
>>> ax = pg.qqplot(x, dist='norm', sparams=(mean, std))
"""
# Update default kwargs with specified inputs
_scatter_kwargs = {"marker": "o", "color": "blue"}
_scatter_kwargs.update(kwargs)
if isinstance(dist, str):
dist = getattr(stats, dist)
x = np.asarray(x)
x = x[~np.isnan(x)] # NaN are automatically removed
# Check sparams: if single parameter, tuple becomes int
if not isinstance(sparams, (tuple, list)):
sparams = (sparams,)
# For fancier distributions, check that the required parameters are passed
if len(sparams) < dist.numargs:
raise ValueError(
"The following sparams are required for this "
"distribution: %s. See scipy.stats.%s for details." % (dist.shapes, dist.name)
)
# Extract quantiles and regression
quantiles = stats.probplot(x, sparams=sparams, dist=dist, fit=False)
theor, observed = quantiles[0], quantiles[1]
fit_params = dist.fit(x)
loc = fit_params[-2]
scale = fit_params[-1]
shape = fit_params[:-2] if len(fit_params) > 2 else None
# Observed values to observed quantiles
if loc != 0 and scale != 1:
observed = (np.sort(observed) - fit_params[-2]) / fit_params[-1]
# Linear regression
slope, intercept, r, _, _ = stats.linregress(theor, observed)
# Start the plot
if ax is None:
ax = plt.gca()
ax.scatter(theor, observed, **_scatter_kwargs)
ax.set_xlabel("Theoretical quantiles")
ax.set_ylabel("Ordered quantiles")
# Add diagonal line
end_pts = [ax.get_xlim(), ax.get_ylim()]
end_pts[0] = min(end_pts[0])
end_pts[1] = max(end_pts[1])
ax.plot(end_pts, end_pts, color="slategrey", lw=1.5)
ax.set_xlim(end_pts)
ax.set_ylim(end_pts)
# Add regression line and annotate R2
fit_val = slope * theor + intercept
ax.plot(theor, fit_val, "r-", lw=2)
posx = end_pts[0] + 0.60 * (end_pts[1] - end_pts[0])
posy = end_pts[0] + 0.10 * (end_pts[1] - end_pts[0])
ax.text(posx, posy, "$R^2=%.3f$" % r**2)
if confidence is not False:
# Confidence envelope
n = x.size
P = _ppoints(n)
crit = stats.norm.ppf(1 - (1 - confidence) / 2)
pdf = dist.pdf(theor) if shape is None else dist.pdf(theor, *shape)
se = (slope / pdf) * np.sqrt(P * (1 - P) / n)
upper = fit_val + crit * se
lower = fit_val - crit * se
ax.plot(theor, upper, "r--", lw=1.25)
ax.plot(theor, lower, "r--", lw=1.25)
# Make square
if square:
ax.set_aspect("equal")
return ax
| (x, dist='norm', sparams=(), confidence=0.95, square=True, ax=None, **kwargs) | [
0.03692981228232384,
0.015381754375994205,
0.024687886238098145,
-0.03720185533165932,
0.01881629414856434,
-0.03563760966062546,
0.013228082098066807,
-0.021967457607388496,
0.023044293746352196,
0.03763258829712868,
0.03155696764588356,
0.04493240639567375,
0.023509033024311066,
0.08183954656124115,
-0.05087200552225113,
0.04783419519662857,
-0.011102747172117233,
-0.020255854353308678,
-0.00757185835391283,
0.01640191487967968,
-0.022058138623833656,
0.019258365035057068,
-0.007809896022081375,
0.01813618838787079,
0.010717353783547878,
-0.01769411750137806,
-0.007770223077386618,
-0.04964781552553177,
-0.03479881212115288,
0.01836289092898369,
-0.026954909786581993,
-0.05912397429347038,
0.019519072026014328,
-0.08365316689014435,
0.01790948584675789,
0.03794997185468674,
0.042325329035520554,
-0.03318922221660614,
0.01721804402768612,
0.01546110026538372,
-0.022341515868902206,
0.01804550737142563,
0.03021942265331745,
-0.04747147113084793,
0.01659461110830307,
0.05254960432648659,
-0.059668056666851044,
0.11661569029092789,
-0.05245892331004143,
0.0150530356913805,
0.08777914941310883,
-0.00855801347643137,
-0.006461016833782196,
0.010887380689382553,
0.03015141189098358,
0.013522795401513577,
-0.0074245017021894455,
0.053955160081386566,
0.06234314665198326,
-0.059441354125738144,
0.04883168637752533,
0.07263543456792831,
-0.0011398877250030637,
-0.022602224722504616,
0.01514371670782566,
-0.003970124758780003,
0.025549354031682014,
-0.06918955594301224,
-0.021978791803121567,
0.015064370818436146,
0.011216098442673683,
0.060212142765522,
-0.03513886407017708,
-0.029675336554646492,
0.023622384294867516,
0.0617990605533123,
-0.0027983570471405983,
-0.010167600587010384,
-0.028020409867167473,
0.009379809722304344,
0.057673078030347824,
0.09430817514657974,
0.014361593872308731,
-0.05309369042515755,
-0.039808932691812515,
0.014996360056102276,
0.00043144289520569146,
0.023735735565423965,
0.05336573347449303,
0.006789735518395901,
-0.057945121079683304,
-0.012309937737882137,
0.08882197737693787,
0.004913773387670517,
0.002038904232904315,
-0.03139827400445938,
-0.011476806364953518,
-0.029924709349870682,
-0.027113601565361023,
-0.04765283316373825,
-0.0009004333987832069,
0.001248279819265008,
-0.019485067576169968,
0.02951664663851261,
-0.03604567423462868,
-0.0006917963619343936,
-0.0016917663160711527,
0.03386932983994484,
-0.014690312556922436,
0.0016535102622583508,
-0.06030282378196716,
0.028133761137723923,
-0.014622301794588566,
0.005761073436588049,
-0.012468629516661167,
-0.006330662872642279,
-0.0896381065249443,
0.010241278447210789,
0.023066964000463486,
-0.03647640720009804,
-0.03434540703892708,
0.04960247501730919,
-0.042756062000989914,
-0.010683348402380943,
0.00923245307058096,
-0.020731929689645767,
0.027045590803027153,
-0.014293583109974861,
-0.03133026510477066,
-0.040625061839818954,
0.04368554428219795,
-0.028496485203504562,
-0.03062748722732067,
0.018918311223387718,
0.010615337640047073,
0.005154644604772329,
-0.0035988998133689165,
-0.019847789779305458,
0.038652751594781876,
0.04379889369010925,
0.05332039296627045,
0.029766017571091652,
-0.05096268653869629,
-0.0013835927238687873,
-0.011148087680339813,
0.01758076623082161,
0.038290027529001236,
-0.01866893842816353,
0.0031114898156374693,
-0.04688204452395439,
-0.023032959550619125,
0.010717353783547878,
0.009306131862103939,
-0.07413166761398315,
0.03096754103899002,
-0.10110924392938614,
0.020618578419089317,
-0.0020091496407985687,
0.0020814109593629837,
0.03674845024943352,
0.025345321744680405,
-0.015019030310213566,
0.06470084935426712,
-0.012615986168384552,
-0.040534380823373795,
0.020199179649353027,
-0.0004626144946087152,
0.005341674201190472,
0.005729902070015669,
-0.03516153246164322,
-0.01636791042983532,
0.0013637563679367304,
-0.00865436252206564,
0.002476723166182637,
-0.055995479226112366,
-0.0046417308039963245,
-0.042370669543743134,
0.021582063287496567,
-0.006143633741885424,
-0.06692253053188324,
0.00854101125150919,
-0.06062020733952522,
0.010507653467357159,
-0.006914421450346708,
-0.03636305779218674,
0.021922117099165916,
0.03035544417798519,
0.004780585877597332,
0.00907376129180193,
-0.01629989966750145,
-0.03035544417798519,
-0.03760991990566254,
-0.05159745365381241,
-0.01831755042076111,
-0.0058319177478551865,
0.022704239934682846,
0.006404341198503971,
-0.00015736330533400178,
0.03606834262609482,
-0.012151245959103107,
-0.0007261559367179871,
-0.019099673256278038,
0.013398109003901482,
-0.04665534198284149,
-0.00002201713687099982,
-0.01467897742986679,
-0.020822610706090927,
-0.03697515279054642,
0.06456483155488968,
0.027249623090028763,
0.058126483112573624,
-0.039763592183589935,
-0.020040487870573997,
0.005973606836050749,
-0.02922193333506584,
0.08329044282436371,
-0.009062426164746284,
-0.08011660724878311,
-0.0057554058730602264,
0.01769411750137806,
0.09022753685712814,
-0.04683670401573181,
-0.025685375556349754,
0.07694277912378311,
0.0064780195243656635,
0.05059996247291565,
0.1181572675704956,
0.041146475821733475,
0.041917264461517334,
-0.07816696912050247,
0.07218202948570251,
0.013738161884248257,
0.07295281440019608,
-0.020414546132087708,
-0.037133846431970596,
-0.028405804187059402,
0.00224718707613647,
0.04661000147461891,
-0.06773865967988968,
0.055632755160331726,
-0.04797021672129631,
0.007537852972745895,
-0.026524174958467484,
0.04432030767202377,
-0.01727471873164177,
-0.01644725538790226,
-0.0183402206748724,
0.06660515069961548,
-0.011561819352209568,
-0.053773798048496246,
0.009136104956269264,
0.0364537388086319,
-0.04751681163907051,
-0.05205085873603821,
0.03006073087453842,
-0.01785280928015709,
0.01739940606057644,
-0.057310353964567184,
0.03658976033329964,
-0.01843090169131756,
0.003488382324576378,
0.00379726430401206,
-0.039128825068473816,
0.03307587280869484,
0.04250669106841087,
-0.020720595493912697,
-0.07843901216983795,
0.008098941296339035,
0.0072374725714325905,
0.029652666300535202,
0.024030448868870735,
0.056176841259002686,
-0.014939684420824051,
0.0015571617987006903,
-0.010609669610857964,
0.04824225977063179,
0.029629996046423912,
-0.03398268297314644,
0.05019190162420273,
-0.03332524374127388,
-0.009793541394174099,
-0.039491549134254456,
0.006920089013874531,
0.006608373485505581,
0.0165266003459692,
-0.01614120788872242,
-0.01582382433116436,
0.012763341888785362,
-0.0089150695130229,
0.029743347316980362,
-0.03556959703564644,
-0.005525869783014059,
-0.03844871744513512,
-0.01746741682291031,
0.03021942265331745,
0.028768528252840042,
0.0072488076984882355,
0.021412037312984467,
0.01845357194542885,
0.006823740899562836,
0.010122260078787804,
0.021105987951159477,
0.04719942808151245,
0.03615902364253998,
0.01724071428179741,
0.037791281938552856,
0.027068261057138443,
-0.08406122773885727,
-0.011556152254343033,
-0.00920978281646967,
0.006614041049033403,
0.08410657197237015,
-0.01636791042983532,
0.010127927176654339,
0.01908833719789982,
0.0009762370027601719,
-0.0036102349404245615,
-0.012423289008438587,
-0.0005809247959405184,
0.005100802984088659,
-0.041350509971380234,
-0.04729010909795761,
0.04855964332818985,
-0.0353202261030674,
0.04833294078707695,
0.0011172174708917737,
-0.09049957990646362,
0.02926727384328842,
0.0064780195243656635,
0.011386125348508358,
-0.014066880568861961,
0.03629504516720772,
0.003173832781612873,
0.010932721197605133,
-0.013624811545014381,
0.012219256721436977,
0.005225488916039467,
-0.011346452869474888,
-0.005406850948929787,
-0.0590786337852478,
-0.024959929287433624,
-0.0348668210208416,
0.010791031643748283,
0.04665534198284149,
-0.03425472602248192,
-0.012763341888785362,
0.014055545441806316,
-0.041463859379291534,
0.027294963598251343,
-0.03028743341565132,
-0.0064780195243656635,
0.002261355984956026,
0.025730716064572334,
-0.0014664807822555304,
0.002961299382150173,
0.06148167699575424,
0.04305077716708183,
0.0029442966915667057,
-0.011006399057805538,
0.0303327739238739,
0.06284189224243164,
0.03024209290742874,
-0.04357219114899635,
0.022239500656723976,
-0.026796218007802963,
0.006920089013874531,
-0.007464174646884203,
0.008030930534005165,
0.01569913700222969,
0.04418428614735603,
0.005392682272940874,
-0.013114730827510357,
-0.06633310765028,
0.007039107847958803,
-0.0013786336639896035,
0.011391793377697468,
-0.024257151409983635,
0.01616387814283371,
-0.019451061263680458,
-0.03563760966062546,
-0.013942194171249866,
-0.07807628810405731,
-0.013092060573399067,
-0.01640191487967968,
-0.04343616962432861,
0.012547975406050682,
-0.03323456272482872,
0.03112623281776905,
0.013568135909736156,
-0.056630246341228485,
-0.058035802096128464,
-0.05109870806336403,
0.06279654800891876,
0.06334063410758972,
-0.01559712179005146,
0.00782123114913702,
0.04883168637752533,
0.009929562918841839,
-0.1208776906132698,
0.011584489606320858,
-0.01648125983774662,
-0.0006071372190490365,
-0.021446041762828827,
0.040511708706617355,
0.040080975741147995,
-0.07866571843624115,
-0.0064893546514213085,
-0.0042166635394096375,
-0.00445753475651145,
-0.01603919081389904,
-0.010450977832078934,
-0.039264846593141556,
-0.0729074776172638,
-0.029675336554646492,
-0.026274802163243294,
0.006404341198503971,
-0.027703026309609413,
-0.040602389723062515,
0.03420938551425934,
0.01663995161652565,
0.024778567254543304,
-0.06034816429018974,
0.008319975808262825,
0.03817667439579964,
-0.0031993368174880743,
0.024914588779211044,
-0.005729902070015669,
-0.01915634796023369,
0.037088505923748016,
-0.005423853639513254,
-0.009952233172953129,
-0.0384940579533577,
-0.04166789352893829,
0.015291073359549046,
-0.01882763020694256,
-0.013794837519526482,
-0.011845197528600693,
0.01908833719789982,
-0.009045423939824104,
0.022794920951128006,
-0.007532185409218073,
0.013160071335732937,
-0.011329449713230133,
-0.07621733099222183,
-0.01773945800960064,
0.04500041529536247,
0.04960247501730919,
-0.040489040315151215,
-0.02926727384328842,
-0.0167533028870821,
0.040035635232925415,
0.056584905833005905,
0.025708045810461044,
0.009000083431601524,
0.0019864793866872787,
-0.08242897689342499,
0.006580035667866468,
-0.07662539184093475,
-0.014259577728807926,
0.026002759113907814,
0.029675336554646492,
0.01614120788872242,
-0.0754012018442154,
-0.019371716305613518,
0.022602224722504616,
0.08256499469280243,
0.03185167908668518,
0.006823740899562836,
-0.005157478619366884,
-0.03529755398631096,
0.05994009971618652,
0.04647397994995117,
-0.040353018790483475,
0.003241843543946743,
0.03196503221988678,
0.07998058944940567,
-0.039831601083278656,
0.0690535381436348,
0.028020409867167473,
-0.005916931200772524,
0.01713869720697403,
-0.06479153037071228,
0.039831601083278656,
0.06252450495958328,
0.026456164196133614,
-0.024597205221652985,
0.019099673256278038,
-0.042121294885873795,
-0.0019638091325759888,
0.03307587280869484,
0.04495507478713989,
0.010343294590711594,
-0.00855801347643137,
0.01812485232949257,
-0.05096268653869629,
0.06075622886419296,
0.01874828338623047,
-0.03817667439579964,
-0.00016967253759503365,
-0.056176841259002686,
0.059758737683296204,
-0.04166789352893829,
0.002829528646543622,
-0.011380458250641823,
0.011788521893322468,
-0.026274802163243294,
0.0020969966426491737,
0.07435837388038635,
-0.054272543638944626,
-0.026705536991357803,
-0.001180269056931138,
-0.05912397429347038,
0.05091734603047371,
-0.06007612124085426,
0.03563760966062546,
-0.022205494344234467,
-0.006710389629006386,
0.053637776523828506,
-0.038698092103004456,
-0.037972643971443176,
0.010433975607156754,
0.04411627724766731,
0.026433493942022324,
-0.00038751933607272804,
0.020867951214313507,
-0.013896853663027287,
-0.0161298718303442,
0.024687886238098145,
0.0375872477889061,
0.023713065311312675,
0.006563032977283001,
0.006925756577402353,
-0.028745857998728752,
-0.021933453157544136,
0.03074083849787712,
0.07794027030467987,
-0.04574853554368019,
-0.010020243935286999,
0.0615723580121994,
0.002614161465317011,
-0.020561903715133667,
0.039083484560251236,
0.06320461630821228,
-0.00804793369024992,
-0.012468629516661167,
0.05109870806336403,
0.010258281603455544,
0.010263948701322079,
0.021548058837652206,
-0.042121294885873795,
0.027521664276719093,
-0.0074585070833563805,
0.03643106669187546,
0.01661728136241436,
0.00025433170958422124,
0.01845357194542885,
0.039355527609586716,
0.0006074914708733559,
-0.03194236010313034,
-0.027181612327694893,
0.013534130528569221,
0.08410657197237015,
0.03756457939743996,
-0.025277310982346535,
-0.0065573654137551785,
0.00025450880639255047,
0.00752651784569025,
0.00887539703398943,
-0.04282407462596893,
-0.056720927357673645,
-0.010966726578772068,
0.0738142877817154,
-0.03164764866232872,
0.01924702897667885,
-0.00800259318202734,
-0.03799531236290932,
0.06057486683130264,
-0.023962438106536865,
-0.08057001233100891,
-0.004959113895893097,
-0.008212292566895485,
-0.010433975607156754,
-0.005888593383133411,
-0.04477371275424957,
0.010762694291770458,
-0.042846743017435074,
-0.037881962954998016,
0.037927303463220596,
0.010853375308215618,
-0.0018603760981932282,
0.01543843001127243,
0.05005588009953499,
-0.03187435120344162,
-0.0627058669924736,
0.05232290178537369,
-0.013137401081621647,
0.021695414558053017,
-0.039264846593141556,
-0.005293499678373337,
0.03017408214509487,
-0.0009266458218917251,
0.029108582064509392,
0.00885272677987814,
-0.07263543456792831,
0.006013279780745506,
-0.014236907474696636,
-0.003029310144484043,
0.0091701103374362,
-0.057219672948122025,
-0.012366613373160362,
0.040851764380931854,
0.05844386667013168,
-0.00770787987858057,
-0.01546110026538372,
-0.028655176982283592,
-0.055315371602773666,
-0.02949397638440132,
0.00856368150562048,
0.027907058596611023,
0.038788773119449615,
0.0015529111260548234,
0.011159422807395458,
0.025685375556349754,
0.040511708706617355,
-0.015404424630105495,
-0.01908833719789982,
0.01838556118309498,
-0.03590965270996094,
-0.0049959528259932995,
-0.03273582085967064,
0.028224442154169083,
-0.0012532388791441917,
0.03241843730211258,
-0.08514939993619919,
-0.06030282378196716,
-0.0037802616134285927,
-0.05304834991693497,
-0.009283461607992649,
-0.03729253634810448,
0.057582397013902664,
0.014939684420824051,
0.0041316500864923,
0.019564412534236908,
0.004845762625336647,
0.08061535656452179,
0.023554373532533646,
-0.013636146672070026,
-0.03479881212115288,
0.03137560561299324,
-0.05078132450580597,
0.0372471958398819,
0.004978950135409832,
-0.01817019283771515,
0.021196668967604637,
0.023395681753754616,
0.0017101858975365758,
-0.04436564818024635,
-0.0305594764649868,
0.0337333083152771,
0.00442636338993907,
0.08274635672569275,
-0.06388472020626068,
0.024778567254543304,
0.003853939939290285,
-0.010377299971878529,
0.03300786018371582,
0.0022330181673169136,
0.004468869883567095,
-0.06071088835597038,
-0.04846896231174469,
0.011153755709528923,
0.03420938551425934,
0.011754516512155533,
-0.03275848925113678,
-0.04545382037758827,
0.012468629516661167,
-0.04842362180352211,
-0.013613476417958736,
-0.07349690049886703,
-0.011641165241599083,
0.03262246772646904,
-0.00739616435021162,
-0.01512104645371437,
-0.01577848382294178,
0.023055627942085266,
0.02999272011220455,
0.006789735518395901,
-0.041826583445072174,
-0.025186631828546524,
0.01691199466586113,
-0.005106470547616482,
0.03316655382514,
-0.027657685801386833,
-0.03522954508662224,
0.009311798959970474,
-0.03275848925113678,
-0.04846896231174469,
-0.022930942475795746,
0.06034816429018974,
-0.042574699968099594,
0.0615723580121994,
0.0047295778058469296,
0.06062020733952522,
0.07218202948570251,
-0.04561251401901245,
0.022443532943725586,
-0.06492755562067032,
0.011754516512155533,
0.025005269795656204,
-0.057945121079683304,
-0.04527245834469795,
-0.03398268297314644,
-0.0017597769619897008,
-0.054227203130722046,
-0.04828760027885437,
-0.03185167908668518,
0.021117324009537697,
0.04697272554039955,
0.022341515868902206,
0.020686589181423187,
0.03579629957675934,
0.001338960719294846,
-0.014304918237030506,
-0.0040041301399469376,
0.04438832029700279,
0.04561251401901245,
-0.008365316316485405,
-0.022341515868902206,
0.0032956853974610567,
-0.06084690988063812,
-0.009311798959970474,
0.0355469286441803,
-0.03683913126587868,
0.03652174770832062,
-0.0003283641708549112,
0.00892073754221201,
-0.04531779885292053,
-0.027657685801386833,
0.0009011418442241848,
0.005412518512457609,
0.0010839205933734775,
0.0040069641545414925,
0.01795482635498047,
-0.06474619358778,
0.03178367018699646,
-0.01839689537882805,
-0.006767065264284611,
0.01539308950304985,
0.00813861470669508,
0.007577525917440653,
0.06161769852042198,
-0.010796699672937393,
-0.01712736301124096,
0.03609101474285126,
-0.009045423939824104,
0.025844067335128784,
0.013613476417958736,
0.055406052619218826,
-0.018918311223387718,
-0.05245892331004143,
-0.04500041529536247,
0.01683264970779419,
0.04964781552553177,
0.040670402348041534,
0.012593315914273262,
0.006075622979551554,
-0.057582397013902664,
0.025889407843351364
]
|
32,054 | pingouin.correlation | rcorr |
Correlation matrix of a dataframe with p-values and/or sample size on the
upper triangle (:py:class:`pandas.DataFrame` method).
This method is a faster, but less exhaustive, matrix-version of the
:py:func:`pingouin.pairwise_corr` function. It is based on the
:py:func:`pandas.DataFrame.corr` method. Missing values are automatically
removed from each pairwise correlation.
Parameters
----------
self : :py:class:`pandas.DataFrame`
Input dataframe.
method : str
Correlation method. Can be either 'pearson' or 'spearman'.
upper : str
If 'pval', the upper triangle of the output correlation matrix shows
the p-values. If 'n', the upper triangle is the sample size used in
each pairwise correlation.
decimals : int
Number of decimals to display in the output correlation matrix.
padjust : string or None
Method used for testing and adjustment of pvalues.
* ``'none'``: no correction
* ``'bonf'``: one-step Bonferroni correction
* ``'sidak'``: one-step Sidak correction
* ``'holm'``: step-down method using Bonferroni adjustments
* ``'fdr_bh'``: Benjamini/Hochberg FDR correction
* ``'fdr_by'``: Benjamini/Yekutieli FDR correction
stars : boolean
If True, only significant p-values are displayed as stars using the
pre-defined thresholds of ``pval_stars``. If False, all the raw
p-values are displayed.
pval_stars : dict
Significance thresholds. Default is 3 stars for p-values < 0.001,
2 stars for p-values < 0.01 and 1 star for p-values < 0.05.
Returns
-------
rcorr : :py:class:`pandas.DataFrame`
Correlation matrix, of type str.
Examples
--------
>>> import numpy as np
>>> import pandas as pd
>>> import pingouin as pg
>>> # Load an example dataset of personality dimensions
>>> df = pg.read_dataset('pairwise_corr').iloc[:, 1:]
>>> # Add some missing values
>>> df.iloc[[2, 5, 20], 2] = np.nan
>>> df.iloc[[1, 4, 10], 3] = np.nan
>>> df.head().round(2)
Neuroticism Extraversion Openness Agreeableness Conscientiousness
0 2.48 4.21 3.94 3.96 3.46
1 2.60 3.19 3.96 NaN 3.23
2 2.81 2.90 NaN 2.75 3.50
3 2.90 3.56 3.52 3.17 2.79
4 3.02 3.33 4.02 NaN 2.85
>>> # Correlation matrix on the four first columns
>>> df.iloc[:, 0:4].rcorr()
Neuroticism Extraversion Openness Agreeableness
Neuroticism - *** **
Extraversion -0.35 - ***
Openness -0.01 0.265 - ***
Agreeableness -0.134 0.054 0.161 -
>>> # Spearman correlation and Holm adjustement for multiple comparisons
>>> df.iloc[:, 0:4].rcorr(method='spearman', padjust='holm')
Neuroticism Extraversion Openness Agreeableness
Neuroticism - *** **
Extraversion -0.325 - ***
Openness -0.027 0.24 - ***
Agreeableness -0.15 0.06 0.173 -
>>> # Compare with the pg.pairwise_corr function
>>> pairwise = df.iloc[:, 0:4].pairwise_corr(method='spearman',
... padjust='holm')
>>> pairwise[['X', 'Y', 'r', 'p-corr']].round(3) # Do not show all columns
X Y r p-corr
0 Neuroticism Extraversion -0.325 0.000
1 Neuroticism Openness -0.027 0.543
2 Neuroticism Agreeableness -0.150 0.002
3 Extraversion Openness 0.240 0.000
4 Extraversion Agreeableness 0.060 0.358
5 Openness Agreeableness 0.173 0.000
>>> # Display the raw p-values with four decimals
>>> df.iloc[:, [0, 1, 3]].rcorr(stars=False, decimals=4)
Neuroticism Extraversion Agreeableness
Neuroticism - 0.0000 0.0028
Extraversion -0.3501 - 0.2305
Agreeableness -0.134 0.0539 -
>>> # With the sample size on the upper triangle instead of the p-values
>>> df.iloc[:, [0, 1, 2]].rcorr(upper='n')
Neuroticism Extraversion Openness
Neuroticism - 500 497
Extraversion -0.35 - 497
Openness -0.01 0.265 -
| @pf.register_dataframe_method
def rcorr(
self,
method="pearson",
upper="pval",
decimals=3,
padjust=None,
stars=True,
pval_stars={0.001: "***", 0.01: "**", 0.05: "*"},
):
"""
Correlation matrix of a dataframe with p-values and/or sample size on the
upper triangle (:py:class:`pandas.DataFrame` method).
This method is a faster, but less exhaustive, matrix-version of the
:py:func:`pingouin.pairwise_corr` function. It is based on the
:py:func:`pandas.DataFrame.corr` method. Missing values are automatically
removed from each pairwise correlation.
Parameters
----------
self : :py:class:`pandas.DataFrame`
Input dataframe.
method : str
Correlation method. Can be either 'pearson' or 'spearman'.
upper : str
If 'pval', the upper triangle of the output correlation matrix shows
the p-values. If 'n', the upper triangle is the sample size used in
each pairwise correlation.
decimals : int
Number of decimals to display in the output correlation matrix.
padjust : string or None
Method used for testing and adjustment of pvalues.
* ``'none'``: no correction
* ``'bonf'``: one-step Bonferroni correction
* ``'sidak'``: one-step Sidak correction
* ``'holm'``: step-down method using Bonferroni adjustments
* ``'fdr_bh'``: Benjamini/Hochberg FDR correction
* ``'fdr_by'``: Benjamini/Yekutieli FDR correction
stars : boolean
If True, only significant p-values are displayed as stars using the
pre-defined thresholds of ``pval_stars``. If False, all the raw
p-values are displayed.
pval_stars : dict
Significance thresholds. Default is 3 stars for p-values < 0.001,
2 stars for p-values < 0.01 and 1 star for p-values < 0.05.
Returns
-------
rcorr : :py:class:`pandas.DataFrame`
Correlation matrix, of type str.
Examples
--------
>>> import numpy as np
>>> import pandas as pd
>>> import pingouin as pg
>>> # Load an example dataset of personality dimensions
>>> df = pg.read_dataset('pairwise_corr').iloc[:, 1:]
>>> # Add some missing values
>>> df.iloc[[2, 5, 20], 2] = np.nan
>>> df.iloc[[1, 4, 10], 3] = np.nan
>>> df.head().round(2)
Neuroticism Extraversion Openness Agreeableness Conscientiousness
0 2.48 4.21 3.94 3.96 3.46
1 2.60 3.19 3.96 NaN 3.23
2 2.81 2.90 NaN 2.75 3.50
3 2.90 3.56 3.52 3.17 2.79
4 3.02 3.33 4.02 NaN 2.85
>>> # Correlation matrix on the four first columns
>>> df.iloc[:, 0:4].rcorr()
Neuroticism Extraversion Openness Agreeableness
Neuroticism - *** **
Extraversion -0.35 - ***
Openness -0.01 0.265 - ***
Agreeableness -0.134 0.054 0.161 -
>>> # Spearman correlation and Holm adjustement for multiple comparisons
>>> df.iloc[:, 0:4].rcorr(method='spearman', padjust='holm')
Neuroticism Extraversion Openness Agreeableness
Neuroticism - *** **
Extraversion -0.325 - ***
Openness -0.027 0.24 - ***
Agreeableness -0.15 0.06 0.173 -
>>> # Compare with the pg.pairwise_corr function
>>> pairwise = df.iloc[:, 0:4].pairwise_corr(method='spearman',
... padjust='holm')
>>> pairwise[['X', 'Y', 'r', 'p-corr']].round(3) # Do not show all columns
X Y r p-corr
0 Neuroticism Extraversion -0.325 0.000
1 Neuroticism Openness -0.027 0.543
2 Neuroticism Agreeableness -0.150 0.002
3 Extraversion Openness 0.240 0.000
4 Extraversion Agreeableness 0.060 0.358
5 Openness Agreeableness 0.173 0.000
>>> # Display the raw p-values with four decimals
>>> df.iloc[:, [0, 1, 3]].rcorr(stars=False, decimals=4)
Neuroticism Extraversion Agreeableness
Neuroticism - 0.0000 0.0028
Extraversion -0.3501 - 0.2305
Agreeableness -0.134 0.0539 -
>>> # With the sample size on the upper triangle instead of the p-values
>>> df.iloc[:, [0, 1, 2]].rcorr(upper='n')
Neuroticism Extraversion Openness
Neuroticism - 500 497
Extraversion -0.35 - 497
Openness -0.01 0.265 -
"""
from numpy import triu_indices_from as tif
from numpy import format_float_positional as ffp
from scipy.stats import pearsonr, spearmanr
# Safety check
assert isinstance(pval_stars, dict), "pval_stars must be a dictionnary."
assert isinstance(decimals, int), "decimals must be an int."
assert method in ["pearson", "spearman"], "Method is not recognized."
assert upper in ["pval", "n"], "upper must be either `pval` or `n`."
mat = self.corr(method=method, numeric_only=True).round(decimals)
if upper == "n":
mat_upper = self.corr(method=lambda x, y: len(x), numeric_only=True).astype(int)
else:
if method == "pearson":
mat_upper = self.corr(method=lambda x, y: pearsonr(x, y)[1], numeric_only=True)
else:
# Method = 'spearman'
mat_upper = self.corr(method=lambda x, y: spearmanr(x, y)[1], numeric_only=True)
if padjust is not None:
pvals = mat_upper.to_numpy()[tif(mat, k=1)]
mat_upper.to_numpy()[tif(mat, k=1)] = multicomp(pvals, alpha=0.05, method=padjust)[1]
# Convert r to text
mat = mat.astype(str)
# Inplace modification of the diagonal
np.fill_diagonal(mat.to_numpy(), "-")
if upper == "pval":
def replace_pval(x):
for key, value in pval_stars.items():
if x < key:
return value
return ""
if stars:
# Replace p-values by stars
mat_upper = mat_upper.applymap(replace_pval)
else:
mat_upper = mat_upper.applymap(lambda x: ffp(x, precision=decimals))
# Replace upper triangle by p-values or n
mat.to_numpy()[tif(mat, k=1)] = mat_upper.to_numpy()[tif(mat, k=1)]
return mat
| (self, method='pearson', upper='pval', decimals=3, padjust=None, stars=True, pval_stars={0.001: '***', 0.01: '**', 0.05: '*'}) | [
-0.004317834507673979,
-0.021191952750086784,
0.04708864167332649,
-0.01414516381919384,
0.029033180326223373,
-0.050142593681812286,
-0.010276136919856071,
0.01358802430331707,
0.07436786592006683,
0.01327850203961134,
-0.01645626313984394,
0.03443950042128563,
0.009404315613210201,
0.07919640839099884,
-0.051875919103622437,
0.0015966185601428151,
0.0038896622136235237,
-0.006866233889013529,
-0.026990333572030067,
-0.025318915024399757,
0.007485277950763702,
0.019582437351346016,
-0.0419299378991127,
0.014392782002687454,
-0.008965825662016869,
-0.0020106045994907618,
-0.027630014345049858,
-0.030766505748033524,
0.018354665488004684,
0.054021939635276794,
-0.00303331739269197,
-0.026330020278692245,
-0.032045863568782806,
0.009502330794930458,
-0.048945773392915726,
-0.05216480419039726,
0.02599986270070076,
-0.02992047742009163,
-0.021357031539082527,
0.043209295719861984,
-0.03177760913968086,
-0.0012509855441749096,
-0.007170597091317177,
-0.06054253876209259,
-0.035326797515153885,
0.01157613005489111,
-0.02998238243162632,
0.040361691266298294,
-0.023420512676239014,
-0.008186861872673035,
0.03784424439072609,
-0.04535531625151634,
-0.04250771179795265,
-0.00846543163061142,
-0.019045932218432426,
0.0771329253911972,
-0.015197538770735264,
0.056869544088840485,
0.02319352887570858,
-0.05158703029155731,
0.04230136424303055,
-0.003737480379641056,
-0.030415713787078857,
0.033572837710380554,
0.049028314650058746,
-0.04378707334399223,
0.04531404748558998,
-0.016229279339313507,
0.02996174804866314,
-0.04452992603182793,
-0.018942758440971375,
0.03285061940550804,
0.004769220948219299,
-0.012246761471033096,
0.01073010265827179,
-0.0019009821116924286,
0.015476109459996223,
-0.042796600610017776,
0.02439034730195999,
-0.015249126590788364,
-0.007614245638251305,
0.014041990041732788,
0.09797409176826477,
-0.04176485911011696,
-0.01470230333507061,
-0.037575993686914444,
0.02197607420384884,
0.015084047801792622,
0.041517242789268494,
-0.014361829496920109,
-0.02942524291574955,
-0.026330020278692245,
0.03774107247591019,
-0.029218893498182297,
-0.015682457014918327,
-0.004650570917874575,
0.04254898428916931,
0.003304149257019162,
0.03346966579556465,
-0.018911805003881454,
-0.02655700407922268,
0.057901281863451004,
0.02043878100812435,
0.025112565606832504,
0.020583225414156914,
0.029776034876704216,
-0.020139576867222786,
0.05369178205728531,
0.004557714331895113,
0.019066566601395607,
-0.07548214495182037,
0.022780831903219223,
0.06050126999616623,
-0.037080757319927216,
0.014867382124066353,
-0.029817303642630577,
-0.07048851996660233,
0.04143470153212547,
-0.01696181483566761,
0.02893000654876232,
0.03446013480424881,
0.034253787249326706,
0.0039360905066132545,
-0.030683966353535652,
-0.04754260927438736,
0.010802323929965496,
-0.0027418506797403097,
-0.008295194245874882,
-0.02998238243162632,
0.02381257340312004,
0.00003318900053272955,
0.01188565231859684,
0.012422156520187855,
0.006819805596023798,
-0.002300781663507223,
0.024183999747037888,
0.02822842262685299,
-0.03117920085787773,
0.03609028831124306,
-0.00204155663959682,
0.06285364180803299,
0.05323781445622444,
0.01358802430331707,
0.018953075632452965,
0.02651573345065117,
0.05439336597919464,
0.041022006422281265,
0.05113306641578674,
0.022780831903219223,
-0.010967402718961239,
0.010322565212845802,
-0.026185575872659683,
0.07498690485954285,
0.003642044262960553,
0.07614246010780334,
-0.051215603947639465,
0.052866388112306595,
-0.057488586753606796,
-0.042796600610017776,
-0.04906958341598511,
0.03668869659304619,
-0.061863165348768234,
0.03326331824064255,
-0.0019022717606276274,
0.00469184061512351,
-0.012267395853996277,
0.05336162447929382,
-0.04469500482082367,
-0.02148083969950676,
-0.035966478288173676,
-0.02661890722811222,
-0.04630452021956444,
-0.027031604200601578,
-0.039783917367458344,
-0.04118708521127701,
0.05645684525370598,
-0.05158703029155731,
-0.016683245077729225,
-0.012246761471033096,
-0.004751165397465229,
0.0050864811055362225,
-0.055053677409887314,
-0.014857064932584763,
-0.002317547332495451,
-0.005063266959041357,
0.07032343745231628,
0.06260602176189423,
-0.056374307721853256,
0.053402893245220184,
-0.004844021983444691,
-0.057942554354667664,
-0.01413484662771225,
-0.014011037535965443,
0.08022814989089966,
0.05592034012079239,
-0.052866388112306595,
0.04585055261850357,
-0.017684035003185272,
0.018230857327580452,
-0.021191952750086784,
0.02550462819635868,
-0.007970196194946766,
-0.0048337047919631,
0.019984815269708633,
-0.0028192312456667423,
-0.02550462819635868,
-0.015393570065498352,
0.03169507160782814,
0.03334585577249527,
0.00564362108707428,
0.05831398069858551,
-0.0340474396944046,
0.04411722719669342,
-0.04353945329785347,
-0.0418267659842968,
0.02723795175552368,
0.0304776169359684,
-0.05703462287783623,
-0.008847176097333431,
0.029549051076173782,
0.06149173900485039,
0.016270549967885017,
-0.03150935843586922,
-0.0049755689688026905,
-0.019520532339811325,
0.033758554607629776,
-0.026845891028642654,
0.02608240209519863,
0.024183999747037888,
-0.055713992565870285,
0.008290035650134087,
-0.021872900426387787,
-0.013742784969508648,
-0.06244094297289848,
-0.04572674259543419,
-0.10952958464622498,
-0.0038148609455674887,
0.05360924080014229,
-0.06603139638900757,
0.039329953491687775,
-0.029590321704745293,
0.05129814147949219,
0.03460457921028137,
0.046180710196495056,
-0.006469013635069132,
-0.0338410921394825,
0.05707589164376259,
0.01499119121581316,
0.025030028074979782,
0.014176116324961185,
0.02325543388724327,
-0.09566298872232437,
-0.013732467778027058,
-0.009636457078158855,
0.03346966579556465,
-0.06008857488632202,
0.0087491599842906,
0.04029978811740875,
0.05521875619888306,
0.011328511871397495,
0.021315760910511017,
-0.04019661247730255,
0.02102687396109104,
-0.00380970211699605,
-0.009239236824214458,
-0.033118873834609985,
-0.061285391449928284,
0.0035801399499177933,
0.026391925290226936,
-0.018963392823934555,
-0.025587167590856552,
0.020614176988601685,
-0.05786001309752464,
0.027588743716478348,
-0.005189655348658562,
0.012339618057012558,
0.005622986238449812,
0.002343340776860714,
0.018911805003881454,
-0.017116576433181763,
0.030333174392580986,
-0.01930386759340763,
0.036956947296857834,
-0.012091999873518944,
0.006866233889013529,
0.04005217179656029,
-0.026268115267157555,
-0.015383252874016762,
0.052866388112306595,
0.025298280641436577,
0.02496812306344509,
-0.04120771959424019,
-0.031880784779787064,
0.028166519477963448,
0.04787276312708855,
0.029528416693210602,
0.025793515145778656,
-0.029755398631095886,
-0.025628436356782913,
-0.02100623957812786,
0.001652074628509581,
-0.02201734483242035,
0.05707589164376259,
-0.005540447309613228,
0.002327864756807685,
-0.011937239207327366,
0.05266004055738449,
-0.032582368701696396,
-0.020242750644683838,
0.012370569631457329,
0.0040985895320773125,
0.044983889907598495,
-0.04118708521127701,
-0.017436416819691658,
0.02711414359509945,
-0.013959450647234917,
0.015703091397881508,
-0.028001440688967705,
0.06359649449586868,
0.00039689772529527545,
-0.03524425998330116,
-0.06784725934267044,
0.034315694123506546,
0.014238020405173302,
-0.010301929898560047,
-0.014258655719459057,
-0.06103777512907982,
0.008408686146140099,
-0.024163365364074707,
0.004010891541838646,
0.017302289605140686,
0.016167376190423965,
0.0017152688233181834,
0.03346966579556465,
0.07337739318609238,
0.013030883856117725,
0.03699821978807449,
-0.0361521914601326,
0.023647494614124298,
-0.008315829560160637,
0.06772345304489136,
-0.051752109080553055,
0.0049833073280751705,
-0.021233221516013145,
-0.019035615026950836,
0.0395156666636467,
0.005540447309613228,
0.020118942484259605,
0.012236443348228931,
-0.07403770834207535,
0.01856101304292679,
0.02197607420384884,
-0.008898762986063957,
0.06169809028506279,
-0.006035682745277882,
0.06640282273292542,
-0.04469500482082367,
0.04147597402334213,
0.04572674259543419,
0.04019661247730255,
0.0032835144083946943,
0.0054888599552214146,
0.04005217179656029,
0.00024358750670216978,
-0.05142195150256157,
0.047212451696395874,
-0.09558045119047165,
0.0463457889854908,
-0.032603003084659576,
-0.00465572951361537,
-0.0015708251157775521,
-0.030415713787078857,
0.010508278384804726,
-0.020531637594103813,
-0.006422585342079401,
0.033118873834609985,
-0.021274492144584656,
-0.014815795235335827,
0.009713837876915932,
-0.06008857488632202,
0.01751895621418953,
-0.035904575139284134,
0.011307877488434315,
-0.00225693266838789,
-0.056787002831697464,
-0.017415782436728477,
0.008150750771164894,
0.017168164253234863,
-0.06937424093484879,
-0.013887228444218636,
-0.059180643409490585,
-0.028187153860926628,
0.013433262705802917,
-0.0226982943713665,
-0.034171249717473984,
0.02156337909400463,
-0.03559505194425583,
0.05303146690130234,
-0.03349030017852783,
0.02097528614103794,
0.03101412206888199,
-0.07589484006166458,
-0.011503907851874828,
-0.03285061940550804,
-0.00775868957862258,
0.013794371858239174,
0.040960103273391724,
-0.04296167939901352,
0.01129755936563015,
-0.008604716509580612,
-0.06206951662898064,
0.05703462287783623,
0.05930444970726967,
-0.009208285249769688,
-0.004426167346537113,
0.03111729770898819,
-0.015321347862482071,
0.0048646568320691586,
0.06124412268400192,
0.04362199455499649,
0.04589182138442993,
-0.04919339343905449,
-0.0001874866138678044,
0.07300596684217453,
0.018478473648428917,
0.013350723311305046,
0.010281295515596867,
-0.008640827611088753,
0.002806334523484111,
0.017178481444716454,
-0.011741207912564278,
0.02152210846543312,
-0.028703024610877037,
0.007000360172241926,
-0.00994082074612379,
-0.014196750707924366,
-0.04052677005529404,
0.04712991043925285,
-0.03786487877368927,
-0.007057105656713247,
0.04230136424303055,
-0.009326934814453125,
-0.009564235806465149,
-0.07812339812517166,
-0.042095016688108444,
0.0078824982047081,
0.03186015039682388,
-0.05604415014386177,
-0.08493288606405258,
-0.03239665552973747,
0.07098375260829926,
0.008547971025109291,
0.027960170060396194,
0.0553838349878788,
-0.020149894058704376,
0.03687440976500511,
-0.0071860733442008495,
-0.0032551416661590338,
-0.043745800852775574,
-0.025236375629901886,
-0.0026825256645679474,
0.03749345242977142,
-0.02540145441889763,
-0.01696181483566761,
0.000048201633035205305,
0.05777747556567192,
0.00191387883387506,
-0.01644594594836235,
-0.09458997845649719,
0.00852217711508274,
0.008826540783047676,
-0.05303146690130234,
-0.03955693542957306,
-0.0096674095839262,
-0.013381675817072392,
0.051091793924570084,
-0.04259025305509567,
0.019118154421448708,
-0.04186803475022316,
-0.005390844773501158,
-0.07312977313995361,
-0.025855420157313347,
-0.02653636783361435,
-0.0020131838973611593,
0.028434772044420242,
-0.055713992565870285,
-0.024018920958042145,
-0.015620552934706211,
0.018519744277000427,
-0.056910812854766846,
0.009863439947366714,
0.0727170780301094,
-0.01591975800693035,
0.08518050611019135,
-0.0259585939347744,
0.04572674259543419,
0.03126174211502075,
-0.0496060885488987,
0.005385686177760363,
0.001213584910146892,
0.03466648608446121,
0.00382775766775012,
-0.048367999494075775,
-0.006752742454409599,
0.048945773392915726,
-0.06388537585735321,
-0.02833159640431404,
0.02649509906768799,
-0.034315694123506546,
0.0006258151843212545,
-0.037080757319927216,
-0.03161253407597542,
0.0475013367831707,
-0.00872852560132742,
-0.023874478414654732,
-0.028393501415848732,
0.014588812366127968,
-0.017188798636198044,
-0.051875919103622437,
-0.00035401599598117173,
0.0002492298372089863,
-0.006830122787505388,
-0.0417235903441906,
0.07432659715414047,
-0.02488558366894722,
0.025855420157313347,
0.050142593681812286,
-0.011689621023833752,
0.020717350766062737,
-0.015259443782269955,
-0.04795530438423157,
0.01415548101067543,
-0.011400734074413776,
0.011957873590290546,
-0.000700293923728168,
0.030312540009617805,
-0.03470775485038757,
-0.062482211738824844,
0.05765366554260254,
-0.0024052453227341175,
-0.018829265609383583,
0.0008692414849065244,
-0.00594282615929842,
-0.03831884637475014,
0.01862291805446148,
-0.020830843597650528,
0.010802323929965496,
-0.04246644303202629,
0.018973710015416145,
0.008119798265397549,
0.06660917401313782,
-0.04395214840769768,
0.038153767585754395,
0.003219030797481537,
-0.024142730981111526,
0.04184740036725998,
0.031241105869412422,
-0.027918901294469833,
0.03167443722486496,
-0.026247480884194374,
0.010240025818347931,
-0.05550764501094818,
0.04186803475022316,
-0.07255200296640396,
0.015558648854494095,
0.09492013603448868,
0.010585658252239227,
0.03297442942857742,
-0.07073614001274109,
-0.06012984365224838,
-0.009646774269640446,
0.010307088494300842,
-0.03338712453842163,
-0.0034434343688189983,
0.006427743937820196,
-0.008011465892195702,
0.04977116733789444,
-0.025009391829371452,
-0.0316331684589386,
-0.02998238243162632,
0.0006100166356191039,
-0.008124957792460918,
0.061367932707071304,
-0.04882196709513664,
-0.02767128311097622,
0.05439336597919464,
-0.08641859143972397,
0.0636790320277214,
0.042714063078165054,
-0.016146739944815636,
-0.0553838349878788,
-0.02381257340312004,
-0.018344348296523094,
-0.11514225602149963,
0.007944402284920216,
0.0688377320766449,
-0.016683245077729225,
0.005798382218927145,
0.07515198737382889,
0.025793515145778656,
-0.024534791707992554,
0.0048904502764344215,
-0.02377130463719368,
-0.039907727390527725,
-0.035409338772296906,
-0.027031604200601578,
0.00538052711635828,
0.02994111180305481,
0.04226009547710419,
0.02434907853603363,
-0.005622986238449812,
0.012236443348228931,
-0.006675361655652523,
-0.06726948916912079,
0.03433632850646973,
-0.0386696383357048,
-0.056333038955926895,
0.0030281587969511747,
-0.01127692498266697,
-0.030291903764009476,
-0.01812768168747425,
0.01800387352705002,
0.006871392484754324,
0.045066431164741516,
-0.028001440688967705,
0.08282813429832458,
-0.0315299928188324,
-0.04968862608075142,
-0.01813800074160099,
-0.05389812961220741,
0.034233152866363525,
-0.032458558678627014,
0.03576013073325157,
-0.02251257933676243,
-0.022347502410411835,
0.0013161140959709883,
0.043209295719861984,
0.010843593627214432,
-0.04675848409533501,
0.04812038317322731,
0.0076090870425105095,
-0.05488860234618187,
-0.014217386022210121,
0.0023343132343143225,
-0.016569754108786583,
0.01522849127650261,
-0.023317337036132812,
-0.03860773518681526,
0.03677123412489891,
-0.01812768168747425,
-0.00116844626609236,
0.013412628322839737,
-0.016848323866724968,
-0.02096496894955635,
0.011442003771662712,
-0.05550764501094818,
0.016776101663708687,
0.03637917339801788,
-0.014176116324961185,
0.02261575497686863,
0.005063266959041357,
-0.018901487812399864,
0.02719668298959732,
-0.023007815703749657,
0.030972853302955627,
0.020005449652671814,
0.04027915373444557,
0.039268046617507935,
0.03060142695903778,
0.02829032763838768,
0.049977514892816544,
0.08381860703229904,
-0.027485569939017296,
0.011658668518066406,
0.07630753517150879,
0.003435696242377162,
-0.046139441430568695,
-0.031901419162750244,
-0.010023360140621662,
-0.0026167521718889475,
0.043291836977005005,
0.06660917401313782,
-0.0044442228972911835,
-0.022945910692214966,
0.010647563263773918,
-0.014351512305438519,
0.08542812615633011,
0.021037191152572632,
-0.03887598589062691,
-0.07841228693723679,
-0.019035615026950836,
0.014052307233214378,
0.04622197896242142,
-0.012195173650979996,
0.014815795235335827,
0.06008857488632202,
-0.07478056102991104,
-0.043209295719861984,
0.02327606827020645,
-0.0005371499573811889,
0.017415782436728477,
0.011266607791185379,
0.03101412206888199,
0.04911085218191147,
-0.02156337909400463,
0.0642155334353447,
0.04490135237574577,
0.015073730610311031,
-0.012649140320718288,
-0.04486008360981941,
-0.039825186133384705,
0.06487584859132767,
-0.0005687469965778291,
-0.010771372355520725,
-0.04345691576600075,
0.039329953491687775,
-0.00877495389431715,
0.01586817018687725,
0.0018442363943904638,
-0.051793377846479416,
0.013195962645113468,
0.033056970685720444,
0.009136063046753407,
0.0020015768241137266,
0.03963947296142578,
0.002529054181650281,
0.053980667144060135,
0.011668986640870571,
-0.040464866906404495,
-0.030787140130996704,
0.010977719910442829,
-0.005099378060549498,
0.040361691266298294,
0.04015534371137619,
0.002131833927705884,
-0.007433691062033176,
0.03895852714776993,
-0.03970137983560562,
0.027960170060396194,
0.017250703647732735,
-0.03295379504561424,
-0.005819017067551613,
-0.00933725293725729,
-0.04341564327478409,
0.04502515867352486,
0.07432659715414047,
-0.024782409891486168,
-0.021831631660461426,
0.02661890722811222,
-0.02439034730195999,
0.040506135672330856,
-0.021604647859930992,
0.004075375385582447,
-0.017395146191120148,
-0.07341866195201874,
-0.00852217711508274,
0.01985068991780281,
-0.015032460913062096,
-0.01129755936563015,
-0.023049084469676018,
-0.034295059740543365,
0.005452749319374561,
0.006695996504276991,
0.05806636065244675,
0.04180612787604332,
0.039247412234544754,
-0.027547474950551987,
0.029549051076173782
]
|
32,055 | pingouin.datasets | read_dataset | Read example datasets.
Parameters
----------
dname : string
Name of dataset to read (without extension).
Must be a valid dataset present in pingouin.datasets
Returns
-------
data : :py:class:`pandas.DataFrame`
Requested dataset.
Examples
--------
Load the `Penguin <https://github.com/allisonhorst/palmerpenguins>`_
dataset:
>>> import pingouin as pg
>>> df = pg.read_dataset('penguins')
>>> df # doctest: +SKIP
species island bill_length_mm ... flipper_length_mm body_mass_g sex
0 Adelie Biscoe 37.8 ... 174.0 3400.0 female
1 Adelie Biscoe 37.7 ... 180.0 3600.0 male
2 Adelie Biscoe 35.9 ... 189.0 3800.0 female
3 Adelie Biscoe 38.2 ... 185.0 3950.0 male
4 Adelie Biscoe 38.8 ... 180.0 3800.0 male
.. ... ... ... ... ... ... ...
339 Gentoo Biscoe NaN ... NaN NaN NaN
340 Gentoo Biscoe 46.8 ... 215.0 4850.0 female
341 Gentoo Biscoe 50.4 ... 222.0 5750.0 male
342 Gentoo Biscoe 45.2 ... 212.0 5200.0 female
343 Gentoo Biscoe 49.9 ... 213.0 5400.0 male
| def read_dataset(dname):
"""Read example datasets.
Parameters
----------
dname : string
Name of dataset to read (without extension).
Must be a valid dataset present in pingouin.datasets
Returns
-------
data : :py:class:`pandas.DataFrame`
Requested dataset.
Examples
--------
Load the `Penguin <https://github.com/allisonhorst/palmerpenguins>`_
dataset:
>>> import pingouin as pg
>>> df = pg.read_dataset('penguins')
>>> df # doctest: +SKIP
species island bill_length_mm ... flipper_length_mm body_mass_g sex
0 Adelie Biscoe 37.8 ... 174.0 3400.0 female
1 Adelie Biscoe 37.7 ... 180.0 3600.0 male
2 Adelie Biscoe 35.9 ... 189.0 3800.0 female
3 Adelie Biscoe 38.2 ... 185.0 3950.0 male
4 Adelie Biscoe 38.8 ... 180.0 3800.0 male
.. ... ... ... ... ... ... ...
339 Gentoo Biscoe NaN ... NaN NaN NaN
340 Gentoo Biscoe 46.8 ... 215.0 4850.0 female
341 Gentoo Biscoe 50.4 ... 222.0 5750.0 male
342 Gentoo Biscoe 45.2 ... 212.0 5200.0 female
343 Gentoo Biscoe 49.9 ... 213.0 5400.0 male
"""
# Check extension
d, ext = op.splitext(dname)
if ext.lower() == ".csv":
dname = d
# Check that dataset exist
if dname not in dts["dataset"].to_numpy():
raise ValueError(
"Dataset does not exist. Valid datasets names are", dts["dataset"].to_numpy()
)
# Load dataset
return pd.read_csv(op.join(ddir, dname + ".csv"), sep=",")
| (dname) | [
0.004359408747404814,
-0.004893019329756498,
0.03548511117696762,
-0.00005706090814783238,
-0.015617641620337963,
0.036361757665872574,
-0.005374222062528133,
0.01043399516493082,
0.06628207117319107,
-0.010167189873754978,
-0.03519924730062485,
0.0360758937895298,
-0.07154195010662079,
0.06712060421705246,
0.0022202017717063427,
-0.050883591175079346,
0.005021657794713974,
0.10321555286645889,
-0.013092519715428352,
-0.021363485604524612,
-0.015265077352523804,
0.054580751806497574,
0.004421345889568329,
-0.02300243265926838,
-0.06136523187160492,
0.03548511117696762,
0.008680702187120914,
-0.003566139377653599,
0.015007801353931427,
0.03272176906466484,
-0.02816702239215374,
0.000445469660917297,
-0.04661470651626587,
0.03197852522134781,
-0.017866428941488266,
0.004025902133435011,
0.017733026295900345,
0.024298343807458878,
-0.03891546651721001,
0.03603778034448624,
-0.03525642305612564,
-0.05888775363564491,
0.07626821845769882,
-0.01437890250235796,
-0.02408871240913868,
0.007056048605591059,
0.023993423208594322,
-0.08774084597826004,
-0.04310812056064606,
0.0037185996770858765,
0.03929661586880684,
-0.0027681055944412947,
0.023993423208594322,
0.034227315336465836,
-0.01774255558848381,
-0.0400589182972908,
-0.04276508465409279,
0.09117119759321213,
0.0131211057305336,
0.03477998450398445,
-0.0029825025703758,
-0.06052669882774353,
-0.02336452528834343,
-0.02506064623594284,
-0.0455474853515625,
0.03226438909769058,
0.047262661159038544,
-0.046195439994335175,
-0.025079702958464622,
-0.03546605259180069,
-0.017980774864554405,
0.048939723521471024,
0.0006699911318719387,
0.01389293558895588,
0.019067054614424706,
0.010862789116799831,
-0.05705823004245758,
-0.027366606518626213,
-0.030053716152906418,
0.025441795587539673,
0.01989605650305748,
-0.044289689511060715,
0.007051284424960613,
0.012730427086353302,
-0.022049555554986,
-0.026661477982997894,
0.03929661586880684,
0.03382710739970207,
0.06914070248603821,
-0.005207468755543232,
0.04089744761586189,
-0.007141807582229376,
0.04993071407079697,
0.011291583999991417,
0.0036661913618445396,
-0.0382484532892704,
-0.03668573498725891,
0.07455303519964218,
-0.0025203577242791653,
-0.011539331637322903,
-0.009728866629302502,
0.010167189873754978,
0.05214138701558113,
0.03639987111091614,
-0.06296606361865997,
-0.02073458768427372,
0.03922038525342941,
0.017170829698443413,
0.0011619135038927197,
-0.0601455494761467,
-0.12158700823783875,
-0.029081782326102257,
-0.02504158765077591,
0.020467782393097878,
0.019019410014152527,
-0.0023238270077854395,
0.028224194422364235,
0.008561593480408192,
-0.0983368307352066,
0.0002927116584032774,
-0.06064104288816452,
0.1449134200811386,
-0.05919267237186432,
-0.05416148528456688,
0.03874394670128822,
-0.021535003557801247,
0.021668406203389168,
0.0033755640033632517,
-0.0313115119934082,
-0.011958597227931023,
0.04806307703256607,
-0.006570081692188978,
-0.015322250314056873,
0.01871448941528797,
0.022373534739017487,
-0.04303188994526863,
0.11015249788761139,
0.02610880881547928,
0.03296951949596405,
0.0032207216136157513,
0.012415977194905281,
-0.0036209297832101583,
-0.0043498799204826355,
-0.018981294706463814,
0.006617725361138582,
-0.03399862349033356,
0.04974013939499855,
-0.08575886487960815,
-0.03845808655023575,
0.006546259857714176,
0.001298293936997652,
-0.03594249114394188,
-0.015055445022881031,
-0.07501041889190674,
0.028681574389338493,
-0.0462716706097126,
-0.01769491285085678,
-0.05934513360261917,
-0.017685383558273315,
-0.002825278090313077,
0.0273284912109375,
0.033121977001428604,
-0.05008317530155182,
0.07104645669460297,
-0.09406794607639313,
0.025232162326574326,
-0.07512476295232773,
-0.01772349886596203,
0.014216913841664791,
-0.007708768825978041,
0.027156973257660866,
0.069979228079319,
0.0262422114610672,
0.002270227763801813,
0.02397436648607254,
-0.002398865995928645,
-0.01373094692826271,
-0.0005097888060845435,
-0.004228388424962759,
-0.015169790014624596,
-0.02995842881500721,
0.01701837033033371,
-0.0006253250176087022,
0.04352738708257675,
0.005350400228053331,
0.00982415396720171,
0.013302152045071125,
0.001362613053061068,
0.047758158296346664,
-0.0012911473168060184,
0.020925162360072136,
0.01955302059650421,
-0.03512302041053772,
0.027614353224635124,
0.053627874702215195,
-0.088198222219944,
0.02159217558801174,
0.009900384582579136,
0.021172910928726196,
0.001523410901427269,
0.00862353015691042,
0.09315317869186401,
0.061784494668245316,
-0.010500696487724781,
0.008356724865734577,
0.02698545530438423,
-0.06018366292119026,
-0.04470895230770111,
-0.05907832831144333,
-0.01259702444076538,
0.05667708069086075,
-0.047300778329372406,
-0.023288294672966003,
-0.003337449161335826,
0.015360364690423012,
-0.03491338714957237,
0.0010553104802966118,
-0.0016639601672068238,
-0.003485144814476371,
0.02096327766776085,
0.05488567054271698,
-0.01649428717792034,
0.0397539958357811,
0.04455649480223656,
0.0003117691958323121,
-0.010557868517935276,
0.03845808655023575,
0.04013514891266823,
0.027233203873038292,
-0.023783791810274124,
-0.02814796380698681,
-0.013702360913157463,
0.054466407746076584,
-0.09185726940631866,
0.03870583325624466,
0.04040195420384407,
0.025556141510605812,
0.007937459275126457,
0.07020792365074158,
-0.004016373306512833,
-0.01937197335064411,
-0.034799039363861084,
0.03678102418780327,
-0.02182086557149887,
-0.04082121700048447,
-0.05762995406985283,
-0.01930527202785015,
-0.012863829731941223,
-0.03251213580369949,
-0.011958597227931023,
0.007151336409151554,
-0.0030015602242201567,
0.0360758937895298,
0.06052669882774353,
0.02866251766681671,
-0.029672566801309586,
-0.019629251211881638,
-0.04794873297214508,
0.03455129265785217,
-0.040440067648887634,
-0.007561073172837496,
-0.02528933621942997,
0.006408092565834522,
0.0419265553355217,
-0.05949759483337402,
0.0311590526252985,
-0.02923424355685711,
-0.06795913726091385,
0.0503118671476841,
-0.07874569296836853,
0.014397960156202316,
0.12120585888624191,
0.02841476909816265,
-0.06174638122320175,
-0.005822073668241501,
0.04432780295610428,
0.0323977917432785,
-0.008866513147950172,
-0.002068932633846998,
0.03464658185839653,
-0.02780492976307869,
-0.023326409980654716,
-0.005412336904555559,
-0.03154020383954048,
-0.019019410014152527,
-0.03899169713258743,
-0.053170494735240936,
0.03941095992922783,
-0.04878726229071617,
-0.008604472503066063,
0.0017949806060642004,
-0.03619024157524109,
-0.02506064623594284,
-0.0006646311958320439,
-0.07748789340257645,
-0.006898824125528336,
-0.03742897883057594,
-0.038172222673892975,
0.0297106821089983,
0.0018485799664631486,
-0.029920313507318497,
-0.028548171743750572,
0.024298343807458878,
0.02553708292543888,
-0.04040195420384407,
0.0029729739762842655,
-0.03237873315811157,
-0.09162858128547668,
-0.06269925832748413,
-0.01887647807598114,
0.03645704686641693,
0.014550420455634594,
0.005588619038462639,
-0.006355684716254473,
-0.019333859905600548,
-0.024831954389810562,
-0.0007640876574441791,
0.014664765447378159,
0.020315321162343025,
-0.027728699147701263,
0.004316529259085655,
-0.02239259146153927,
0.012387391179800034,
-0.013149692676961422,
-0.0031373449601233006,
0.07935553044080734,
0.022468822076916695,
0.030015602707862854,
0.014407488517463207,
0.00988132692873478,
0.05286557599902153,
-0.024870069697499275,
0.02479383908212185,
-0.02239259146153927,
0.04589052125811577,
-0.018552500754594803,
0.03731463477015495,
-0.0180379468947649,
0.06323286890983582,
0.03066355735063553,
0.03186418116092682,
-0.030034659430384636,
-0.006708248984068632,
-0.04097367823123932,
0.05671519413590431,
-0.0035161133855581284,
0.028262309730052948,
-0.03727651759982109,
0.04196466878056526,
0.06902635842561722,
0.028109848499298096,
0.038534317165613174,
-0.04737700894474983,
0.028090791776776314,
0.0353517085313797,
0.023783791810274124,
-0.026451844722032547,
-0.002808602759614587,
-0.009223842062056065,
0.003485144814476371,
-0.01360707264393568,
-0.053742218762636185,
0.07443869113922119,
0.0009099968010559678,
-0.010148132219910622,
-0.0213253702968359,
0.019857941195368767,
-0.021954268217086792,
-0.012577966786921024,
0.02946293354034424,
-0.0073037962429225445,
0.03952530771493912,
-0.011644147336483002,
-0.0026537603698670864,
-0.023288294672966003,
-0.05347541347146034,
-0.0059507121331989765,
-0.030263349413871765,
0.017685383558273315,
0.07676371186971664,
-0.03190229833126068,
-0.009061853401362896,
0.024050597101449966,
0.0068130651488900185,
0.014826754108071327,
-0.0462716706097126,
-0.04242205247282982,
0.029272358864545822,
-0.05023563653230667,
-0.025613313540816307,
0.023345468565821648,
-0.011167709715664387,
0.07527722418308258,
0.023402640596032143,
-0.053284838795661926,
-0.04768192768096924,
-0.07626821845769882,
-0.04832988232374191,
0.0013673774665221572,
0.006822593975812197,
-0.04070687294006348,
-0.0007360968738794327,
-0.0075515443459153175,
0.02793833240866661,
-0.051226627081632614,
0.045013874769210815,
0.02982502616941929,
-0.03750520944595337,
-0.04364173114299774,
-0.022716570645570755,
0.05965005233883858,
0.06025989353656769,
0.016875438392162323,
0.033865220844745636,
0.038896407932043076,
0.032550252974033356,
0.015970205888152122,
-0.009967085905373096,
0.05671519413590431,
0.0718468725681305,
0.012720897793769836,
-0.053742218762636185,
-0.0426507405936718,
0.03598060831427574,
0.026051636785268784,
0.03150209039449692,
-0.03256931155920029,
0.011291583999991417,
-0.005121709778904915,
-0.01144404336810112,
-0.057934876531362534,
-0.003373181913048029,
-0.0280526764690876,
-0.08217604458332062,
0.03081601858139038,
-0.025842003524303436,
-0.034208256751298904,
-0.003720981767401099,
0.04939710348844528,
0.0025417974684387445,
0.047758158296346664,
-0.0006443825550377369,
0.02504158765077591,
-0.06590092182159424,
-0.06715872138738632,
0.0033040984999388456,
0.006236575078219175,
0.053513530641794205,
-0.01360707264393568,
-0.045585598796606064,
0.035904377698898315,
-0.005055008456110954,
0.03750520944595337,
-0.06670133769512177,
0.00526940543204546,
-0.0061127012595534325,
0.024355517700314522,
0.013511785306036472,
-0.028319481760263443,
-0.0004722692829091102,
0.013130635023117065,
0.004156922455877066,
0.06502427160739899,
-0.014064453542232513,
0.018218994140625,
0.021649347618222237,
0.04939710348844528,
-0.039487190544605255,
0.03382710739970207,
-0.05080736055970192,
0.006217517424374819,
-0.022811857983469963,
-0.010395879857242107,
-0.02588011883199215,
0.03102564997971058,
-0.0043951417319476604,
-0.010214833542704582,
0.05042621120810509,
0.010586455464363098,
0.01976265385746956,
0.0005315262824296951,
-0.04246016591787338,
0.04124048352241516,
0.04802496358752251,
0.012673254124820232,
-0.02887215092778206,
-0.02143971621990204,
0.010129074566066265,
0.004533308558166027,
-0.057096343487501144,
-0.006884531117975712,
0.038534317165613174,
0.02637561410665512,
-0.013864349573850632,
0.020429667085409164,
0.05118851363658905,
0.045966751873493195,
0.013568957336246967,
0.009452532045543194,
-0.0156843438744545,
0.03455129265785217,
-0.033484071493148804,
-0.05069301649928093,
-0.021878039464354515,
-0.013759532943367958,
0.039601538330316544,
0.062279991805553436,
-0.009571641683578491,
0.01697072573006153,
-0.05553362891077995,
-0.02982502616941929,
0.01826663687825203,
0.01474099513143301,
-0.00602217810228467,
-0.010586455464363098,
0.013073462061583996,
-0.0433749258518219,
0.08362442255020142,
-0.04085933417081833,
0.051836468279361725,
0.020791759714484215,
-0.00659390352666378,
0.026642419397830963,
0.08392933756113052,
-0.042726971209049225,
-0.003932996653020382,
0.019209984689950943,
0.0015162642812356353,
-0.03634269908070564,
0.05019751936197281,
-0.052065160125494,
-0.03678102418780327,
0.03569474443793297,
0.001632991712540388,
0.015789158642292023,
-0.012901944108307362,
-0.04066875949501991,
0.0068368869833648205,
0.018752604722976685,
0.037676725536584854,
-0.00598882744088769,
0.02361227385699749,
0.026318442076444626,
-0.006431914865970612,
0.015569997951388359,
-0.014779110439121723,
-0.04425157234072685,
0.04082121700048447,
0.0867498517036438,
0.04348927363753319,
0.008823634125292301,
-0.053056150674819946,
-0.003983022645115852,
-0.007665889337658882,
0.06140334531664848,
-0.030758844688534737,
-0.019448203966021538,
0.03845808655023575,
-0.03514207527041435,
-0.012844772078096867,
0.01246362179517746,
-0.039830226451158524,
0.028605345636606216,
0.002074887976050377,
0.021249139681458473,
0.008571121841669083,
0.006927410140633583,
0.011491687968373299,
-0.03538982570171356,
-0.08697854727506638,
0.01978171057999134,
0.03283611685037613,
0.06208941712975502,
0.03148303180932999,
-0.020829875022172928,
0.031235283240675926,
-0.04268885776400566,
-0.015941619873046875,
0.006674898322671652,
0.00497401412576437,
-0.03821033611893654,
0.047300778329372406,
-0.021668406203389168,
0.03626646846532822,
-0.06430009007453918,
0.03813410922884941,
-0.0238600205630064,
0.018838362768292427,
0.015179318375885487,
0.005650556180626154,
-0.010500696487724781,
-0.03914415463805199,
-0.003937761299312115,
0.04082121700048447,
0.006012649275362492,
-0.0028848329093307257,
-0.00722280191257596,
-0.041888438165187836,
0.07699239999055862,
-0.006312805227935314,
-0.025613313540816307,
-0.03796258941292763,
-0.034208256751298904,
-0.04070687294006348,
-0.013835763558745384,
-0.024412689730525017,
0.004566659219563007,
-0.03714311495423317,
-0.006565317511558533,
-0.009447768330574036,
-0.002143971621990204,
0.029901256784796715,
-0.01828569546341896,
-0.013492727652192116,
0.004771527834236622,
-0.02492724359035492,
0.0003355911176186055,
-0.0586971752345562,
-0.0021618378814309835,
-0.05884963646531105,
0.033026691526174545,
-0.053742218762636185,
0.06098407879471779,
-0.044175341725349426,
-0.06464312225580215,
-0.04711019992828369,
0.01619889587163925,
-0.014417017810046673,
-0.024183999747037888,
-0.03657139092683792,
-0.005526682361960411,
-0.001802127226255834,
0.02612786740064621,
-0.008342431858181953,
0.025079702958464622,
-0.006065057124942541,
0.011282054707407951,
0.005193175747990608,
-0.025098759680986404,
-0.012063412927091122,
0.02877686358988285,
-0.03331255540251732,
0.008685466833412647,
0.010424465872347355,
0.00263470271602273,
-0.049092184752225876,
-0.0007497944752685726,
-0.016818266361951828,
0.016322769224643707,
-0.042002785950899124,
0.037810128182172775,
0.0331791527569294,
-0.027004512026906013,
0.039487190544605255,
0.032778944820165634,
0.015693871304392815,
0.019838882610201836,
0.03045392408967018,
0.004766763653606176,
-0.03474186733365059,
0.01718035899102688,
-0.028834035620093346,
0.03725746273994446,
0.04028760641813278,
0.06548165529966354,
-0.0131211057305336,
0.011158180423080921,
-0.020067574456334114,
-0.009724101983010769,
0.015617641620337963,
-0.016551461070775986,
0.05717257410287857,
-0.008104212582111359,
-0.062394335865974426,
0.06372836232185364,
-0.06875955313444138,
-0.04470895230770111,
-0.025842003524303436,
-0.027519065886735916,
0.035408880561590195,
-0.010986663401126862,
0.053627874702215195,
0.044060997664928436,
-0.012168229557573795,
0.054123371839523315,
0.00946206133812666,
0.04825365170836449,
-0.06487181782722473,
0.021001392975449562,
0.027614353224635124,
0.02528933621942997,
0.0130162900313735,
0.02528933621942997,
0.04383230581879616,
-0.03899169713258743,
-0.006908352952450514,
-0.020200977101922035,
0.0034637050703167915,
-0.08652116358280182,
0.04478518292307854,
-0.01930527202785015,
0.001086874515749514,
0.026909224689006805,
0.04638601467013359,
0.020067574456334114,
0.0008814105531200767,
-0.0020701235625892878,
0.04749135300517082,
-0.005493331700563431,
-0.011787079274654388,
0.010824673809111118,
0.0022678454406559467,
0.016484759747982025,
0.012454092502593994,
0.067806676030159,
-0.043451156467199326,
-0.05389467999339104,
0.027423778548836708,
-0.03235967829823494,
-0.006794007495045662,
0.06856897473335266,
0.017551980912685394,
0.01619889587163925,
0.03611401095986366,
-0.019915113225579262,
-0.015760572627186775,
-0.03018711879849434,
-0.010205304250121117,
0.01756151020526886,
0.013340267352759838,
-0.02757623791694641,
0.047300778329372406,
-0.02900555357336998,
-0.02778587117791176,
-0.028071735054254532,
-0.020467782393097878,
0.017046956345438957,
0.0036471339408308268,
0.008966565132141113,
-0.015569997951388359,
-0.06296606361865997,
-0.030739787966012955,
-0.004397524055093527,
-0.010910432785749435,
0.031101880595088005,
-0.01851438544690609,
0.056753307580947876,
0.011453572660684586,
0.01437890250235796,
0.016961196437478065,
0.014969686046242714,
-0.01624654047191143,
-0.039029810577631,
-0.008675938472151756,
-0.02791927382349968,
-0.024012481793761253,
0.020448723807930946,
-0.001628227299079299,
0.010233891196548939,
-0.028471942991018295,
-0.02243070676922798,
0.05743937939405441,
0.022792799398303032,
0.003973493818193674,
-0.023764733225107193,
0.017389992251992226,
0.021134795621037483,
0.012911473400890827
]
|
32,058 | pingouin.utils | remove_na | Remove missing values along a given axis in one or more (paired) numpy arrays.
Parameters
----------
x, y : 1D or 2D arrays
Data. ``x`` and ``y`` must have the same number of dimensions.
``y`` can be None to only remove missing values in ``x``.
paired : bool
Indicates if the measurements are paired or not.
axis : str
Axis or axes along which missing values are removed.
Can be 'rows' or 'columns'. This has no effect if ``x`` and ``y`` are
one-dimensional arrays.
Returns
-------
x, y : np.ndarray
Data without missing values
Examples
--------
Single 1D array
>>> import numpy as np
>>> from pingouin import remove_na
>>> x = [6.4, 3.2, 4.5, np.nan]
>>> remove_na(x)
array([6.4, 3.2, 4.5])
With two paired 1D arrays
>>> y = [2.3, np.nan, 5.2, 4.6]
>>> remove_na(x, y, paired=True)
(array([6.4, 4.5]), array([2.3, 5.2]))
With two independent 2D arrays
>>> x = np.array([[4, 2], [4, np.nan], [7, 6]])
>>> y = np.array([[6, np.nan], [3, 2], [2, 2]])
>>> x_no_nan, y_no_nan = remove_na(x, y, paired=False)
| def remove_na(x, y=None, paired=False, axis="rows"):
"""Remove missing values along a given axis in one or more (paired) numpy arrays.
Parameters
----------
x, y : 1D or 2D arrays
Data. ``x`` and ``y`` must have the same number of dimensions.
``y`` can be None to only remove missing values in ``x``.
paired : bool
Indicates if the measurements are paired or not.
axis : str
Axis or axes along which missing values are removed.
Can be 'rows' or 'columns'. This has no effect if ``x`` and ``y`` are
one-dimensional arrays.
Returns
-------
x, y : np.ndarray
Data without missing values
Examples
--------
Single 1D array
>>> import numpy as np
>>> from pingouin import remove_na
>>> x = [6.4, 3.2, 4.5, np.nan]
>>> remove_na(x)
array([6.4, 3.2, 4.5])
With two paired 1D arrays
>>> y = [2.3, np.nan, 5.2, 4.6]
>>> remove_na(x, y, paired=True)
(array([6.4, 4.5]), array([2.3, 5.2]))
With two independent 2D arrays
>>> x = np.array([[4, 2], [4, np.nan], [7, 6]])
>>> y = np.array([[6, np.nan], [3, 2], [2, 2]])
>>> x_no_nan, y_no_nan = remove_na(x, y, paired=False)
"""
# Safety checks
x = np.asarray(x)
assert axis in ["rows", "columns"], "axis must be rows or columns."
if y is None:
return _remove_na_single(x, axis=axis)
elif isinstance(y, (int, float, str)):
return _remove_na_single(x, axis=axis), y
else: # y is list, np.array, pd.Series
y = np.asarray(y)
assert y.size != 0, "y cannot be an empty list or array."
# Make sure that we just pass-through if y have only 1 element
if y.size == 1:
return _remove_na_single(x, axis=axis), y
if x.ndim != y.ndim or paired is False:
# x and y do not have the same dimension
x_no_nan = _remove_na_single(x, axis=axis)
y_no_nan = _remove_na_single(y, axis=axis)
return x_no_nan, y_no_nan
# At this point, we assume that x and y are paired and have same dimensions
if x.ndim == 1:
# 1D arrays
x_mask = ~np.isnan(x)
y_mask = ~np.isnan(y)
else:
# 2D arrays
ax = 1 if axis == "rows" else 0
x_mask = ~np.any(np.isnan(x), axis=ax)
y_mask = ~np.any(np.isnan(y), axis=ax)
# Check if missing values are present
if ~x_mask.all() or ~y_mask.all():
ax = 0 if axis == "rows" else 1
ax = 0 if x.ndim == 1 else ax
both = np.logical_and(x_mask, y_mask)
x = x.compress(both, axis=ax)
y = y.compress(both, axis=ax)
return x, y
| (x, y=None, paired=False, axis='rows') | [
-0.027911514043807983,
0.03300805389881134,
0.006355742458254099,
0.03280896693468094,
-0.00446693692356348,
-0.05092557147145271,
-0.07238677889108658,
0.07067465782165527,
0.10033810883760452,
-0.0023218118585646152,
0.0042404793202877045,
-0.028030963614583015,
0.02297424152493477,
0.007500472478568554,
0.030459782108664513,
0.014642595313489437,
-0.038443032652139664,
0.07202842831611633,
0.02104313112795353,
-0.024586817249655724,
0.029325006529688835,
0.009476376697421074,
-0.031355660408735275,
0.07979268580675125,
-0.0230936910957098,
0.009068255312740803,
0.01984862983226776,
-0.0038099614903330803,
-0.029902348294854164,
0.04825785011053085,
0.07696569710969925,
-0.031096849590539932,
-0.016185492277145386,
-0.0019622172694653273,
0.012681622058153152,
-0.011636433191597462,
0.017539260908961296,
0.04933290183544159,
-0.07728423178195953,
0.01639452949166298,
-0.036631371825933456,
-0.05845092982053757,
0.053075674921274185,
-0.014612732455134392,
0.03223162516951561,
0.021381573751568794,
0.012661713175475597,
0.012592034414410591,
-0.08046957105398178,
0.07342201471328735,
0.052319157868623734,
0.021899189800024033,
0.018873119726777077,
0.07063484191894531,
-0.0082121966406703,
0.07827965170145035,
-0.011078999377787113,
0.022715432569384575,
0.001652393490076065,
-0.04168809577822685,
0.014801861718297005,
0.009152865968644619,
0.03565586358308792,
0.010013902559876442,
0.0019634615164250135,
0.014483327977359295,
-0.024646542966365814,
-0.04682445153594017,
-0.03816431760787964,
0.009496285580098629,
-0.03145520016551018,
0.032012633979320526,
-0.0029812760185450315,
-0.00673897797241807,
0.04606793448328972,
0.03348585218191147,
0.041130661964416504,
0.03637256473302841,
0.0037278393283486366,
-0.04702353477478027,
-0.006475192494690418,
0.033147409558296204,
-0.021919097751379013,
0.0314352922141552,
0.020804230123758316,
0.043161313980817795,
-0.012054508551955223,
0.07577119767665863,
0.04479379951953888,
-0.019002525135874748,
-0.01836545765399933,
-0.006380627863109112,
0.010302573442459106,
0.0316343754529953,
-0.001955995801836252,
0.04933290183544159,
-0.011636433191597462,
-0.006883313413709402,
-0.003230130532756448,
-0.049094002693891525,
0.013079789467155933,
-0.04801895096898079,
-0.017509397119283676,
0.027931421995162964,
0.021401481702923775,
-0.016862375661730766,
0.0027597956359386444,
0.004698371514678001,
-0.022874699905514717,
0.0459882989525795,
-0.00444454001262784,
-0.047142982482910156,
-0.00792352482676506,
-0.018285823985934258,
0.0063507650047540665,
-0.03796523064374924,
-0.07382018119096756,
0.0553850419819355,
-0.06816620379686356,
-0.05458870902657509,
-0.03637256473302841,
0.04359929636120796,
-0.05319512262940407,
-0.018176328390836716,
0.02900647185742855,
-0.06776803731918335,
0.07604991644620895,
0.034620627760887146,
-0.03681054711341858,
0.03489934653043747,
-0.043081678450107574,
-0.0054001412354409695,
-0.024626635015010834,
0.018036969006061554,
-0.022615890949964523,
-0.018246006220579147,
0.010332436300814152,
-0.0015876912511885166,
0.030818132683634758,
-0.037228621542453766,
0.010740557685494423,
-0.003581015393137932,
0.021978823468089104,
0.031893182545900345,
0.023551583290100098,
0.00992431491613388,
0.050487589091062546,
-0.01646420918405056,
0.04300204664468765,
0.0023952238261699677,
-0.047103166580200195,
0.0044793798588216305,
0.05478779226541519,
-0.04013524204492569,
-0.004073746968060732,
0.011069045402109623,
0.005425026640295982,
0.00046504673082381487,
-0.03175382688641548,
0.004563990514725447,
-0.02974308282136917,
-0.0092225456610322,
0.010869961231946945,
-0.012990201823413372,
-0.0073760454542934895,
-0.0085406843572855,
0.01640448346734047,
-0.005798308178782463,
0.019360875710844994,
0.009486330673098564,
-0.011417441070079803,
-0.001775576383806765,
-0.02703554555773735,
-0.08433178812265396,
-0.021560749039053917,
-0.006599619518965483,
-0.014791907742619514,
-0.04690408334136009,
0.026836462318897247,
0.04789949953556061,
0.010780374519526958,
-0.0001667324686422944,
-0.028090689331293106,
-0.03700963035225868,
-0.011367670260369778,
0.04475397989153862,
0.0046112728305161,
-0.062193699181079865,
-0.00043549525435082614,
0.004573944490402937,
0.022834882140159607,
0.016802651807665825,
-0.0475013330578804,
0.10543464869260788,
0.04144919291138649,
0.01652393490076065,
0.03483961895108223,
0.0370892658829689,
0.03167419135570526,
-0.030778316780924797,
0.024069201201200485,
-0.04654573276638985,
0.02050560526549816,
0.05084593966603279,
-0.01639452949166298,
-0.026896188035607338,
-0.03904028236865997,
0.010700740851461887,
-0.04738188534975052,
0.02500489354133606,
0.09157843142747879,
-0.0157176461070776,
0.006763863377273083,
-0.04363911226391792,
0.027473529800772667,
0.07123209536075592,
0.03344603627920151,
0.0025457809679210186,
0.01722072623670101,
-0.010093536227941513,
-0.019380783662199974,
-0.06151681765913963,
0.0022931937128305435,
0.04101121053099632,
0.036691099405288696,
0.0029912302270531654,
0.010989411734044552,
0.000601605570409447,
0.029185647144913673,
-0.06967923790216446,
0.031395476311445236,
-0.03641238063573837,
-0.012681622058153152,
-0.01897266134619713,
0.029424548149108887,
-0.0790361687541008,
0.04674481600522995,
-0.05586284399032593,
0.024487275630235672,
-0.023571491241455078,
-0.02233717404305935,
-0.008739767596125603,
-0.01573755405843258,
-0.011427395977079868,
0.02106303907930851,
-0.026498019695281982,
0.02444745972752571,
0.03635265678167343,
0.035854946821928024,
-0.02367103286087513,
0.018574494868516922,
0.023471949622035027,
0.0343618206679821,
0.008744744583964348,
0.03687027469277382,
-0.044475264847278595,
-0.008635248988866806,
-0.0024997428990900517,
0.039796799421310425,
-0.02040606364607811,
0.047660600394010544,
-0.04240479692816734,
-0.03217190131545067,
-0.006281085778027773,
-0.005838125012814999,
0.01576741598546505,
0.015269707888364792,
0.0082121966406703,
0.047780051827430725,
0.014702320098876953,
-0.039796799421310425,
0.028787480667233467,
-0.018932845443487167,
-0.026756828650832176,
0.0177383441478014,
0.06844492256641388,
0.02170010656118393,
-0.03161446750164032,
0.07163026183843613,
-0.04001579433679581,
0.0025134298484772444,
-0.054349809885025024,
0.005569362081587315,
0.01055142842233181,
0.012572125531733036,
-0.039299093186855316,
-0.006430398672819138,
-0.04547068104147911,
0.0005736094899475574,
0.041130661964416504,
0.00758508313447237,
0.03306777775287628,
-0.044355813413858414,
-0.00577342277392745,
-0.03543687239289284,
0.03372475132346153,
-0.11116825044155121,
0.012084371410310268,
0.02293442375957966,
-0.036691099405288696,
-0.01577737182378769,
0.027453621849417686,
-0.002341720275580883,
0.020744506269693375,
0.04101121053099632,
-0.05263768881559372,
0.011427395977079868,
-0.005350370425730944,
0.0031828482169657946,
0.0367906391620636,
-0.012134142220020294,
-0.04754115268588066,
-0.0007266549509949982,
-0.04220571368932724,
0.010023856535553932,
0.011805654503405094,
0.04280296340584755,
0.0670115202665329,
0.03758697211742401,
0.040453776717185974,
0.04805876687169075,
-0.06123809888958931,
-0.058291662484407425,
0.04268351197242737,
-0.013965710997581482,
0.0687236413359642,
-0.03296823427081108,
0.026896188035607338,
-0.028150413185358047,
0.08504848927259445,
0.02568177692592144,
0.03356548771262169,
-0.030857950448989868,
0.03147510811686516,
0.04479379951953888,
-0.044395629316568375,
-0.021560749039053917,
-0.06207425147294998,
0.06816620379686356,
0.014164794236421585,
-0.06864400953054428,
-0.022078365087509155,
-0.02836940623819828,
-0.07784166932106018,
0.05323494225740433,
0.014393740333616734,
-0.035835038870573044,
-0.01050165668129921,
0.03826385736465454,
0.0397171676158905,
0.043838195502758026,
0.07147099077701569,
-0.01774829812347889,
0.03489934653043747,
-0.011954966932535172,
0.03227144479751587,
-0.04499288275837898,
0.03155474364757538,
0.03410300984978676,
0.04132974520325661,
-0.053792376071214676,
0.05016905441880226,
0.04531141370534897,
0.016842467710375786,
0.05391182377934456,
0.004947226028889418,
-0.029145831242203712,
0.00789366289973259,
-0.10607171058654785,
-0.013249009847640991,
-0.039896342903375626,
-0.02572159469127655,
-0.03683045506477356,
-0.015010899864137173,
-0.0262790285050869,
0.011676250025629997,
0.024726176634430885,
-0.02373075857758522,
-0.005813239607959986,
-0.041051026433706284,
-0.02181955613195896,
-0.02639847807586193,
-0.029822714626789093,
0.013527726754546165,
-0.019579866901040077,
0.017280451953411102,
-0.0204657893627882,
-0.00545488903298974,
-0.053672924637794495,
-0.020187072455883026,
-0.0026876279152929783,
-0.07163026183843613,
0.026099853217601776,
-0.01774829812347889,
-0.04853656888008118,
-0.036452196538448334,
-0.02040606364607811,
0.047780051827430725,
-0.04463453218340874,
-0.02227744832634926,
0.012462629936635494,
-0.055623944848775864,
0.023372408002614975,
0.004723256919533014,
0.003031047061085701,
0.025223884731531143,
0.006997786462306976,
-0.042524244636297226,
-0.005385209806263447,
0.047142982482910156,
0.01251240074634552,
0.045152150094509125,
0.03499888628721237,
-0.02179964818060398,
0.03884119912981987,
0.056937895715236664,
-0.03683045506477356,
-0.005693789571523666,
0.03818422555923462,
0.03101721592247486,
0.024845626205205917,
-0.09110063314437866,
-0.043838195502758026,
0.01904234103858471,
-0.014413649216294289,
-0.05598229169845581,
0.0066195279359817505,
-0.0000061095706769265234,
-0.0019024921348318458,
0.033864110708236694,
0.02625912055373192,
-0.021421389654278755,
-0.024626635015010834,
-0.05347384139895439,
-0.024785902351140976,
0.028727754950523376,
0.007480564061552286,
-0.013856214471161366,
-0.0008877881919033825,
0.005141332745552063,
-0.048417117446660995,
0.01380644366145134,
0.00951619353145361,
-0.02629893645644188,
-0.07465633004903793,
0.022556165233254433,
-0.022615890949964523,
-0.012213775888085365,
-0.04602811485528946,
0.014503235928714275,
0.007744350004941225,
-0.032649703323841095,
0.050368137657642365,
-0.039139825850725174,
0.004063792992383242,
-0.07979268580675125,
-0.01901247911155224,
-0.04917363449931145,
-0.026677194982767105,
-0.009227522648870945,
0.00027016259264200926,
-0.003767656162381172,
-0.016573704779148102,
-0.021481115370988846,
-0.03493916243314743,
0.057574961334466934,
0.014373832382261753,
-0.05673881247639656,
-0.039139825850725174,
0.0091976597905159,
0.004544082097709179,
-0.026219302788376808,
-0.04296223074197769,
0.021919097751379013,
-0.007485541515052319,
0.029325006529688835,
-0.012293408624827862,
0.03904028236865997,
0.010431977920234203,
-0.013298780657351017,
-0.07935470342636108,
0.022157998755574226,
-0.014911357313394547,
0.024706268683075905,
0.01969931647181511,
-0.015249799937009811,
-0.0041807545349001884,
-0.0420464463531971,
0.046466100960969925,
-0.005648995749652386,
0.029862532392144203,
-0.00926236156374216,
-0.019480325281620026,
-0.03637256473302841,
-0.025422969833016396,
-0.004081212915480137,
-0.013398322276771069,
-0.031893182545900345,
0.0904635637998581,
0.01919165439903736,
0.018763624131679535,
-0.027274446561932564,
0.008630272001028061,
-0.02381039224565029,
0.05136355385184288,
-0.03280896693468094,
-0.02960372343659401,
0.024905351921916008,
-0.06430398672819138,
-0.0003059354203287512,
-0.0649808719754219,
0.008804470300674438,
0.01648411713540554,
-0.007719464600086212,
0.036551740020513535,
0.012761255726218224,
-0.011029228568077087,
-0.021381573751568794,
0.02183946594595909,
-0.021421389654278755,
-0.0073212976567447186,
0.013000155799090862,
0.02438773401081562,
0.09818800538778305,
-0.013726810924708843,
0.03768651559948921,
0.004924829117953777,
-0.024009475484490395,
-0.05646009370684624,
-0.03762679174542427,
-0.035874854773283005,
-0.033286768943071365,
-0.03243070840835571,
-0.013209193013608456,
-0.02299414947628975,
0.0027597956359386444,
-0.022675616666674614,
-0.0177383441478014,
0.08457069098949432,
0.03157465159893036,
0.03965744376182556,
0.026717012748122215,
-0.00010405226203147322,
0.03617348149418831,
-0.04208626225590706,
-0.016683200374245644,
-0.06004359945654869,
0.05988433212041855,
-0.004417166113853455,
0.06370673328638077,
-0.037248533219099045,
-0.0687236413359642,
0.07385999709367752,
-0.006385604850947857,
-0.02436782605946064,
-0.031236208975315094,
-0.011576708406209946,
0.05192098766565323,
-0.026478111743927002,
0.023392315953969955,
-0.013746718876063824,
-0.03563595563173294,
0.011576708406209946,
-0.041090842336416245,
-0.03633274883031845,
0.02500489354133606,
0.02828977257013321,
-0.020167162641882896,
0.016215354204177856,
0.019331011921167374,
-0.044475264847278595,
0.06772822141647339,
-0.0473022498190403,
0.01313951425254345,
-0.011059091426432133,
0.0739794448018074,
0.025343336164951324,
-0.03561604768037796,
-0.08871162682771683,
-0.076607346534729,
0.0026527883019298315,
-0.020157208666205406,
0.03161446750164032,
-0.05004960298538208,
-0.021421389654278755,
-0.02906619757413864,
-0.10001957416534424,
-0.012562171556055546,
0.006380627863109112,
0.04945235326886177,
0.02767261303961277,
0.007833937183022499,
-0.0009493796387687325,
0.0022720410488545895,
0.029942166060209274,
0.052319157868623734,
-0.009297201409935951,
-0.03221171721816063,
0.05789349600672722,
-0.03742770850658417,
0.01835550367832184,
-0.0046436237171292305,
0.031216301023960114,
-0.027135087177157402,
0.0072466409765183926,
-0.013945802114903927,
-0.06784766912460327,
-0.08385398983955383,
-0.02767261303961277,
-0.04495306313037872,
-0.019331011921167374,
0.03894074261188507,
0.0019584842957556248,
-0.04821803420782089,
0.03167419135570526,
0.04427618160843849,
-0.009531124494969845,
0.016942009329795837,
-0.01651398092508316,
0.0039294115267694,
0.00856059230864048,
-0.04200662672519684,
-0.0044121891260147095,
-0.001590179861523211,
0.033187225461006165,
-0.0024835672229528427,
-0.00013243721332401037,
0.02168019860982895,
-0.014612732455134392,
0.04989033564925194,
-0.005041790660470724,
-0.018992571160197258,
0.05056722089648247,
0.005693789571523666,
-0.0017009200528264046,
-0.027792062610387802,
0.020664872601628304,
-0.011337808333337307,
-0.04698371887207031,
0.06637445092201233,
-0.003959273919463158,
-0.0282499548047781,
0.050407953560352325,
0.02910601533949375,
0.02438773401081562,
-0.07437761127948761,
-0.014433557167649269,
0.010959548875689507,
0.024049293249845505,
-0.012243637815117836,
-0.008485936559736729,
-0.01718091033399105,
-0.024566909298300743,
-0.06131773069500923,
0.013826352544128895,
-0.0022197815123945475,
-0.02502480149269104,
0.044355813413858414,
-0.029145831242203712,
-0.008162425830960274,
0.04085194319486618,
0.02691609598696232,
-0.005340415984392166,
0.03758697211742401,
0.05665917694568634,
0.035874854773283005,
0.0007726930198259652,
-0.007286457810550928,
0.06987832486629486,
0.04491324722766876,
0.016075996682047844,
0.07103300839662552,
-0.004215593915432692,
0.022894607856869698,
0.014981037005782127,
-0.07019685953855515,
-0.008510821498930454,
-0.002607994480058551,
-0.07202842831611633,
0.03935881704092026,
0.01716100238263607,
-0.014413649216294289,
0.01584704965353012,
0.023531675338745117,
-0.013358506374061108,
-0.0490143708884716,
0.062313150614500046,
-0.04292241111397743,
0.01917174644768238,
0.0015777371590957046,
0.018076786771416664,
-0.01486158650368452,
0.061715900897979736,
-0.02767261303961277,
-0.014324061572551727,
-0.04332058131694794,
-0.005375255830585957,
-0.01312956027686596,
0.05474797636270523,
-0.027831880375742912,
0.026896188035607338,
0.010058696381747723,
-0.04363911226391792,
0.01855458691716194,
0.022735340520739555,
0.044475264847278595,
-0.008426210843026638,
0.02245662361383438,
0.024586817249655724,
-0.031196391209959984,
-0.08799492567777634,
0.017957335337996483,
0.017280451953411102,
0.002346697263419628,
-0.0098795210942626,
0.016812605783343315,
-0.015040761791169643,
-0.04917363449931145,
0.03828376531600952,
0.06482160091400146,
0.0021700107026845217,
0.046426281332969666,
-0.030439874157309532,
-0.025462785735726357,
-0.04527159780263901,
0.04419654607772827,
0.015697738155722618,
-0.06752914190292358,
-0.014393740333616734,
0.016026224941015244,
0.031236208975315094,
0.0779213011264801,
0.03430209681391716,
0.10941632091999054,
-0.010660924017429352,
-0.04395764693617821,
0.04023478552699089,
-0.029862532392144203,
0.026040127500891685,
-0.02299414947628975,
-0.04403727874159813,
-0.045789215713739395,
0.05514614284038544,
-0.013258963823318481,
0.04455489665269852,
0.04933290183544159,
-0.004193197004497051,
-0.005708720535039902,
-0.03742770850658417,
-0.005375255830585957,
0.04272332787513733,
-0.007152076344937086,
-0.03794532269239426,
0.00038852397119626403,
0.00048744361265562475,
0.0026677194982767105,
0.0010775397531688213,
-0.02711517922580242,
-0.005962552037090063,
-0.009610758163034916,
-0.02106303907930851,
0.039816711097955704,
0.02703554555773735,
0.036472104489803314,
-0.02166029065847397,
0.04125010967254639,
-0.01050165668129921,
0.06115846708416939
]
|
32,059 | pingouin.parametric | rm_anova | One-way and two-way repeated measures ANOVA.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a
:py:class:`pandas.DataFrame` method, in which case this argument is no
longer needed.
Both wide and long-format dataframe are supported for one-way repeated
measures ANOVA. However, ``data`` must be in long format for two-way
repeated measures.
dv : string
Name of column containing the dependent variable (only required if
``data`` is in long format).
within : string or list of string
Name of column containing the within factor (only required if ``data``
is in long format).
If ``within`` is a single string, then compute a one-way repeated
measures ANOVA, if ``within`` is a list with two strings,
compute a two-way repeated measures ANOVA.
subject : string
Name of column containing the subject identifier (only required if
``data`` is in long format).
correction : string or boolean
If True, also return the Greenhouse-Geisser corrected p-value.
The default for one-way design is to compute Mauchly's test of
sphericity to determine whether the p-values needs to be corrected
(see :py:func:`pingouin.sphericity`).
The default for two-way design is to return both the uncorrected and
Greenhouse-Geisser corrected p-values. Note that sphericity test for
two-way design are not currently implemented in Pingouin.
detailed : boolean
If True, return a full ANOVA table.
effsize : string
Effect size. Must be one of 'np2' (partial eta-squared), 'n2'
(eta-squared) or 'ng2'(generalized eta-squared, default). Note that for
one-way repeated measure ANOVA, eta-squared is the same as the generalized eta-squared.
Returns
-------
aov : :py:class:`pandas.DataFrame`
ANOVA summary:
* ``'Source'``: Name of the within-group factor
* ``'ddof1'``: Degrees of freedom (numerator)
* ``'ddof2'``: Degrees of freedom (denominator)
* ``'F'``: F-value
* ``'p-unc'``: Uncorrected p-value
* ``'ng2'``: Generalized eta-square effect size
* ``'eps'``: Greenhouse-Geisser epsilon factor (= index of sphericity)
* ``'p-GG-corr'``: Greenhouse-Geisser corrected p-value
* ``'W-spher'``: Sphericity test statistic
* ``'p-spher'``: p-value of the sphericity test
* ``'sphericity'``: sphericity of the data (boolean)
See Also
--------
anova : One-way and N-way ANOVA
mixed_anova : Two way mixed ANOVA
friedman : Non-parametric one-way repeated measures ANOVA
Notes
-----
Data can be in wide or long format for one-way repeated measures ANOVA but
*must* be in long format for two-way repeated measures ANOVA.
In one-way repeated-measures ANOVA, the total variance (sums of squares)
is divided into three components
.. math::
SS_{\text{total}} = SS_{\text{effect}} +
(SS_{\text{subjects}} + SS_{\text{error}})
with
.. math::
SS_{\text{total}} = \sum_i^r \sum_j^n (Y_{ij} - \overline{Y})^2
SS_{\text{effect}} = \sum_i^r n_i(\overline{Y_i} - \overline{Y})^2
SS_{\text{subjects}} = r\sum (\overline{Y}_s - \overline{Y})^2
SS_{\text{error}} = SS_{\text{total}} - SS_{\text{effect}} -
SS_{\text{subjects}}
where :math:`i=1,...,r; j=1,...,n_i`, :math:`r` is the number of
conditions, :math:`n_i` the number of observations for each condition,
:math:`\overline{Y}` the grand mean of the data, :math:`\overline{Y_i}`
the mean of the :math:`i^{th}` condition and :math:`\overline{Y}_{subj}`
the mean of the :math:`s^{th}` subject.
The F-statistics is then defined as:
.. math::
F^* = \frac{MS_{\text{effect}}}{MS_{\text{error}}} =
\frac{\frac{SS_{\text{effect}}}
{r-1}}{\frac{SS_{\text{error}}}{(n - 1)(r - 1)}}
and the p-value can be calculated using a F-distribution with
:math:`v_{\text{effect}} = r - 1` and
:math:`v_{\text{error}} = (n - 1)(r - 1)` degrees of freedom.
The default effect size reported in Pingouin is the generalized eta-squared,
which is equivalent to eta-squared for one-way repeated measures ANOVA.
.. math::
\eta_g^2 = \frac{SS_{\text{effect}}}{SS_{\text{total}}}
The partial eta-squared is defined as:
.. math::
\eta_p^2 = \frac{SS_{\text{effect}}}{SS_{\text{effect}} + SS_{\text{error}}}
Missing values are automatically removed using a strict listwise approach (= complete-case
analysis). In other words, any subject with one or more missing value(s) is completely removed
from the dataframe prior to running the test. This could drastically decrease the power of the
ANOVA if many missing values are present. In that case, we strongly recommend using linear
mixed effect modelling, which can handle missing values in repeated measures.
.. warning:: The epsilon adjustement factor of the interaction in
two-way repeated measures ANOVA where both factors have more than
two levels slightly differs than from R and JASP.
Please always make sure to double-check your results with another
software.
.. warning:: Sphericity tests for the interaction term of a two-way
repeated measures ANOVA are not currently supported in Pingouin.
Instead, please refer to the Greenhouse-Geisser epsilon value
(a value close to 1 indicates that sphericity is met.) For more
details, see :py:func:`pingouin.sphericity`.
Examples
--------
1. One-way repeated measures ANOVA using a wide-format dataset
>>> import pingouin as pg
>>> data = pg.read_dataset('rm_anova_wide')
>>> pg.rm_anova(data)
Source ddof1 ddof2 F p-unc ng2 eps
0 Within 3 24 5.200652 0.006557 0.346392 0.694329
2. One-way repeated-measures ANOVA using a long-format dataset.
We're also specifying two additional options here: ``detailed=True`` means
that we'll get a more detailed ANOVA table, and ``effsize='np2'``
means that we want to get the partial eta-squared effect size instead
of the default (generalized) eta-squared.
>>> df = pg.read_dataset('rm_anova')
>>> aov = pg.rm_anova(dv='DesireToKill', within='Disgustingness',
... subject='Subject', data=df, detailed=True, effsize="np2")
>>> aov.round(3)
Source SS DF MS F p-unc np2 eps
0 Disgustingness 27.485 1 27.485 12.044 0.001 0.116 1.0
1 Error 209.952 92 2.282 NaN NaN NaN NaN
3. Two-way repeated-measures ANOVA
>>> aov = pg.rm_anova(dv='DesireToKill', within=['Disgustingness', 'Frighteningness'],
... subject='Subject', data=df)
4. As a :py:class:`pandas.DataFrame` method
>>> df.rm_anova(dv='DesireToKill', within='Disgustingness', subject='Subject', detailed=False)
Source ddof1 ddof2 F p-unc ng2 eps
0 Disgustingness 1 92 12.043878 0.000793 0.025784 1.0
| @pf.register_dataframe_method
def rm_anova(
data=None, dv=None, within=None, subject=None, correction="auto", detailed=False, effsize="ng2"
):
"""One-way and two-way repeated measures ANOVA.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a
:py:class:`pandas.DataFrame` method, in which case this argument is no
longer needed.
Both wide and long-format dataframe are supported for one-way repeated
measures ANOVA. However, ``data`` must be in long format for two-way
repeated measures.
dv : string
Name of column containing the dependent variable (only required if
``data`` is in long format).
within : string or list of string
Name of column containing the within factor (only required if ``data``
is in long format).
If ``within`` is a single string, then compute a one-way repeated
measures ANOVA, if ``within`` is a list with two strings,
compute a two-way repeated measures ANOVA.
subject : string
Name of column containing the subject identifier (only required if
``data`` is in long format).
correction : string or boolean
If True, also return the Greenhouse-Geisser corrected p-value.
The default for one-way design is to compute Mauchly's test of
sphericity to determine whether the p-values needs to be corrected
(see :py:func:`pingouin.sphericity`).
The default for two-way design is to return both the uncorrected and
Greenhouse-Geisser corrected p-values. Note that sphericity test for
two-way design are not currently implemented in Pingouin.
detailed : boolean
If True, return a full ANOVA table.
effsize : string
Effect size. Must be one of 'np2' (partial eta-squared), 'n2'
(eta-squared) or 'ng2'(generalized eta-squared, default). Note that for
one-way repeated measure ANOVA, eta-squared is the same as the generalized eta-squared.
Returns
-------
aov : :py:class:`pandas.DataFrame`
ANOVA summary:
* ``'Source'``: Name of the within-group factor
* ``'ddof1'``: Degrees of freedom (numerator)
* ``'ddof2'``: Degrees of freedom (denominator)
* ``'F'``: F-value
* ``'p-unc'``: Uncorrected p-value
* ``'ng2'``: Generalized eta-square effect size
* ``'eps'``: Greenhouse-Geisser epsilon factor (= index of sphericity)
* ``'p-GG-corr'``: Greenhouse-Geisser corrected p-value
* ``'W-spher'``: Sphericity test statistic
* ``'p-spher'``: p-value of the sphericity test
* ``'sphericity'``: sphericity of the data (boolean)
See Also
--------
anova : One-way and N-way ANOVA
mixed_anova : Two way mixed ANOVA
friedman : Non-parametric one-way repeated measures ANOVA
Notes
-----
Data can be in wide or long format for one-way repeated measures ANOVA but
*must* be in long format for two-way repeated measures ANOVA.
In one-way repeated-measures ANOVA, the total variance (sums of squares)
is divided into three components
.. math::
SS_{\\text{total}} = SS_{\\text{effect}} +
(SS_{\\text{subjects}} + SS_{\\text{error}})
with
.. math::
SS_{\\text{total}} = \\sum_i^r \\sum_j^n (Y_{ij} - \\overline{Y})^2
SS_{\\text{effect}} = \\sum_i^r n_i(\\overline{Y_i} - \\overline{Y})^2
SS_{\\text{subjects}} = r\\sum (\\overline{Y}_s - \\overline{Y})^2
SS_{\\text{error}} = SS_{\\text{total}} - SS_{\\text{effect}} -
SS_{\\text{subjects}}
where :math:`i=1,...,r; j=1,...,n_i`, :math:`r` is the number of
conditions, :math:`n_i` the number of observations for each condition,
:math:`\\overline{Y}` the grand mean of the data, :math:`\\overline{Y_i}`
the mean of the :math:`i^{th}` condition and :math:`\\overline{Y}_{subj}`
the mean of the :math:`s^{th}` subject.
The F-statistics is then defined as:
.. math::
F^* = \\frac{MS_{\\text{effect}}}{MS_{\\text{error}}} =
\\frac{\\frac{SS_{\\text{effect}}}
{r-1}}{\\frac{SS_{\\text{error}}}{(n - 1)(r - 1)}}
and the p-value can be calculated using a F-distribution with
:math:`v_{\\text{effect}} = r - 1` and
:math:`v_{\\text{error}} = (n - 1)(r - 1)` degrees of freedom.
The default effect size reported in Pingouin is the generalized eta-squared,
which is equivalent to eta-squared for one-way repeated measures ANOVA.
.. math::
\\eta_g^2 = \\frac{SS_{\\text{effect}}}{SS_{\\text{total}}}
The partial eta-squared is defined as:
.. math::
\\eta_p^2 = \\frac{SS_{\\text{effect}}}{SS_{\\text{effect}} + SS_{\\text{error}}}
Missing values are automatically removed using a strict listwise approach (= complete-case
analysis). In other words, any subject with one or more missing value(s) is completely removed
from the dataframe prior to running the test. This could drastically decrease the power of the
ANOVA if many missing values are present. In that case, we strongly recommend using linear
mixed effect modelling, which can handle missing values in repeated measures.
.. warning:: The epsilon adjustement factor of the interaction in
two-way repeated measures ANOVA where both factors have more than
two levels slightly differs than from R and JASP.
Please always make sure to double-check your results with another
software.
.. warning:: Sphericity tests for the interaction term of a two-way
repeated measures ANOVA are not currently supported in Pingouin.
Instead, please refer to the Greenhouse-Geisser epsilon value
(a value close to 1 indicates that sphericity is met.) For more
details, see :py:func:`pingouin.sphericity`.
Examples
--------
1. One-way repeated measures ANOVA using a wide-format dataset
>>> import pingouin as pg
>>> data = pg.read_dataset('rm_anova_wide')
>>> pg.rm_anova(data)
Source ddof1 ddof2 F p-unc ng2 eps
0 Within 3 24 5.200652 0.006557 0.346392 0.694329
2. One-way repeated-measures ANOVA using a long-format dataset.
We're also specifying two additional options here: ``detailed=True`` means
that we'll get a more detailed ANOVA table, and ``effsize='np2'``
means that we want to get the partial eta-squared effect size instead
of the default (generalized) eta-squared.
>>> df = pg.read_dataset('rm_anova')
>>> aov = pg.rm_anova(dv='DesireToKill', within='Disgustingness',
... subject='Subject', data=df, detailed=True, effsize="np2")
>>> aov.round(3)
Source SS DF MS F p-unc np2 eps
0 Disgustingness 27.485 1 27.485 12.044 0.001 0.116 1.0
1 Error 209.952 92 2.282 NaN NaN NaN NaN
3. Two-way repeated-measures ANOVA
>>> aov = pg.rm_anova(dv='DesireToKill', within=['Disgustingness', 'Frighteningness'],
... subject='Subject', data=df)
4. As a :py:class:`pandas.DataFrame` method
>>> df.rm_anova(dv='DesireToKill', within='Disgustingness', subject='Subject', detailed=False)
Source ddof1 ddof2 F p-unc ng2 eps
0 Disgustingness 1 92 12.043878 0.000793 0.025784 1.0
"""
assert effsize in ["n2", "np2", "ng2"], "effsize must be n2, np2 or ng2."
if isinstance(within, list):
assert len(within) > 0, "Within cannot be empty."
if len(within) == 1:
within = within[0]
elif len(within) == 2:
return rm_anova2(dv=dv, within=within, data=data, subject=subject, effsize=effsize)
else:
raise ValueError("Repeated measures ANOVA with three or more factors is not supported.")
# Convert from wide to long-format, if needed
if all([v is None for v in [dv, within, subject]]):
assert isinstance(data, pd.DataFrame)
data = data._get_numeric_data().d | (data=None, dv=None, within=None, subject=None, correction='auto', detailed=False, effsize='ng2') | [
0.012453681789338589,
0.006064401473850012,
0.03599655255675316,
-0.027614684775471687,
0.036776263266801834,
-0.039007097482681274,
-0.015767443925142288,
-0.06107718497514725,
0.06874432414770126,
0.00843601580709219,
-0.05263034254312515,
0.007851233705878258,
0.020066671073436737,
0.044963203370571136,
-0.0341339148581028,
0.061943527311086655,
-0.002547590062022209,
0.0462627187371254,
0.04968477413058281,
0.006475914269685745,
-0.0014863198157399893,
0.029585614800453186,
-0.021138770505785942,
-0.0011560264974832535,
0.015139345079660416,
0.021322868764400482,
-0.005560839548707008,
-0.06367621570825577,
0.01557251624763012,
0.010255335830152035,
0.006264743395149708,
-0.05930118262767792,
-0.05397317185997963,
0.032574500888586044,
0.0020047719590365887,
-0.04299227520823479,
-0.017478471621870995,
0.001319142640568316,
-0.05042116716504097,
0.05826156958937645,
-0.01965515874326229,
-0.02525389939546585,
0.034155573695898056,
-0.014478757977485657,
-0.025665413588285446,
-0.01724022626876831,
0.003265030449256301,
0.0742022842168808,
-0.004797374829649925,
-0.035390112549066544,
0.00040508306119591,
0.0019059547921642661,
0.025297217071056366,
0.037880849093198776,
0.020337402820587158,
0.07632482051849365,
-0.03809743747115135,
0.05375658720731735,
0.06623192876577377,
-0.0761948749423027,
0.03558504208922386,
0.03400396555662155,
-0.009573090821504593,
-0.022351650521159172,
-0.00862552784383297,
-0.03376572206616402,
0.0008426539716310799,
0.02469077706336975,
-0.013558268547058105,
-0.03562835976481438,
-0.0677047073841095,
0.015377589501440525,
0.021669406443834305,
0.00016497743490617722,
0.022394968196749687,
0.018680522218346596,
-0.028589321300387383,
-0.05574917793273926,
0.010325726121664047,
0.004624105989933014,
0.041346222162246704,
-0.004277568776160479,
-0.003332713386043906,
0.006280987057834864,
0.004913789685815573,
-0.009854651987552643,
-0.011858070269227028,
0.005154740996658802,
0.10257501900196075,
-0.049251604825258255,
0.057828400284051895,
0.0020846379920840263,
0.018160715699195862,
-0.028502685949206352,
-0.012399534694850445,
0.010168701410293579,
-0.017391836270689964,
-0.03235791251063347,
0.009345675818622112,
-0.04251578450202942,
-0.02570873126387596,
0.01939525455236435,
0.03159986436367035,
0.07173320651054382,
0.010044164955615997,
0.02125789225101471,
-0.03664631024003029,
0.027571367099881172,
0.05063775181770325,
0.012507827952504158,
-0.07688795030117035,
0.038920462131500244,
-0.05761181190609932,
-0.03803246095776558,
-0.010336555540561676,
-0.025102289393544197,
-0.01417553797364235,
0.014251342974603176,
-0.10396116971969604,
-0.004507691133767366,
0.061467040330171585,
0.05098428949713707,
-0.03216298669576645,
-0.03419889137148857,
0.05098428949713707,
-0.05817493796348572,
-0.022059259936213493,
-0.04634935408830643,
0.005447132047265768,
-0.05366995185613632,
-0.04024163633584976,
0.0005543241859413683,
-0.006827866192907095,
0.02971556782722473,
-0.0029591030906885862,
0.004207178484648466,
0.09807003289461136,
-0.03235791251063347,
-0.003246079199016094,
-0.04080475866794586,
0.0272248312830925,
0.062030162662267685,
-0.02432258240878582,
-0.06120713800191879,
0.01780335046350956,
-0.022893115878105164,
0.055792491883039474,
-0.001594612724147737,
-0.004396690987050533,
0.0072231353260576725,
-0.020478183403611183,
-0.02993215247988701,
-0.005896547343581915,
-0.009231967851519585,
0.08698084205389023,
-0.017825009301304817,
0.022394968196749687,
-0.05033453181385994,
-0.016850372776389122,
-0.046739209443330765,
-0.02908746898174286,
-0.02750639244914055,
-0.03138327598571777,
0.042169246822595596,
0.015778273344039917,
-0.00783499050885439,
-0.008425186388194561,
-0.006768305320292711,
-0.018528912216424942,
-0.022308334708213806,
-0.024365898221731186,
0.012832706794142723,
-0.026531755924224854,
-0.011663143523037434,
-0.0441618375480175,
0.06974061578512192,
-0.024647459387779236,
-0.011186654679477215,
0.022698188200592995,
-0.05063775181770325,
-0.03681958094239235,
-0.008593040518462658,
-0.031751472502946854,
-0.024907363578677177,
-0.03441547974944115,
0.01630890741944313,
0.02190764993429184,
-0.0026355779264122248,
-0.001193928997963667,
-0.01910286396741867,
-0.02570873126387596,
-0.0423208586871624,
0.02274150587618351,
0.02926073782145977,
-0.003487030742689967,
-0.060080889612436295,
0.0009996786247938871,
-0.03279108554124832,
0.08269244432449341,
-0.038465630263090134,
-0.04028495401144028,
0.01015787199139595,
-0.001544527243822813,
0.019730962812900543,
-0.04071812331676483,
0.034437138587236404,
-0.022394968196749687,
0.012291242368519306,
-0.02021828107535839,
-0.007899966090917587,
0.015702467411756516,
-0.0028751760255545378,
0.06779134273529053,
0.031556546688079834,
0.02395438589155674,
-0.0335707925260067,
0.04177939519286156,
0.0032623230945318937,
0.011040459387004375,
0.052890244871377945,
-0.011013385839760303,
-0.05358332023024559,
-0.07775428891181946,
0.04773550108075142,
0.027159854769706726,
0.034177232533693314,
0.014381295070052147,
0.08598455041646957,
0.03441547974944115,
-0.037317726761102676,
0.013666561804711819,
0.014944417402148247,
-0.00017699117597658187,
-0.03896377980709076,
0.0052901073358953,
0.032574500888586044,
-0.02023993991315365,
-0.00964889582246542,
-0.028957515954971313,
-0.0191136933863163,
-0.03577996790409088,
-0.03021371364593506,
0.041259586811065674,
0.048601847141981125,
-0.000645357882604003,
-0.031534887850284576,
0.03902875632047653,
0.04342544451355934,
-0.0014687222428619862,
-0.05341004952788353,
0.03662465140223503,
-0.009248211979866028,
-0.015583345666527748,
0.05999425798654556,
-0.010336555540561676,
-0.05436302721500397,
0.03590992093086243,
0.016828713938593864,
0.04695579409599304,
-0.030538592487573624,
0.02395438589155674,
-0.008376454934477806,
0.0011451971950009465,
0.008614698424935341,
-0.02553546242415905,
0.01846393570303917,
-0.037794217467308044,
-0.0225682370364666,
0.02051067166030407,
-0.009448554366827011,
-0.042559102177619934,
0.016276421025395393,
-0.004908374976366758,
0.018777985125780106,
-0.03749099746346474,
0.0764547735452652,
-0.0007539892103523016,
0.03255284205079079,
-0.0021563819609582424,
-0.014370465651154518,
0.0010612702462822199,
0.0020413207821547985,
0.007374745327979326,
0.005460668820887804,
-0.023889409378170967,
-0.014695344492793083,
-0.02739810012280941,
-0.024755753576755524,
0.026336828246712685,
0.003064688527956605,
0.005907376762479544,
-0.048601847141981125,
0.03283440321683884,
-0.022784821689128876,
0.0008778491755947471,
0.07013046741485596,
-0.0348486490547657,
0.002988883526995778,
-0.02339126355946064,
0.03166483715176582,
-0.010217433795332909,
0.022871457040309906,
0.06233338266611099,
0.0014186367625370622,
-0.05358332023024559,
0.021041307598352432,
0.0430355928838253,
-0.04184437170624733,
0.05834820494055748,
-0.06878764182329178,
0.004908374976366758,
0.03320259973406792,
-0.032964352518320084,
0.024539167061448097,
0.02088969759643078,
-0.008917919360101223,
-0.017294373363256454,
-0.040869735181331635,
0.0713866651058197,
0.026726683601737022,
-0.03785919025540352,
-0.014143050648272038,
0.04760555177927017,
-0.04847189411520958,
0.05544595420360565,
-0.0037496411241590977,
0.05583580955862999,
-0.009286114946007729,
0.027549710124731064,
0.021279551088809967,
-0.039938416332006454,
-0.0643259733915329,
0.004867765121161938,
0.024214288219809532,
-0.05800166726112366,
-0.04773550108075142,
-0.006237669847905636,
-0.020164133980870247,
0.05488283187150955,
0.04587286338210106,
0.06566880643367767,
0.04578623175621033,
-0.002802078379318118,
-0.03253118321299553,
0.03783753141760826,
-0.036494702100753784,
0.05414644256234169,
-0.007634648121893406,
0.04368535056710243,
0.018398961052298546,
-0.0020521502010524273,
0.05917122960090637,
0.022329991683363914,
0.028589321300387383,
0.08442512899637222,
0.0007587270229123533,
0.0007228549802675843,
0.024495849385857582,
0.012367047369480133,
-0.017272714525461197,
-0.015583345666527748,
0.004190934356302023,
-0.000612870033364743,
-0.02993215247988701,
0.0170669574290514,
-0.03027869015932083,
-0.027181513607501984,
-0.03289937600493431,
-0.009351090528070927,
-0.05081101879477501,
-0.029498981311917305,
-0.050204578787088394,
0.024625802412629128,
-0.0527602918446064,
0.0337224043905735,
0.004182812757790089,
0.011868899688124657,
-0.012237096205353737,
0.030538592487573624,
0.003752348478883505,
0.04056651517748833,
-0.012648608535528183,
-0.06510568410158157,
0.014619539491832256,
0.028654295951128006,
-0.002741163596510887,
-0.03121000900864601,
0.03380903974175453,
-0.021279551088809967,
0.0010551788145676255,
0.02674834243953228,
-0.0165038350969553,
0.08841031044721603,
-0.012995146214962006,
0.033895671367645264,
0.027268147096037865,
-0.09720369428396225,
-0.0052901073358953,
-0.07255623489618301,
-0.006465085316449404,
0.00575576676055789,
-0.008712162263691425,
-0.029434004798531532,
0.005054570268839598,
-0.04717237874865532,
-0.05180731415748596,
0.015605004504323006,
-0.013623245060443878,
-0.03112337365746498,
0.038465630263090134,
0.012616121210157871,
0.045439694076776505,
0.0006189615232869983,
0.003432884346693754,
0.01127328909933567,
0.06467250734567642,
0.013742366805672646,
-0.0330076701939106,
0.033332549035549164,
0.018767155706882477,
0.06731485575437546,
-0.024907363578677177,
0.00512496056035161,
0.052240487188100815,
0.07021710276603699,
-0.002902249339967966,
-0.08043995499610901,
0.025773705914616585,
-0.024170970544219017,
0.0055770836770534515,
0.024734094738960266,
-0.002581431530416012,
-0.008500991389155388,
-0.044703301042318344,
-0.024560825899243355,
-0.012193778529763222,
-0.0663185641169548,
0.013287536799907684,
0.028675954788923264,
0.052716974169015884,
0.034350503236055374,
0.02341292053461075,
0.027463074773550034,
0.02469077706336975,
-0.04985804483294487,
0.00703903753310442,
0.038270704448223114,
-0.019633499905467033,
-0.06735817342996597,
-0.04353373870253563,
0.10621365904808044,
0.035758309066295624,
0.03326757252216339,
0.00783499050885439,
-0.029412347823381424,
0.0016325152246281505,
0.006345963105559349,
-0.009675969369709492,
-0.07753770053386688,
-0.031751472502946854,
-0.012464511208236217,
0.01267026737332344,
-0.06584206968545914,
0.03419889137148857,
-0.031643182039260864,
0.04221256449818611,
0.04453003406524658,
0.003955397754907608,
-0.020337402820587158,
0.01836647279560566,
-0.05375658720731735,
-0.0784473642706871,
-0.03142659366130829,
-0.004077226854860783,
0.02889254130423069,
0.037231091409921646,
-0.019709303975105286,
-0.04182271286845207,
-0.005441717337816954,
0.04294895753264427,
0.03554172441363335,
-0.021691065281629562,
0.03915870562195778,
0.0021441990975290537,
0.036126505583524704,
-0.007493867538869381,
0.003866055980324745,
-0.004201763775199652,
-0.05141746252775192,
-0.01095382496714592,
-0.00866343080997467,
-0.002136077033355832,
-0.019406083971261978,
0.05302019417285919,
-0.028632638975977898,
0.03190308436751366,
0.017543446272611618,
0.0068224514834582806,
0.023044725880026817,
-0.05436302721500397,
0.05366995185613632,
-0.03662465140223503,
-0.06484577804803848,
-0.019319450482726097,
0.015680808573961258,
-0.038162410259246826,
-0.006519231479614973,
0.011641484685242176,
-0.00875547993928194,
0.01002250611782074,
-0.026813317090272903,
-0.03235791251063347,
0.04816867411136627,
0.02900083363056183,
0.033505819737911224,
0.03162152320146561,
-0.010471921414136887,
0.005016667768359184,
0.01324421912431717,
0.015085198916494846,
0.012735242955386639,
-0.0846417173743248,
-0.018117399886250496,
-0.012269583530724049,
-0.016698762774467468,
0.04197432100772858,
-0.019785109907388687,
0.02171272225677967,
0.026401804760098457,
-0.024192629382014275,
0.004959814250469208,
-0.033982306718826294,
0.04182271286845207,
0.04091305285692215,
0.018149886280298233,
-0.010980898514389992,
-0.019720133394002914,
-0.0761948749423027,
0.019341109320521355,
0.036494702100753784,
-0.0050843507051467896,
0.022979749366641045,
-0.04556964337825775,
-0.02993215247988701,
-0.014738661237061024,
-0.0024650166742503643,
0.0359748974442482,
-0.04565627872943878,
0.0249723382294178,
-0.015074369497597218,
-0.011479045264422894,
-0.05544595420360565,
0.04838525876402855,
0.07117008417844772,
0.007250208407640457,
0.0337224043905735,
0.028177808970212936,
-0.01002250611782074,
0.021420331671833992,
-0.047388967126607895,
0.00834396667778492,
-0.08026668429374695,
0.059691037982702255,
-0.07818745821714401,
0.0028643468394875526,
0.051677364856004715,
0.02573038823902607,
0.03385235369205475,
-0.06051406264305115,
-0.03064688667654991,
-0.014857783913612366,
0.011879729107022285,
-0.027268147096037865,
-0.04275403171777725,
-0.06818120181560516,
-0.0152368089184165,
0.01983925700187683,
-0.0191136933863163,
-0.00610771868377924,
0.04286232218146324,
-0.027722977101802826,
-0.0555759072303772,
0.000659571320284158,
-0.021117111667990685,
-0.025470485910773277,
0.04290563985705376,
0.01412139181047678,
0.0488184317946434,
0.0025178096257150173,
0.03944026678800583,
-0.06445592641830444,
-0.02135535702109337,
-0.021647747606039047,
-0.06047074496746063,
-0.02471243590116501,
0.07502531260251999,
0.035108551383018494,
-0.0063243042677640915,
0.058954644948244095,
0.0050518629141151905,
-0.015117686241865158,
0.003086347132921219,
0.007282696198672056,
-0.03586660325527191,
-0.0013827647780999541,
0.0005621077725663781,
0.04314388334751129,
0.0069307442754507065,
0.041432857513427734,
-0.01585407741367817,
-0.004902960266917944,
0.02573038823902607,
-0.004112422000616789,
-0.04212593287229538,
0.008609284646809101,
-0.019590182229876518,
-0.060903917998075485,
-0.014717002399265766,
-0.018420619890093803,
-0.009080357849597931,
-0.03712280094623566,
0.008690503425896168,
-0.0382273867726326,
0.02021828107535839,
-0.014922759495675564,
0.016482176259160042,
0.012518657371401787,
-0.04968477413058281,
-0.08316893130540848,
-0.09633734822273254,
-0.00978426169604063,
0.054579611867666245,
-0.002501565497368574,
-0.005338839255273342,
-0.0061239623464643955,
-0.012226266786456108,
0.029022492468357086,
0.04000338912010193,
-0.05172068253159523,
0.014803636819124222,
0.014208026230335236,
-0.05600908026099205,
0.005276570562273264,
0.0688309594988823,
0.00685493927448988,
0.04704242944717407,
-0.04695579409599304,
-0.043577056378126144,
0.007856648415327072,
0.03783753141760826,
0.048991698771715164,
0.01891876570880413,
-0.06917749345302582,
0.0013787037460133433,
0.0041530318558216095,
0.04056651517748833,
0.05098428949713707,
-0.00819777138531208,
-0.005874888971447945,
-0.004033910110592842,
0.011062118224799633,
-0.03095010668039322,
-0.02917410247027874,
-0.01122997235506773,
0.12943165004253387,
0.013525781221687794,
0.05791503190994263,
0.038162410259246826,
0.026250194758176804,
0.08087312430143356,
-0.005636644549667835,
0.025513803586363792,
-0.010471921414136887,
0.05202390253543854,
0.0445733517408371,
-0.03931031748652458,
0.01977428048849106,
0.00536320498213172,
-0.024929022416472435,
-0.006638353690505028,
0.006486743688583374,
0.04500652104616165,
0.025795364752411842,
-0.09746359288692474,
0.0009915566770359874,
-0.025968633592128754,
0.05934450030326843,
-0.0065896217711269855,
-0.02310970053076744,
-0.08533479273319244,
-0.06900422275066376,
-0.0162980780005455,
0.013666561804711819,
0.03190308436751366,
-0.02341292053461075,
-0.03010542131960392,
-0.019828427582979202,
0.006827866192907095,
-0.015529199503362179,
-0.004502276424318552,
0.00152692967094481,
-0.0092752855271101,
0.03740436211228371,
-0.014478757977485657,
-0.028957515954971313,
0.0812629759311676,
-0.029758883640170097,
0.01099172793328762,
0.0065950364805758,
-0.06649182736873627,
-0.02162608876824379,
0.0736391618847847,
0.023066384717822075,
0.020727258175611496,
0.038530606776475906,
-0.001644698204472661,
-0.005003130994737148,
0.008035331964492798,
-0.03233625367283821,
0.04076144099235535,
0.021940138190984726,
0.05371326953172684,
0.0068982564844191074,
-0.022676529362797737,
-0.023542873561382294,
0.004575374070554972,
-0.01486861240118742,
0.0044779106974601746,
0.030993422493338585,
-0.05808830261230469,
0.055402640253305435,
0.029022492468357086,
0.029390688985586166,
-0.03465372323989868,
-0.027831271290779114,
0.009654310531914234,
-0.005836986470967531,
-0.020716428756713867,
-0.009199480526149273,
0.04411851987242699,
0.0032379571348428726,
-0.0019722841680049896,
-0.030603569000959396,
-0.06523562967777252,
-0.025145607069134712,
0.034826990216970444,
0.028740931302309036,
0.050940971821546555,
0.016005687415599823,
-0.05509942024946213,
0.041151296347379684,
-0.05722196027636528,
0.028567662462592125,
0.032661132514476776,
-0.0003929001104552299,
0.020109988749027252,
0.034177232533693314,
-0.022958090528845787,
0.023282969370484352,
-0.035173527896404266,
-0.06627524644136429,
-0.04717237874865532,
0.03926699981093407,
0.08230259269475937,
0.020012523978948593,
0.00922113936394453,
-0.01882130280137062,
0.03458874672651291
]
|
32,060 | pingouin.correlation | rm_corr | Repeated measures correlation.
Parameters
----------
data : :py:class:`pandas.DataFrame`
Dataframe.
x, y : string
Name of columns in ``data`` containing the two dependent variables.
subject : string
Name of column in ``data`` containing the subject indicator.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'r'``: Repeated measures correlation coefficient
* ``'dof'``: Degrees of freedom
* ``'pval'``: p-value
* ``'CI95'``: 95% parametric confidence intervals
* ``'power'``: achieved power of the test (= 1 - type II error).
See also
--------
plot_rm_corr
Notes
-----
Repeated measures correlation (rmcorr) is a statistical technique for determining the common
within-individual association for paired measures assessed on two or more occasions for
multiple individuals.
From `Bakdash and Marusich (2017)
<https://doi.org/10.3389/fpsyg.2017.00456>`_:
*Rmcorr accounts for non-independence among observations using analysis
of covariance (ANCOVA) to statistically adjust for inter-individual
variability. By removing measured variance between-participants,
rmcorr provides the best linear fit for each participant using parallel
regression lines (the same slope) with varying intercepts.
Like a Pearson correlation coefficient, the rmcorr coefficient
is bounded by − 1 to 1 and represents the strength of the linear
association between two variables.*
Results have been tested against the `rmcorr <https://github.com/cran/rmcorr>`_ R package.
Missing values are automatically removed from the dataframe (listwise deletion).
Examples
--------
>>> import pingouin as pg
>>> df = pg.read_dataset('rm_corr')
>>> pg.rm_corr(data=df, x='pH', y='PacO2', subject='Subject')
r dof pval CI95% power
rm_corr -0.50677 38 0.000847 [-0.71, -0.23] 0.929579
Now plot using the :py:func:`pingouin.plot_rm_corr` function:
.. plot::
>>> import pingouin as pg
>>> df = pg.read_dataset('rm_corr')
>>> g = pg.plot_rm_corr(data=df, x='pH', y='PacO2', subject='Subject')
| def rm_corr(data=None, x=None, y=None, subject=None):
"""Repeated measures correlation.
Parameters
----------
data : :py:class:`pandas.DataFrame`
Dataframe.
x, y : string
Name of columns in ``data`` containing the two dependent variables.
subject : string
Name of column in ``data`` containing the subject indicator.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'r'``: Repeated measures correlation coefficient
* ``'dof'``: Degrees of freedom
* ``'pval'``: p-value
* ``'CI95'``: 95% parametric confidence intervals
* ``'power'``: achieved power of the test (= 1 - type II error).
See also
--------
plot_rm_corr
Notes
-----
Repeated measures correlation (rmcorr) is a statistical technique for determining the common
within-individual association for paired measures assessed on two or more occasions for
multiple individuals.
From `Bakdash and Marusich (2017)
<https://doi.org/10.3389/fpsyg.2017.00456>`_:
*Rmcorr accounts for non-independence among observations using analysis
of covariance (ANCOVA) to statistically adjust for inter-individual
variability. By removing measured variance between-participants,
rmcorr provides the best linear fit for each participant using parallel
regression lines (the same slope) with varying intercepts.
Like a Pearson correlation coefficient, the rmcorr coefficient
is bounded by − 1 to 1 and represents the strength of the linear
association between two variables.*
Results have been tested against the `rmcorr <https://github.com/cran/rmcorr>`_ R package.
Missing values are automatically removed from the dataframe (listwise deletion).
Examples
--------
>>> import pingouin as pg
>>> df = pg.read_dataset('rm_corr')
>>> pg.rm_corr(data=df, x='pH', y='PacO2', subject='Subject')
r dof pval CI95% power
rm_corr -0.50677 38 0.000847 [-0.71, -0.23] 0.929579
Now plot using the :py:func:`pingouin.plot_rm_corr` function:
.. plot::
>>> import pingouin as pg
>>> df = pg.read_dataset('rm_corr')
>>> g = pg.plot_rm_corr(data=df, x='pH', y='PacO2', subject='Subject')
"""
from pingouin import ancova, power_corr
# Safety checks
assert isinstance(data, pd.DataFrame), "Data must be a DataFrame"
assert x in data.columns, "The %s column is not in data." % x
assert y in data.columns, "The %s column is not in data." % y
assert data[x].dtype.kind in "bfiu", "%s must be numeric." % x
assert data[y].dtype.kind in "bfiu", "%s must be numeric." % y
assert subject in data.columns, "The %s column is not in data." % subject
if data[subject].nunique() < 3:
raise ValueError("rm_corr requires at least 3 unique subjects.")
# Remove missing values
data = data[[x, y, subject]].dropna(axis=0)
# Using PINGOUIN
# For max precision, make sure rounding is disabled
old_options = options.copy()
options["round"] = None
aov = ancova(dv=y, covar=x, between=subject, data=data)
options.update(old_options) # restore options
bw = aov.bw_ # Beta within parameter
sign = np.sign(bw)
dof = int(aov.at[2, "DF"])
n = dof + 2
ssfactor = aov.at[1, "SS"]
sserror = aov.at[2, "SS"]
rm = sign * np.sqrt(ssfactor / (ssfactor + sserror))
pval = aov.at[1, "p-unc"]
ci = compute_esci(stat=rm, nx=n, eftype="pearson").tolist()
pwr = power_corr(r=rm, n=n, alternative="two-sided")
# Convert to Dataframe
stats = pd.DataFrame(
{"r": rm, "dof": int(dof), "pval": pval, "CI95%": [ci], "power": pwr}, index=["rm_corr"]
)
return _postprocess_dataframe(stats)
| (data=None, x=None, y=None, subject=None) | [
-0.015211055986583233,
0.040881041437387466,
0.052443139255046844,
-0.005515864118933678,
0.03907777741551399,
-0.041050758212804794,
-0.03697750344872475,
-0.0037868530489504337,
0.12822262942790985,
-0.013535082340240479,
-0.019973792135715485,
0.019772252067923546,
0.0206314530223608,
0.047606151551008224,
-0.06050478667020798,
0.022933267056941986,
-0.00702742300927639,
0.0009314650669693947,
-0.03561975434422493,
-0.03262845799326897,
0.01525348611176014,
0.08023460954427719,
-0.035004522651433945,
0.0201116893440485,
-0.014617039822041988,
0.04092346876859665,
-0.016409697011113167,
-0.02450316585600376,
0.02420615777373314,
0.040223378688097,
0.008528375066816807,
-0.024121299386024475,
-0.04336318001151085,
-0.011477240361273289,
-0.030825195834040642,
-0.01796898804605007,
0.024821389466524124,
-0.021236076951026917,
-0.039120204746723175,
0.052740149199962616,
-0.03031603805720806,
0.010092970915138721,
0.036701712757349014,
-0.015900539234280586,
-0.01454278826713562,
-0.01139238104224205,
-0.012262190692126751,
0.06406888365745544,
-0.001743596512824297,
-0.023060554638504982,
0.04003244638442993,
-0.05711041018366814,
-0.03612891212105751,
0.00995507463812828,
0.011084765195846558,
0.03470751643180847,
-0.05070352181792259,
0.07887686043977737,
0.04234486445784569,
-0.022148316726088524,
0.06326272338628769,
0.0036330451257526875,
-0.045951392501592636,
0.008459426462650299,
0.06381430476903915,
-0.02564876899123192,
0.023675786331295967,
-0.007032726891338825,
0.01621876284480095,
-0.042302437126636505,
-0.03532274439930916,
0.05443733558058739,
0.027282312512397766,
-0.020907247439026833,
0.0259245615452528,
-0.02206345647573471,
0.032098088413476944,
-0.05214613303542137,
-0.0031928368844091892,
0.012463731691241264,
0.03691386058926582,
0.021130003035068512,
0.049048762768507004,
0.016293013468384743,
0.020164726302027702,
-0.029446229338645935,
0.030337253585457802,
-0.010978691279888153,
-0.002015411853790283,
-0.02929772436618805,
0.003161014523357153,
-0.026497364044189453,
0.06016534939408302,
-0.015889931470155716,
0.001689233467914164,
-0.050024647265672684,
-0.016324836760759354,
0.05545565113425255,
0.05647396296262741,
-0.029403800144791603,
-0.03485601767897606,
0.047096993774175644,
0.015592924319207668,
0.06619036942720413,
0.01840389333665371,
0.042026642709970474,
0.0050756558775901794,
0.02397279441356659,
-0.00203264900483191,
0.006332636345177889,
-0.10098274797201157,
0.03801703453063965,
0.041517484933137894,
-0.03489844873547554,
0.010236171074211597,
-0.019273702055215836,
-0.07573705911636353,
0.011540885083377361,
-0.04633326083421707,
-0.010061148554086685,
0.009615636430680752,
0.04047795757651329,
-0.014023023657500744,
-0.030676690861582756,
0.005462827160954475,
-0.03288303688168526,
0.00751536525785923,
0.004513462074100971,
-0.036213770508766174,
-0.02496989257633686,
0.004399432335048914,
-0.04705456644296646,
0.025118397548794746,
0.020281407982110977,
0.014415498822927475,
0.03629862889647484,
0.09368482977151871,
-0.011657566763460636,
0.03144042566418648,
-0.05057623237371445,
0.028024833649396896,
0.07149408757686615,
-0.056813400238752365,
-0.0005940161645412445,
0.047139424830675125,
0.017735624685883522,
0.0469697043299675,
-0.0044948989525437355,
-0.025075968354940414,
-0.02978566661477089,
-0.014373069629073143,
-0.04066888988018036,
0.01478675939142704,
-0.01620815508067608,
0.06712382286787033,
-0.0518491230905056,
0.006025020964443684,
-0.022487754002213478,
-0.08269553631544113,
-0.013482045382261276,
0.007510061375796795,
0.016643060371279716,
0.021437618881464005,
-0.03629862889647484,
0.03606526553630829,
-0.0016295666573569179,
0.03513181209564209,
-0.034728728234767914,
0.0019066857639700174,
-0.030379682779312134,
-0.0620746873319149,
-0.025266900658607483,
0.003237918484956026,
-0.05227342247962952,
-0.041517484933137894,
0.005133996717631817,
-0.054394908249378204,
-0.03892927244305611,
-0.004709699656814337,
-0.0050650485791265965,
-0.004123638849705458,
-0.03714722394943237,
-0.005717405583709478,
-0.007822980172932148,
-0.03076155111193657,
0.03277696296572685,
0.05358874425292015,
-0.0348772332072258,
0.02494867891073227,
-0.04442392289638519,
-0.010936261154711246,
-0.003336037043482065,
-0.028767352923750877,
0.06894830614328384,
0.06355972588062286,
-0.06733597069978714,
0.03812310844659805,
-0.025012323632836342,
0.020398089662194252,
-0.04552709311246872,
0.009180732071399689,
0.01248494628816843,
0.0039247493259608746,
-0.012760739773511887,
0.0013577511999756098,
-0.029403800144791603,
-0.0027791468892246485,
0.05978348106145859,
0.02494867891073227,
-0.010872617363929749,
0.044466350227594376,
0.019241880625486374,
0.06826942414045334,
-0.017300721257925034,
-0.052018843591213226,
0.006390977185219526,
0.031885936856269836,
-0.06525691598653793,
0.03256481513381004,
0.05931675434112549,
0.019072161987423897,
0.014956478029489517,
-0.061650391668081284,
-0.00048727888497523963,
-0.011678781360387802,
0.0097959628328681,
-0.02397279441356659,
0.07607650011777878,
0.07637350261211395,
-0.09546688199043274,
0.04671512544155121,
0.009021620266139507,
-0.01937977597117424,
-0.08842355012893677,
-0.025882132351398468,
-0.05015193670988083,
0.003654259955510497,
0.07675537467002869,
-0.009037530981004238,
0.04045674204826355,
-0.04242972657084465,
0.04501793906092644,
0.043745044618844986,
0.09079961478710175,
-0.0016706704627722502,
-0.02083299495279789,
0.028024833649396896,
0.03786852955818176,
0.004277446772903204,
-0.027048949152231216,
0.01840389333665371,
-0.05575265735387802,
-0.002887873211875558,
0.026561006903648376,
0.018817583099007607,
-0.016770347952842712,
-0.011933360248804092,
0.005484041757881641,
0.044933076947927475,
-0.008666271343827248,
0.03239509463310242,
0.029021931812167168,
-0.018817583099007607,
0.03831404075026512,
-0.0068205781280994415,
-0.050788380205631256,
-0.10208591818809509,
0.025351760908961296,
0.008295010775327682,
-0.009461828507483006,
-0.03655320778489113,
-0.003877016017213464,
-0.0006490421947091818,
-0.00769569119438529,
-0.013004710897803307,
0.0451027974486351,
-0.008029825054109097,
-0.017290113493800163,
0.040796179324388504,
0.005643153563141823,
-0.025097182020545006,
-0.00035932674654759467,
0.03494087979197502,
-0.06551149487495422,
-0.00612579146400094,
-0.012856206856667995,
-0.01915702037513256,
-0.0048820702359080315,
-0.005237419158220291,
0.01575203612446785,
-0.02426980249583721,
-0.05944404378533363,
-0.03318004310131073,
0.04015973582863808,
0.032840605825185776,
0.04185692220926285,
-0.012750132009387016,
-0.03099491447210312,
0.014235172420740128,
0.03820796683430672,
0.0012536657741293311,
0.0047494773752987385,
0.0061417026445269585,
-0.02227560617029667,
-0.03464386984705925,
-0.016314228996634483,
0.0765007957816124,
-0.045442234724760056,
-0.015614138916134834,
0.01367297861725092,
0.0254578348249197,
0.02734595723450184,
0.024291018024086952,
0.0019398339791223407,
0.027918759733438492,
-0.02566998451948166,
0.027961188927292824,
-0.03298911079764366,
0.04340560734272003,
0.02450316585600376,
-0.026942875236272812,
-0.06691167503595352,
0.06848157942295074,
-0.006030324846506119,
0.07548248022794724,
-0.0003573378489818424,
-0.031610146164894104,
0.03167378902435303,
0.02834305539727211,
-0.010761238634586334,
-0.02420615777373314,
-0.014500358141958714,
-0.033837705850601196,
-0.01283499225974083,
0.05252799764275551,
-0.028894642367959023,
0.00968988798558712,
-0.02787632867693901,
0.04484821856021881,
0.023442422971129417,
0.016833992674946785,
-0.01887062005698681,
0.02571241371333599,
-0.023548496887087822,
-0.021978598088026047,
0.023824291303753853,
0.03511059656739235,
-0.00011005209671566263,
-0.011848500929772854,
-0.03271331638097763,
0.015147412195801735,
0.056092094630002975,
0.00798209197819233,
0.042790379375219345,
0.034771159291267395,
0.04387233406305313,
-0.01225158292800188,
0.031885936856269836,
0.05401303991675377,
0.023697001859545708,
-0.011699996888637543,
0.039395999163389206,
0.03687142953276634,
-0.032586026936769485,
-0.053885750472545624,
0.002834836021065712,
-0.09198764711618423,
0.04794558882713318,
-0.02084360271692276,
-0.03899291902780533,
-0.02836427092552185,
0.01140298880636692,
-0.005796961020678282,
-0.02569119818508625,
0.005102174356579781,
0.02564876899123192,
0.005590116139501333,
-0.031100988388061523,
0.007525972556322813,
-0.03691386058926582,
0.03148285672068596,
-0.053419023752212524,
-0.06220197677612305,
-0.006438710726797581,
-0.03182229399681091,
0.010034630075097084,
-0.0044842916540801525,
0.014733722433447838,
-0.029043147340416908,
-0.0008691463735885918,
-0.03659563884139061,
-0.05868031084537506,
0.05498892441391945,
-0.0042297132313251495,
-0.03604405000805855,
-0.004163416568189859,
-0.003715252736583352,
0.002677050419151783,
-0.04340560734272003,
-0.009827785193920135,
0.017481045797467232,
0.003749727038666606,
-0.005415093619376421,
-0.0057333167642354965,
0.017131000757217407,
0.03141921013593674,
0.03328612074255943,
-0.08222880959510803,
-0.0027844507712870836,
-0.007923751138150692,
-0.08261067420244217,
0.05426761880517006,
0.0513823963701725,
-0.025012323632836342,
0.01644151844084263,
0.03763516619801521,
0.00032054330222308636,
-0.03385892137885094,
0.04730914160609245,
0.022615043446421623,
0.007435809355229139,
-0.04629082977771759,
-0.009228465147316456,
0.06843914836645126,
0.025627553462982178,
0.04798801988363266,
0.0017382927471771836,
-0.0013604030245915055,
-0.03517424315214157,
0.01628240756690502,
-0.04259944334626198,
0.01282438449561596,
-0.04064767807722092,
-0.011922752484679222,
0.024821389466524124,
-0.02738838829100132,
-0.07781611382961273,
0.015359560027718544,
-0.02007986791431904,
0.019729822874069214,
0.0023004866670817137,
0.03305275738239288,
0.0020538638345897198,
-0.11014756560325623,
-0.0755673423409462,
0.038908056914806366,
0.007244875654578209,
-0.05630424618721008,
-0.06351729482412338,
-0.0020750786643475294,
0.10132218152284622,
0.02348485216498375,
0.046418119221925735,
0.03169500455260277,
-0.008814775384962559,
-0.019072161987423897,
-0.02838548645377159,
0.002604124369099736,
-0.028661279007792473,
-0.0946182832121849,
-0.021724019199609756,
0.031079772859811783,
-0.06474775820970535,
-0.004839640576392412,
0.009663369506597519,
0.11201447248458862,
0.0320768728852272,
-0.0023468942381441593,
-0.02887342870235443,
0.03396499529480934,
-0.01863725669682026,
-0.058128722012043,
-0.032331451773643494,
-0.018732722848653793,
0.04247215390205383,
0.035492464900016785,
-0.05541322007775307,
0.01406545378267765,
-0.025033537298440933,
0.007292609196156263,
-0.017343150451779366,
-0.02180887944996357,
-0.001523492275737226,
0.0013040510239079595,
0.03795338794589043,
-0.03880198299884796,
-0.0012888029450550675,
-0.00762674305588007,
-0.042747948318719864,
-0.04024459421634674,
0.011519670486450195,
0.05180669575929642,
-0.07433687895536423,
0.08986615389585495,
-0.0046646180562675,
0.019517673179507256,
0.020408697426319122,
-0.052655287086963654,
0.0037550306878983974,
-0.02176644839346409,
0.04548466578125954,
-0.02159672975540161,
-0.046630267053842545,
-0.01888122782111168,
0.03078276477754116,
-0.03924749419093132,
-0.05057623237371445,
0.01272891741245985,
-0.024778960272669792,
-0.017311327159404755,
-0.05015193670988083,
-0.026454932987689972,
0.03748666122555733,
-0.00800861045718193,
0.003884971607476473,
-0.02037687599658966,
-0.014436714351177216,
0.011222662404179573,
-0.03133435174822807,
0.015455027110874653,
-0.01573082059621811,
-0.010199044831097126,
-0.019708607345819473,
0.06546906381845474,
0.0020353009458631277,
0.0513823963701725,
-0.014871618710458279,
-0.018223566934466362,
0.02395157888531685,
0.024057654663920403,
-0.026497364044189453,
-0.02690044604241848,
-0.005568901542574167,
-0.0008180981385521591,
0.014595825225114822,
-0.020737528800964355,
-0.040584031492471695,
-0.08014974743127823,
0.06729354709386826,
0.003948616329580545,
-0.019984399899840355,
0.023569712415337563,
0.03154649958014488,
-0.02132093720138073,
-0.01125448476523161,
-0.008501856587827206,
0.036701712757349014,
-0.01367297861725092,
0.014447321183979511,
0.023463638499379158,
0.039650578051805496,
-0.07073035091161728,
0.005396530497819185,
0.015868717804551125,
-0.05982591211795807,
0.03313761577010155,
0.02957351878285408,
-0.02738838829100132,
0.010761238634586334,
-0.04264187440276146,
0.011318129487335682,
-0.048836614936590195,
0.043490469455718994,
-0.0557950884103775,
0.0010448319371789694,
0.08171965181827545,
0.05677097290754318,
0.016812779009342194,
-0.06075936555862427,
-0.044211775064468384,
-0.018255388364195824,
0.05235828086733818,
-0.028300626203417778,
-0.00394331244751811,
-0.022699903696775436,
0.016356658190488815,
0.02274233289062977,
-0.050279222428798676,
-0.03417714312672615,
-0.0044895950704813,
-0.00896327942609787,
-0.020238978788256645,
0.044933076947927475,
-0.037189655005931854,
-0.0069531709887087345,
0.006194740068167448,
-0.03899291902780533,
0.03617133945226669,
0.031843509525060654,
-0.0008731241687200963,
-0.04773344099521637,
0.04361775889992714,
-0.021437618881464005,
-0.08282282203435898,
0.001042843097820878,
0.07289426773786545,
0.020058652386069298,
0.04100833088159561,
0.026751941069960594,
0.043002527207136154,
0.0043013133108615875,
0.0015964184422045946,
0.011243877001106739,
-0.010883224196732044,
-0.05409789830446243,
-0.01669609732925892,
0.02056780830025673,
-0.009265591390430927,
0.05715284124016762,
-0.006449318025261164,
-0.02450316585600376,
0.005849998444318771,
-0.0050862631760537624,
-0.006083361804485321,
0.053673602640628815,
-0.06313543021678925,
-0.046842414885759354,
-0.03723208233714104,
-0.02448195219039917,
0.005913642700761557,
0.00022474494471680373,
-0.03948085755109787,
-0.025139611214399338,
0.029700808227062225,
-0.007929055020213127,
0.10098274797201157,
-0.03052818775177002,
-0.03725329786539078,
-0.051467254757881165,
-0.03256481513381004,
-0.0003483878099359572,
-0.02717623859643936,
0.023590927943587303,
-0.0040865130722522736,
-0.014967085793614388,
0.013747231103479862,
0.012134901247918606,
0.026009421795606613,
-0.04722428321838379,
0.02908557653427124,
0.05240071192383766,
-0.030888840556144714,
-0.012686488218605518,
0.04043552652001381,
-0.022211961448192596,
0.009403487667441368,
-0.011360558681190014,
-0.057577136904001236,
0.025860916823148727,
-0.004839640576392412,
0.013142607174813747,
0.03385892137885094,
-0.009594421833753586,
0.0005532438517548144,
0.012771347537636757,
-0.03180107846856117,
0.047139424830675125,
0.02424858696758747,
0.004579758271574974,
-0.007117586210370064,
0.0031504069920629263,
-0.02280597761273384,
0.020313231274485588,
-0.04141141101717949,
0.0571952685713768,
-0.033540695905685425,
0.05426761880517006,
0.03228902071714401,
0.007388075813651085,
0.010119489394128323,
0.03967179358005524,
0.05312201380729675,
-0.04480579122900963,
0.011890930123627186,
0.04020216315984726,
0.015539886429905891,
-0.04769100993871689,
-0.03345583751797676,
-0.0016269147163257003,
0.03362555801868439,
0.03288303688168526,
0.0324375256896019,
-0.014171527698636055,
-0.05015193670988083,
0.007854802533984184,
0.01886001229286194,
0.07272455096244812,
-0.013959379866719246,
-0.047648582607507706,
-0.0325435996055603,
0.003073503263294697,
0.03723208233714104,
0.028746139258146286,
-0.014171527698636055,
0.002677050419151783,
0.03385892137885094,
-0.08782953023910522,
-0.020048044621944427,
0.01188032329082489,
0.012209153734147549,
0.00025441261823289096,
0.012410694733262062,
0.04671512544155121,
0.026815585792064667,
-0.01575203612446785,
0.03494087979197502,
-0.0030788069125264883,
-0.005277196876704693,
0.01186971552670002,
-0.0348772332072258,
0.011657566763460636,
0.07947087287902832,
0.005399182438850403,
0.007377468515187502,
-0.023909149691462517,
-0.01321685966104269,
-0.04730914160609245,
0.024375876411795616,
-0.03103734366595745,
0.0016534333117306232,
0.03175864741206169,
0.07382772117853165,
0.058298442512750626,
0.011922752484679222,
0.06848157942295074,
-0.012771347537636757,
0.07446416467428207,
-0.0005147918709553778,
0.020196549594402313,
-0.025733627378940582,
0.021501263603568077,
0.006194740068167448,
0.022105887532234192,
0.02233925089240074,
-0.017109787091612816,
-0.03858983516693115,
0.001646803691983223,
-0.06271113455295563,
-0.007658565416932106,
0.0308039803057909,
-0.03763516619801521,
-0.019093375653028488,
0.02711259387433529,
-0.00545752327889204,
-0.016293013468384743,
0.011477240361273289,
0.015879323706030846,
0.013842698186635971,
0.07425201684236526,
-0.06003805994987488,
0.013057747855782509,
-0.06716625392436981,
-0.024651670828461647,
-0.018064456060528755,
-0.0848594531416893,
0.026836801320314407,
-0.004640751052647829,
0.01454278826713562,
0.02518204227089882,
-0.013185037299990654,
-0.01234705001115799,
-0.013863912783563137,
0.029403800144791603,
0.05558294057846069,
0.015295916236937046,
0.014224565587937832,
0.010485446080565453,
0.04798801988363266
]
|
32,061 | pingouin.config | set_default_options | Reset Pingouin's default global options (e.g. rounding).
.. versionadded:: 0.3.8
| def set_default_options():
"""Reset Pingouin's default global options (e.g. rounding).
.. versionadded:: 0.3.8
"""
options.clear()
# Rounding behavior
options["round"] = None
options["round.column.CI95%"] = 2
# default is to return Bayes factors inside DataFrames as formatted str
options["round.column.BF10"] = _format_bf
| () | [
-0.04948338866233826,
0.008671675808727741,
0.08253427594900131,
-0.031006120145320892,
-0.04699248820543289,
-0.04186197742819786,
-0.0798574909567833,
-0.03002091310918331,
0.020838046446442604,
-0.012621795758605003,
-0.06859267503023148,
-0.04647200182080269,
-0.0404864065349102,
0.05007822811603546,
-0.019741306081414223,
0.023124467581510544,
-0.009308341890573502,
-0.004651847295463085,
0.07725505530834198,
-0.02583843283355236,
0.05424211919307709,
-0.023923786357045174,
-0.06290449947118759,
0.014248316176235676,
0.007835179567337036,
-0.023236000910401344,
-0.011980482377111912,
-0.0101587800309062,
0.0070405080914497375,
-0.0029463248793035746,
-0.036210983991622925,
0.034389279782772064,
-0.05275501683354378,
-0.00648749154061079,
0.00476802745833993,
-0.07565642148256302,
0.03347843140363693,
0.06851831823587418,
-0.01317016500979662,
0.04219657927751541,
-0.012473084963858128,
-0.044018279761075974,
-0.017231818288564682,
-0.011385640129446983,
-0.03767949715256691,
0.009889242239296436,
0.01834714598953724,
0.054204944521188736,
0.07212454825639725,
0.02602432109415531,
0.006557199638336897,
-0.011831771582365036,
0.004026798997074366,
0.07182712852954865,
-0.08283169567584991,
-0.035077065229415894,
-0.015307877212762833,
0.0200944934040308,
-0.023793665692210197,
0.017436295747756958,
0.0242397952824831,
0.024500038474798203,
0.0017066842410713434,
-0.04792192950844765,
0.03513283282518387,
0.0013198048109188676,
-0.000695918221026659,
0.09405933320522308,
0.025708312168717384,
-0.014582914300262928,
-0.01588412933051586,
0.01747347228229046,
-0.03667570278048515,
0.016915809363126755,
-0.015465882606804371,
0.0140438387170434,
-0.05145379900932312,
0.023626364767551422,
-0.05189993232488632,
0.03576485440135002,
-0.020429091528058052,
0.04134149104356766,
-0.010261017829179764,
0.0178359542042017,
-0.01672062650322914,
-0.04234528914093971,
0.036025095731019974,
0.07532182335853577,
0.13785454630851746,
-0.035746265202760696,
-0.03375726193189621,
-0.02518782578408718,
0.05461389571428299,
0.007509875576943159,
-0.030801642686128616,
-0.0005248431698419154,
-0.008439315482974052,
0.03448222577571869,
0.035077065229415894,
-0.0807497501373291,
-0.039408259093761444,
-0.04483618587255478,
0.05193711072206497,
-0.059075210243463516,
-0.03372008353471756,
-0.021321354433894157,
0.037121836096048355,
-0.03706606850028038,
0.023849431425333023,
0.04290295019745827,
-0.08201378583908081,
-0.015995662659406662,
0.011051042005419731,
-0.015819068998098373,
0.04992951825261116,
0.0203175600618124,
-0.03500271216034889,
-0.022659748792648315,
0.047624506056308746,
0.024667339399456978,
-0.07182712852954865,
0.024425683543086052,
-0.007347223348915577,
-0.03466811403632164,
0.00589729705825448,
-0.042568352073431015,
0.03223298117518425,
0.07152970880270004,
0.009364108555018902,
-0.002245759591460228,
0.10907908529043198,
-0.013625591062009335,
-0.027734490111470222,
-0.023347534239292145,
0.014081016182899475,
-0.05327550321817398,
-0.010632794350385666,
0.045988693833351135,
0.08431880176067352,
0.06595306843519211,
-0.025317946448922157,
-0.05848036706447601,
0.026860816404223442,
-0.00881109107285738,
0.031991325318813324,
0.05156533420085907,
0.0649120956659317,
-0.08298040926456451,
-0.04502207413315773,
-0.00020680041052401066,
0.018663156777620316,
0.05193711072206497,
-0.034463636577129364,
-0.08892882615327835,
0.017993958666920662,
-0.01718534715473652,
0.013653473928570747,
-0.016925103962421417,
-0.034798234701156616,
-0.013290992937982082,
0.03896212577819824,
0.024425683543086052,
0.06717992573976517,
-0.027009528130292892,
-0.0158376581966877,
0.0162094347178936,
-0.026619162410497665,
-0.017612889409065247,
0.0634993463754654,
0.02234373800456524,
-0.003390132449567318,
-0.03810704126954079,
-0.01396948378533125,
0.036285340785980225,
0.10171791911125183,
0.032102860510349274,
0.0033576020505279303,
-0.012250019237399101,
-0.029407482594251633,
0.007193865720182657,
0.005311749875545502,
-0.02070792391896248,
0.0016300054267048836,
-0.020633568987250328,
-0.01084656547755003,
-0.014015955850481987,
0.04453876614570618,
-0.03492835536599159,
-0.08268298208713531,
-0.05048718303442001,
0.07019130885601044,
0.006887150462716818,
-0.004277747590094805,
0.007124158088117838,
0.04669506847858429,
0.02100534550845623,
0.0068174428306519985,
-0.04784757271409035,
0.0006738440133631229,
-0.03801409900188446,
0.004491519182920456,
0.010205251164734364,
0.03492835536599159,
-0.0815676599740982,
0.020503446459770203,
-0.005088684149086475,
-0.022882813587784767,
-0.01259391289204359,
0.020429091528058052,
0.026117265224456787,
0.02078227885067463,
-0.0027859965339303017,
-0.023533422499895096,
-0.02347765490412712,
-0.04710401967167854,
0.004675083328038454,
0.053721632808446884,
0.0284594539552927,
-0.026860816404223442,
0.08283169567584991,
0.009252575226128101,
-0.035894975066185,
-0.011961893178522587,
-0.028645342215895653,
-0.010223840363323689,
0.06952211260795593,
0.04212222248315811,
-0.010939509607851505,
0.05137944594025612,
-0.06152892857789993,
-0.014201844111084938,
-0.011850360780954361,
-0.09227480739355087,
0.0010891875717788935,
-0.008397490717470646,
-0.06911315768957138,
0.004777321591973305,
-0.007310045883059502,
-0.04636047035455704,
-0.045765627175569534,
0.013811479322612286,
0.008062892593443394,
-0.0049074431881308556,
0.04409263655543327,
0.009006273932754993,
-0.018560918048024178,
-0.035300131887197495,
-0.02492758259177208,
0.04316319525241852,
0.02111687697470188,
0.01417396031320095,
-0.08714430034160614,
-0.0017833630554378033,
0.04974362999200821,
0.030243977904319763,
0.0016602122923359275,
-0.03851599618792534,
0.04554256051778793,
-0.05524591729044914,
0.001459220889955759,
0.026321742683649063,
-0.004640229512006044,
-0.029295949265360832,
-0.001126946066506207,
0.03963132202625275,
0.07837038487195969,
-0.005474401637911797,
-0.023719308897852898,
0.016125785186886787,
-0.016776392236351967,
0.05695608630776405,
-0.008369607850909233,
-0.08357524871826172,
0.012547440826892853,
-0.009628999046981335,
0.02892417460680008,
-0.07301680743694305,
0.02245527133345604,
-0.006101774051785469,
-0.037921153008937836,
0.05788552388548851,
-0.024760281667113304,
0.026879405602812767,
-0.01573541946709156,
-0.010874448344111443,
0.027846023440361023,
-0.03660134971141815,
-0.023087291046977043,
-0.03645263984799385,
-0.009824180975556374,
0.017984664067626,
0.027009528130292892,
0.007193865720182657,
0.0402633436024189,
-0.017464177682995796,
-0.04223375394940376,
0.07205019146203995,
-0.04000309854745865,
0.02925877273082733,
0.025317946448922157,
-0.057253506034612656,
-0.07602819800376892,
0.030541399493813515,
0.0403376966714859,
0.04624893516302109,
0.05591511353850365,
0.06000464782118797,
-0.04937185347080231,
0.03147083893418312,
0.0019657656084746122,
-0.011618000455200672,
-0.004435752518475056,
0.026916583999991417,
-0.060376424342393875,
0.01453644223511219,
-0.044315699487924576,
-0.010511966422200203,
-0.06160328537225723,
0.01560529787093401,
-0.004421811085194349,
-0.07480133324861526,
0.0013267756439745426,
-0.029370304197072983,
-0.03429633751511574,
0.006826736964285374,
-0.003390132449567318,
0.010688560083508492,
0.028069088235497475,
-0.04074665158987045,
0.008764619939029217,
-0.011236930266022682,
0.0029230888467282057,
0.015465882606804371,
0.010130896233022213,
0.021934784948825836,
-0.003345984034240246,
0.0007522655068896711,
0.013504764065146446,
-0.014443498104810715,
0.021674541756510735,
-0.028106266632676125,
0.031006120145320892,
-0.003464487614110112,
-0.032028503715991974,
0.02990937978029251,
0.0202060267329216,
0.027715900912880898,
-0.021971963346004486,
0.00817907229065895,
-0.0031345365568995476,
0.009266517125070095,
0.024407096207141876,
-0.01499186735600233,
0.0487026572227478,
0.05208582058548927,
-0.026470452547073364,
0.025410890579223633,
0.0023317327722907066,
0.049148790538311005,
-0.013188754208385944,
-0.023310355842113495,
0.026805050671100616,
-0.012965688481926918,
0.021934784948825836,
0.06494926661252975,
0.013421114534139633,
0.028143445029854774,
0.000036868997995043173,
-0.03963132202625275,
0.010000774636864662,
0.029165828600525856,
-0.08327782899141312,
-0.01944388635456562,
-0.0717155933380127,
0.032902177423238754,
0.05368445813655853,
-0.0318240262567997,
0.023979552090168,
-0.014201844111084938,
-0.004814499523490667,
0.023087291046977043,
-0.018012547865509987,
-0.014322671107947826,
0.01278909482061863,
-0.009294399991631508,
-0.0008829680155031383,
0.009015568532049656,
0.018542328849434853,
0.05301525816321373,
-0.06245836988091469,
-0.04989233985543251,
-0.01668344810605049,
0.000423476129071787,
0.07249632477760315,
-0.03437069430947304,
0.021823251619935036,
0.003329718951135874,
0.0003804895095527172,
-0.0280876774340868,
-0.012500968761742115,
0.020410502329468727,
-0.06937340646982193,
0.04171326756477356,
-0.0018704980611801147,
-0.03448222577571869,
0.03247463330626488,
0.001769421505741775,
-0.03855317085981369,
0.03866470605134964,
-0.059075210243463516,
0.0015939896693453193,
0.05111920088529587,
-0.017873132601380348,
0.05506002902984619,
-0.0035946094430983067,
0.04134149104356766,
0.039371080696582794,
0.002451398177072406,
0.05156533420085907,
-0.03169390559196472,
-0.0007731779478490353,
0.010065835900604725,
0.012473084963858128,
0.08967237174510956,
0.10186662524938583,
0.03760514408349991,
0.00948493555188179,
-0.018263496458530426,
-0.03238169103860855,
0.014239021576941013,
-0.011218341067433357,
0.003471458563581109,
-0.047252729535102844,
0.026396097615361214,
0.013560529798269272,
0.04476183280348778,
-0.007500580977648497,
-0.03539307788014412,
-0.023384710773825645,
0.00879250280559063,
-0.013002865947782993,
-0.04301448538899422,
-0.0031205948907881975,
-0.047587331384420395,
0.017278289422392845,
-0.023384710773825645,
-0.0407838299870491,
0.005911238491535187,
-0.05015258491039276,
-0.017566416412591934,
-0.0008759972406551242,
-0.028794052079319954,
0.005623112432658672,
-0.006984741892665625,
-0.008132600225508213,
0.013672063127160072,
-0.036136627197265625,
0.0483308807015419,
-0.013857950456440449,
-0.00443342886865139,
0.02580125629901886,
-0.0010920920176431537,
-0.028831230476498604,
0.04528231918811798,
-0.02401673048734665,
0.06810936331748962,
0.04453876614570618,
0.03139648586511612,
-0.02568972297012806,
-0.01255673449486494,
-0.060302071273326874,
-0.027009528130292892,
-0.07234761118888855,
-0.006970800459384918,
-0.005469754803925753,
0.01707381382584572,
-0.039556968957185745,
0.004345132037997246,
-0.01446208730340004,
-0.02645186334848404,
-0.03561614081263542,
-0.04873983561992645,
0.03520718961954117,
0.01248237956315279,
0.013830067589879036,
-0.01893269270658493,
-0.017724420875310898,
-0.03409186005592346,
-0.013774300925433636,
-0.022659748792648315,
0.010567733086645603,
0.05338703468441963,
-0.03992874547839165,
-0.01718534715473652,
0.04483618587255478,
0.05766246095299721,
0.03539307788014412,
-0.04468747600913048,
0.006208659615367651,
-0.016506854444742203,
0.04621175676584244,
-0.019313763827085495,
-0.04684377834200859,
-0.007946711964905262,
0.020763689652085304,
-0.0203175600618124,
-0.026154441758990288,
0.025708312168717384,
-0.020652158185839653,
-0.0015312524046748877,
-0.031340718269348145,
-0.03490976616740227,
0.002299202373251319,
0.001133916899561882,
0.04234528914093971,
-0.006738440133631229,
-0.021674541756510735,
-0.042493999004364014,
0.025708312168717384,
-0.024109674617648125,
-0.027344126254320145,
-0.007672527339309454,
-0.00520486431196332,
0.024574395269155502,
0.019834250211715698,
0.02554101124405861,
0.023700721561908722,
0.04059794172644615,
0.036062274128198624,
0.029500426724553108,
0.03310665488243103,
-0.0011315932497382164,
0.0013686004094779491,
0.07309116423130035,
-0.01328169833868742,
0.02507629245519638,
0.004772674757987261,
-0.021135466173291206,
0.06810936331748962,
0.0017519944813102484,
-0.03535589948296547,
0.024574395269155502,
0.03779103234410286,
0.0027116413693875074,
0.02412826381623745,
-0.024946169927716255,
-0.004860971588641405,
0.07621408253908157,
0.012965688481926918,
-0.03414762765169144,
0.04476183280348778,
0.030392689630389214,
0.02107970044016838,
0.005646347999572754,
-0.0404864065349102,
-0.04669506847858429,
0.02489040419459343,
0.022957168519496918,
0.054056230932474136,
-0.03554178774356842,
-0.04149020463228226,
-0.02671210654079914,
0.025429479777812958,
-0.016032841056585312,
-0.02515064738690853,
0.019350942224264145,
-0.006468902807682753,
0.017315467819571495,
-0.06606459617614746,
-0.0055487570352852345,
-0.0011002246756106615,
-0.033088065683841705,
0.003297188552096486,
-0.039259545505046844,
-0.02816203236579895,
-0.0025280769914388657,
0.007035861257463694,
0.025931376963853836,
-0.0649864450097084,
-0.022120673209428787,
-0.006310897879302502,
0.006933622527867556,
-0.031266361474990845,
-0.030113857239484787,
-0.007481992244720459,
-0.04654635861515999,
0.032902177423238754,
-0.009401286020874977,
0.008629851043224335,
0.013848656788468361,
-0.027771668508648872,
0.013114399276673794,
-0.0007296104449778795,
-0.05959569662809372,
-0.060376424342393875,
0.04944621026515961,
-0.021786075085401535,
-0.037084657698869705,
0.058814965188503265,
0.031526606529951096,
0.047401443123817444,
0.024500038474798203,
-0.031229184940457344,
0.03743784502148628,
-0.0283479206264019,
0.012064131908118725,
-0.03814421966671944,
0.04372086003422737,
0.03455657884478569,
0.021246999502182007,
0.0018426148453727365,
0.009656881913542747,
0.004400898702442646,
-0.0027743785176426172,
-0.04989233985543251,
-0.011088219471275806,
0.04353497177362442,
-0.04465029761195183,
-0.02979784831404686,
-0.05111920088529587,
-0.06621330976486206,
0.05052436143159866,
-0.000695918221026659,
-0.011181163601577282,
0.003169390605762601,
-0.00784912146627903,
-0.04487336426973343,
0.008671675808727741,
-0.01284486148506403,
-0.004354426637291908,
0.013597707264125347,
-0.049185965210199356,
-0.0026442569214850664,
0.018523739650845528,
-0.06275579333305359,
0.001793819246813655,
-0.026396097615361214,
-0.005372163373976946,
-0.004349779337644577,
0.045728448778390884,
0.10164356231689453,
-0.03797692060470581,
0.09264658391475677,
0.029481837525963783,
-0.0004952172748744488,
-0.030467044562101364,
-0.07178995013237,
0.03899930417537689,
0.03766091167926788,
0.014378437772393227,
-0.014118194580078125,
-0.011218341067433357,
0.009759120643138885,
0.008457904681563377,
-0.07911393791437149,
0.020689334720373154,
0.0023398653138428926,
0.015317171812057495,
0.05758810415863991,
-0.079783134162426,
-0.08171636611223221,
0.03215862438082695,
-0.028533808887004852,
0.08283169567584991,
0.039408259093761444,
0.01235225796699524,
-0.017380528151988983,
0.024574395269155502,
-0.02096816711127758,
-0.018226319923996925,
0.01936952956020832,
0.027065293863415718,
-0.020986756309866905,
0.009926419705152512,
-0.011469289660453796,
0.011924715712666512,
-0.009215397760272026,
0.016488267108798027,
0.018616683781147003,
-0.013318875804543495,
0.007138099521398544,
0.0200944934040308,
-0.02663775160908699,
-0.00527921924367547,
-0.004036093130707741,
0.006905739661306143,
-0.01990860514342785,
0.045988693833351135,
-0.005860119592398405,
0.04498489946126938,
-0.03760514408349991,
-0.016181550920009613,
0.017538532614707947,
0.07837038487195969,
-0.0002415091876173392,
-0.02892417460680008,
-0.03862752765417099,
-0.05461389571428299,
0.016413910314440727,
-0.021414298564195633,
0.03818139806389809,
-0.022919991984963417,
-0.052531950175762177,
0.0041848039254546165,
-0.0016021222108975053,
-0.0007092789164744318,
0.027697313576936722,
-0.005228100344538689,
0.013318875804543495,
0.026990938931703568,
0.02355200983583927,
0.05268066003918648,
0.023273179307579994,
-0.014573619700968266,
-0.019276585429906845,
0.07149253040552139,
-0.027195414528250694,
-0.009889242239296436,
-0.07680892199277878,
-0.025392301380634308,
0.0043753390200436115,
0.01202695444226265,
0.00479591079056263,
0.04531949758529663,
0.08506235480308533,
0.0038083805702626705,
-0.0005483696004375815,
-0.0567701980471611,
-0.02230656147003174,
-0.01084656547755003,
-0.026953760534524918,
0.0033413369674235582,
0.03996592015028,
-0.0016753156669437885,
-0.018179846927523613,
-0.01638602837920189,
0.0403376966714859,
-0.01903493143618107,
-0.004094183444976807,
-0.022659748792648315,
-0.05461389571428299,
-0.03360855206847191,
-0.015428704209625721,
0.030095268040895462,
-0.00812330562621355,
-0.020484859123826027,
0.036173805594444275,
0.0063899001106619835,
0.02089381217956543,
0.03896212577819824,
-0.011906126514077187,
-0.03078305348753929,
0.0036480522248893976,
-0.008100070059299469,
0.014657269231975079,
0.07034002244472504,
-0.02645186334848404,
0.04509643092751503,
0.06881573796272278,
-0.021860430017113686,
-0.04059794172644615,
-0.002904500113800168,
0.020689334720373154,
0.044204168021678925,
0.04487336426973343,
-0.01657191663980484,
0.05030129477381706,
-0.006292309146374464
]
|
32,062 | pingouin.distribution | sphericity | Mauchly and JNS test for sphericity.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame containing the repeated measurements.
Both wide and long-format dataframe are supported for this function.
To test for an interaction term between two repeated measures factors
with a wide-format dataframe, ``data`` must have a two-levels
:py:class:`pandas.MultiIndex` columns.
dv : string
Name of column containing the dependent variable (only required if
``data`` is in long format).
within : string
Name of column containing the within factor (only required if ``data``
is in long format).
If ``within`` is a list with two strings, this function computes
the epsilon factor for the interaction between the two within-subject
factor.
subject : string
Name of column containing the subject identifier (only required if
``data`` is in long format).
method : str
Method to compute sphericity:
* `'jns'`: John, Nagao and Sugiura test.
* `'mauchly'`: Mauchly test (default).
alpha : float
Significance level
Returns
-------
spher : boolean
True if data have the sphericity property.
W : float
Test statistic.
chi2 : float
Chi-square statistic.
dof : int
Degrees of freedom.
pval : float
P-value.
Raises
------
ValueError
When testing for an interaction, if both within-subject factors have
more than 2 levels (not yet supported in Pingouin).
See Also
--------
epsilon : Epsilon adjustement factor for repeated measures.
homoscedasticity : Test equality of variance.
normality : Univariate normality test.
Notes
-----
The **Mauchly** :math:`W` statistic [1]_ is defined by:
.. math::
W = \frac{\prod \lambda_j}{(\frac{1}{k-1} \sum \lambda_j)^{k-1}}
where :math:`\lambda_j` are the eigenvalues of the population
covariance matrix (= double-centered sample covariance matrix) and
:math:`k` is the number of conditions.
From then, the :math:`W` statistic is transformed into a chi-square
score using the number of observations per condition :math:`n`
.. math:: f = \frac{2(k-1)^2+k+1}{6(k-1)(n-1)}
.. math:: \chi_w^2 = (f-1)(n-1) \text{log}(W)
The p-value is then approximated using a chi-square distribution:
.. math:: \chi_w^2 \sim \chi^2(\frac{k(k-1)}{2}-1)
The **JNS** :math:`V` statistic ([2]_, [3]_, [4]_) is defined by:
.. math::
V = \frac{(\sum_j^{k-1} \lambda_j)^2}{\sum_j^{k-1} \lambda_j^2}
.. math:: \chi_v^2 = \frac{n}{2} (k-1)^2 (V - \frac{1}{k-1})
and the p-value approximated using a chi-square distribution
.. math:: \chi_v^2 \sim \chi^2(\frac{k(k-1)}{2}-1)
Missing values are automatically removed from ``data`` (listwise deletion).
References
----------
.. [1] Mauchly, J. W. (1940). Significance test for sphericity of a normal
n-variate distribution. The Annals of Mathematical Statistics,
11(2), 204-209.
.. [2] Nagao, H. (1973). On some test criteria for covariance matrix.
The Annals of Statistics, 700-709.
.. [3] Sugiura, N. (1972). Locally best invariant test for sphericity and
the limiting distributions. The Annals of Mathematical Statistics,
1312-1316.
.. [4] John, S. (1972). The distribution of a statistic used for testing
sphericity of normal distributions. Biometrika, 59(1), 169-173.
See also http://www.real-statistics.com/anova-repeated-measures/sphericity/
Examples
--------
Mauchly test for sphericity using a wide-format dataframe
>>> import pandas as pd
>>> import pingouin as pg
>>> data = pd.DataFrame({'A': [2.2, 3.1, 4.3, 4.1, 7.2],
... 'B': [1.1, 2.5, 4.1, 5.2, 6.4],
... 'C': [8.2, 4.5, 3.4, 6.2, 7.2]})
>>> spher, W, chisq, dof, pval = pg.sphericity(data)
>>> print(spher, round(W, 3), round(chisq, 3), dof, round(pval, 3))
True 0.21 4.677 2 0.096
John, Nagao and Sugiura (JNS) test
>>> round(pg.sphericity(data, method='jns')[-1], 3) # P-value only
0.046
Now using a long-format dataframe
>>> data = pg.read_dataset('rm_anova2')
>>> data.head()
Subject Time Metric Performance
0 1 Pre Product 13
1 2 Pre Product 12
2 3 Pre Product 17
3 4 Pre Product 12
4 5 Pre Product 19
Let's first test sphericity for the *Time* within-subject factor
>>> pg.sphericity(data, dv='Performance', subject='Subject',
... within='Time')
(True, nan, nan, 1, 1.0)
Since *Time* has only two levels (Pre and Post), the sphericity assumption
is necessarily met.
The *Metric* factor, however, has three levels:
>>> round(pg.sphericity(data, dv='Performance', subject='Subject',
... within=['Metric'])[-1], 3)
0.878
The p-value value is very large, and the test therefore indicates that
there is no violation of sphericity.
Now, let's calculate the epsilon for the interaction between the two
repeated measures factor. The current implementation in Pingouin only works
if at least one of the two within-subject factors has no more than two
levels.
>>> spher, _, chisq, dof, pval = pg.sphericity(data, dv='Performance',
... subject='Subject',
... within=['Time', 'Metric'])
>>> print(spher, round(chisq, 3), dof, round(pval, 3))
True 3.763 2 0.152
Here again, there is no violation of sphericity acccording to Mauchly's
test.
Alternatively, we could use a wide-format dataframe with two column
levels:
>>> # Pivot from long-format to wide-format
>>> piv = data.pivot(index='Subject', columns=['Time', 'Metric'], values='Performance')
>>> piv.head()
Time Pre Post
Metric Product Client Action Product Client Action
Subject
1 13 12 17 18 30 34
2 12 19 18 6 18 30
3 17 19 24 21 31 32
4 12 25 25 18 39 40
5 19 27 19 18 28 27
>>> spher, _, chisq, dof, pval = pg.sphericity(piv)
>>> print(spher, round(chisq, 3), dof, round(pval, 3))
True 3.763 2 0.152
which gives the same output as the long-format dataframe.
| def sphericity(data, dv=None, within=None, subject=None, method="mauchly", alpha=0.05):
"""Mauchly and JNS test for sphericity.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame containing the repeated measurements.
Both wide and long-format dataframe are supported for this function.
To test for an interaction term between two repeated measures factors
with a wide-format dataframe, ``data`` must have a two-levels
:py:class:`pandas.MultiIndex` columns.
dv : string
Name of column containing the dependent variable (only required if
``data`` is in long format).
within : string
Name of column containing the within factor (only required if ``data``
is in long format).
If ``within`` is a list with two strings, this function computes
the epsilon factor for the interaction between the two within-subject
factor.
subject : string
Name of column containing the subject identifier (only required if
``data`` is in long format).
method : str
Method to compute sphericity:
* `'jns'`: John, Nagao and Sugiura test.
* `'mauchly'`: Mauchly test (default).
alpha : float
Significance level
Returns
-------
spher : boolean
True if data have the sphericity property.
W : float
Test statistic.
chi2 : float
Chi-square statistic.
dof : int
Degrees of freedom.
pval : float
P-value.
Raises
------
ValueError
When testing for an interaction, if both within-subject factors have
more than 2 levels (not yet supported in Pingouin).
See Also
--------
epsilon : Epsilon adjustement factor for repeated measures.
homoscedasticity : Test equality of variance.
normality : Univariate normality test.
Notes
-----
The **Mauchly** :math:`W` statistic [1]_ is defined by:
.. math::
W = \\frac{\\prod \\lambda_j}{(\\frac{1}{k-1} \\sum \\lambda_j)^{k-1}}
where :math:`\\lambda_j` are the eigenvalues of the population
covariance matrix (= double-centered sample covariance matrix) and
:math:`k` is the number of conditions.
From then, the :math:`W` statistic is transformed into a chi-square
score using the number of observations per condition :math:`n`
.. math:: f = \\frac{2(k-1)^2+k+1}{6(k-1)(n-1)}
.. math:: \\chi_w^2 = (f-1)(n-1) \\text{log}(W)
The p-value is then approximated using a chi-square distribution:
.. math:: \\chi_w^2 \\sim \\chi^2(\\frac{k(k-1)}{2}-1)
The **JNS** :math:`V` statistic ([2]_, [3]_, [4]_) is defined by:
.. math::
V = \\frac{(\\sum_j^{k-1} \\lambda_j)^2}{\\sum_j^{k-1} \\lambda_j^2}
.. math:: \\chi_v^2 = \\frac{n}{2} (k-1)^2 (V - \\frac{1}{k-1})
and the p-value approximated using a chi-square distribution
.. math:: \\chi_v^2 \\sim \\chi^2(\\frac{k(k-1)}{2}-1)
Missing values are automatically removed from ``data`` (listwise deletion).
References
----------
.. [1] Mauchly, J. W. (1940). Significance test for sphericity of a normal
n-variate distribution. The Annals of Mathematical Statistics,
11(2), 204-209.
.. [2] Nagao, H. (1973). On some test criteria for covariance matrix.
The Annals of Statistics, 700-709.
.. [3] Sugiura, N. (1972). Locally best invariant test for sphericity and
the limiting distributions. The Annals of Mathematical Statistics,
1312-1316.
.. [4] John, S. (1972). The distribution of a statistic used for testing
sphericity of normal distributions. Biometrika, 59(1), 169-173.
See also http://www.real-statistics.com/anova-repeated-measures/sphericity/
Examples
--------
Mauchly test for sphericity using a wide-format dataframe
>>> import pandas as pd
>>> import pingouin as pg
>>> data = pd.DataFrame({'A': [2.2, 3.1, 4.3, 4.1, 7.2],
... 'B': [1.1, 2.5, 4.1, 5.2, 6.4],
... 'C': [8.2, 4.5, 3.4, 6.2, 7.2]})
>>> spher, W, chisq, dof, pval = pg.sphericity(data)
>>> print(spher, round(W, 3), round(chisq, 3), dof, round(pval, 3))
True 0.21 4.677 2 0.096
John, Nagao and Sugiura (JNS) test
>>> round(pg.sphericity(data, method='jns')[-1], 3) # P-value only
0.046
Now using a long-format dataframe
>>> data = pg.read_dataset('rm_anova2')
>>> data.head()
Subject Time Metric Performance
0 1 Pre Product 13
1 2 Pre Product 12
2 3 Pre Product 17
3 4 Pre Product 12
4 5 Pre Product 19
Let's first test sphericity for the *Time* within-subject factor
>>> pg.sphericity(data, dv='Performance', subject='Subject',
... within='Time')
(True, nan, nan, 1, 1.0)
Since *Time* has only two levels (Pre and Post), the sphericity assumption
is necessarily met.
The *Metric* factor, however, has three levels:
>>> round(pg.sphericity(data, dv='Performance', subject='Subject',
... within=['Metric'])[-1], 3)
0.878
The p-value value is very large, and the test therefore indicates that
there is no violation of sphericity.
Now, let's calculate the epsilon for the interaction between the two
repeated measures factor. The current implementation in Pingouin only works
if at least one of the two within-subject factors has no more than two
levels.
>>> spher, _, chisq, dof, pval = pg.sphericity(data, dv='Performance',
... subject='Subject',
... within=['Time', 'Metric'])
>>> print(spher, round(chisq, 3), dof, round(pval, 3))
True 3.763 2 0.152
Here again, there is no violation of sphericity acccording to Mauchly's
test.
Alternatively, we could use a wide-format dataframe with two column
levels:
>>> # Pivot from long-format to wide-format
>>> piv = data.pivot(index='Subject', columns=['Time', 'Metric'], values='Performance')
>>> piv.head()
Time Pre Post
Metric Product Client Action Product Client Action
Subject
1 13 12 17 18 30 34
2 12 19 18 6 18 30
3 17 19 24 21 31 32
4 12 25 25 18 39 40
5 19 27 19 18 28 27
>>> spher, _, chisq, dof, pval = pg.sphericity(piv)
>>> print(spher, round(chisq, 3), dof, round(pval, 3))
True 3.763 2 0.152
which gives the same output as the long-format dataframe.
"""
assert isinstance(data, pd.DataFrame), "Data must be a pandas Dataframe."
# If data is in long-format, convert to wide-format
if all([v is not None for v in [dv, within, subject]]):
data = _long_to_wide_rm(data, dv=dv, within=within, subject=subject)
# From now on we assume that data is in wide-format and contains only
# the relevant columns.
# Remove rows with missing values in wide-format dataframe
data = data.dropna()
# Support for two-way factor of shape (2, N)
data = _check_multilevel_rm(data, func="mauchly")
# From here, we work only with one-way design
n, k = data.shape
d = k - 1
# Sphericity is always met with only two repeated measures.
if k <= 2:
return True, np.nan, np.nan, 1, 1.0
# Compute dof of the test
ddof = (d * (d + 1)) / 2 - 1
ddof = 1 if ddof == 0 else ddof
if method.lower() == "mauchly":
# Method 1. Contrast matrix. Similar to R & Matlab implementation.
# Only works for one-way design or two-way design with shape (2, N).
# 1 - Compute the successive difference matrix Z.
# (Note that the order of columns does not matter.)
# 2 - Find the contrast matrix that M so that data * M = Z
# 3 - Performs the QR decomposition of this matrix | (data, dv=None, within=None, subject=None, method='mauchly', alpha=0.05) | [
0.030617546290159225,
0.0016734017990529537,
0.04480098932981491,
0.005361255723983049,
0.032443560659885406,
-0.0014597477857023478,
-0.04356949031352997,
-0.036605168133974075,
0.03664763271808624,
0.06081043928861618,
-0.012049554847180843,
0.03836748003959656,
0.02804839052259922,
0.01816457137465477,
-0.05180777609348297,
-0.017039237543940544,
0.01898203045129776,
-0.018153954297304153,
-0.0020874394103884697,
-0.04008733108639717,
-0.03263465315103531,
0.005117079708725214,
0.019863186404109,
0.08102396875619888,
0.0035060488153249025,
0.014639943838119507,
0.011455039493739605,
-0.01901387982070446,
-0.014459465630352497,
0.01934298500418663,
-0.014395767822861671,
0.011741681024432182,
-0.027942227199673653,
-0.009703341871500015,
0.06866654008626938,
0.00233957776799798,
0.031955208629369736,
-0.07180897891521454,
-0.052614618092775345,
0.04594755172729492,
-0.037688035517930984,
0.022082002833485603,
0.017325880005955696,
-0.017028622329235077,
-0.014140975661575794,
0.017357729375362396,
0.035394903272390366,
0.10047311335802078,
-0.010605731047689915,
-0.028918931260704994,
-0.013047491200268269,
-0.021646732464432716,
-0.0072350408881902695,
0.000502949464134872,
-0.01466117613017559,
0.01423652283847332,
0.003227369626984,
0.024502530694007874,
0.08382668346166611,
-0.060725510120391846,
0.06038578599691391,
0.005050727631896734,
0.002027722541242838,
-0.0012195529416203499,
-0.01783546432852745,
-0.029831936582922935,
0.0395989790558815,
0.00994751788675785,
0.013716321438550949,
-0.04238045960664749,
-0.03813392296433449,
-0.009172524325549603,
0.03131822496652603,
-0.0025611938908696175,
0.02526690810918808,
0.050321489572525024,
0.00046413345262408257,
-0.021954607218503952,
-0.013918031938374043,
-0.0007020059856586158,
0.05851731076836586,
0.004257155582308769,
-0.02726278081536293,
-0.05197763815522194,
-0.06756243854761124,
0.04335716366767883,
0.057031020522117615,
0.03210383653640747,
0.04599002003669739,
-0.017294030636548996,
-0.021445022895932198,
-0.013833100907504559,
0.05596938729286194,
0.0023010934237390757,
0.006709531880915165,
0.021805979311466217,
-0.007532298564910889,
-0.05889949947595596,
-0.008891191333532333,
-0.007633154280483723,
0.020765576511621475,
0.06824188679456711,
0.03724214807152748,
0.04841054603457451,
0.0036599859595298767,
0.030511382967233658,
-0.04087293893098831,
0.008015342988073826,
0.020202910527586937,
0.008317908272147179,
-0.05796525999903679,
0.04286881163716316,
-0.06879393756389618,
-0.06594875454902649,
0.017761150375008583,
-0.06781723350286484,
-0.04097910225391388,
0.027963459491729736,
-0.07197883725166321,
-0.00960779469460249,
0.013907415792346,
0.02278268337249756,
-0.024035410955548286,
0.00467915553599596,
-0.004219998139888048,
-0.03204013779759407,
0.02955591306090355,
-0.009151292033493519,
-0.05223243311047554,
-0.0012759523233398795,
0.012856396846473217,
0.02526690810918808,
0.07745687663555145,
0.037157218903303146,
-0.02713538520038128,
0.02284638024866581,
0.05397351086139679,
-0.04497084766626358,
0.052614618092775345,
-0.03828255087137222,
0.031764112412929535,
0.0031397847924381495,
-0.061617281287908554,
-0.02732647955417633,
0.053166668862104416,
0.03770926594734192,
0.019884418696165085,
-0.05214750021696091,
-0.01495843380689621,
-0.011932775378227234,
0.015213226899504662,
-0.029152492061257362,
0.10828674584627151,
-0.055332403630018234,
0.013981729745864868,
-0.07231856137514114,
0.05465295910835266,
-0.0758431926369667,
0.012803315185010433,
-0.00489413645118475,
0.0040846397168934345,
-0.039747606962919235,
-0.020691262558102608,
0.055035147815942764,
-0.026498403400182724,
0.007022714242339134,
-0.02333473227918148,
-0.024226505309343338,
-0.01646595634520054,
-0.01551048457622528,
-0.013217353262007236,
0.016582734882831573,
-0.06866654008626938,
0.015404320321977139,
0.003344149561598897,
-0.0316154845058918,
-0.006051318254321814,
0.016094382852315903,
0.0296833086758852,
-0.07788152992725372,
-0.04964204132556915,
-0.03443943336606026,
-0.025542933493852615,
0.04019349440932274,
-0.03252848982810974,
0.0555022656917572,
0.03456682711839676,
-0.03609558194875717,
0.012527290731668472,
-0.006661758292466402,
-0.03010796196758747,
-0.05006669461727142,
-0.01891833171248436,
0.04471605643630028,
0.04883519932627678,
0.005220589227974415,
0.05541733652353287,
-0.009692725725471973,
-0.07342266291379929,
0.0013442951021715999,
-0.020563865080475807,
-0.011444423347711563,
-0.012877630069851875,
-0.030511382967233658,
-0.022103236988186836,
-0.039068158715963364,
-0.039726372808218,
0.02792099490761757,
0.016540270298719406,
0.021954607218503952,
0.027453875169157982,
-0.03263465315103531,
-0.0013051473069936037,
0.04964204132556915,
0.033759985119104385,
-0.04329346492886543,
0.05677622929215431,
-0.025181977078318596,
0.03792159631848335,
-0.011423190124332905,
-0.008110890164971352,
-0.026010051369667053,
-0.040660612285137177,
0.061192627996206284,
-0.050321489572525024,
0.03900446370244026,
0.026434706524014473,
0.08425133675336838,
0.004936601966619492,
-0.08773349970579147,
0.011338259093463421,
0.04153115302324295,
0.03507641330361366,
-0.04036335274577141,
-0.09461288899183273,
-0.037985291332006454,
-0.04637220874428749,
0.035585999488830566,
-0.0016097037587314844,
-0.01233619637787342,
0.01266530342400074,
-0.05465295910835266,
-0.01596698723733425,
0.038409944623708725,
-0.031105898320674896,
-0.044588662683963776,
0.02828195132315159,
0.044758521020412445,
0.04008733108639717,
-0.008668247610330582,
-0.00471365824341774,
-0.04420647397637367,
0.01596698723733425,
-0.005074614193290472,
0.013026258908212185,
-0.05448309704661369,
0.03620174527168274,
0.061192627996206284,
0.06815695017576218,
-0.03760310262441635,
-0.050873540341854095,
-0.0513831228017807,
0.025521699339151382,
0.026986755430698395,
-0.02137070894241333,
-0.013833100907504559,
-0.061192627996206284,
0.06157481670379639,
0.0057487525045871735,
0.0011525372974574566,
0.01148688793182373,
-0.017463892698287964,
-0.02860044129192829,
-0.02248542383313179,
0.006677682977169752,
0.032188765704631805,
-0.03773050010204315,
0.03758187219500542,
0.042231831699609756,
0.04015102609992027,
0.0011658077128231525,
0.03923802077770233,
0.02991686761379242,
-0.014034811407327652,
0.011837228201329708,
0.006762613542377949,
0.00006519100861623883,
-0.010255391709506512,
0.06064057722687721,
-0.017209099605679512,
-0.07202130556106567,
-0.04526810720562935,
-0.044036611914634705,
-0.02906756103038788,
0.04480098932981491,
0.02261282131075859,
-0.061192627996206284,
-0.021413173526525497,
0.03380244970321655,
-0.03983253613114357,
0.04042705148458481,
0.026094982400536537,
0.06369809061288834,
-0.004318199586123228,
-0.03643530607223511,
0.03596818819642067,
0.00962371937930584,
-0.038664739578962326,
0.006253028754144907,
-0.06136249005794525,
-0.0217635128647089,
0.02392924763262272,
-0.06692545861005783,
0.024311436340212822,
0.03201890364289284,
-0.003105281852185726,
-0.02785729616880417,
-0.04134005680680275,
0.03102096915245056,
0.02388678304851055,
0.003779419930651784,
-0.05367625504732132,
0.06560903042554855,
0.005117079708725214,
0.03989623486995697,
-0.08178834617137909,
-0.0065343622118234634,
-0.03010796196758747,
-0.0034503131173551083,
-0.01996934972703457,
-0.008063116110861301,
0.007203191984444857,
0.03692365810275078,
0.011539970524609089,
0.0048782117664813995,
-0.022082002833485603,
0.025415536016225815,
-0.012898862361907959,
0.007123569492250681,
-0.0010768957436084747,
0.03643530607223511,
-0.016179313883185387,
-0.007659695111215115,
-0.016221780329942703,
0.002890300704166293,
-0.027814831584692,
-0.013684472069144249,
-0.0435270257294178,
-0.01704985462129116,
-0.0068634687922894955,
0.008599242195487022,
0.006337959785014391,
0.03422710672020912,
0.02713538520038128,
0.040044862776994705,
0.02853674255311489,
-0.0013237259117886424,
-0.07422950118780136,
-0.04274141788482666,
0.020956670865416527,
0.06076797470450401,
0.041870877146720886,
-0.01227249763906002,
-0.0009422008879482746,
-0.02913125790655613,
-0.04148868843913078,
-0.0038802751805633307,
0.015924522653222084,
0.015436169691383839,
0.009437933564186096,
0.00354320602491498,
-0.07775413244962692,
-0.030511382967233658,
-0.007893254980444908,
0.048453010618686676,
0.036838725209236145,
0.03263465315103531,
0.01091360580176115,
-0.05006669461727142,
-0.06157481670379639,
0.020532017573714256,
-0.015351238660514355,
-0.053039275109767914,
0.0012732981704175472,
0.01803717575967312,
0.014671792276203632,
-0.012314963154494762,
0.026795661076903343,
-0.011263945139944553,
-0.008317908272147179,
-0.03584079071879387,
0.00424653897061944,
0.08926225453615189,
-0.002145829377695918,
0.011677982285618782,
0.050194092094898224,
-0.02199707180261612,
0.005807142239063978,
-0.05448309704661369,
0.04556536674499512,
-0.014650559984147549,
-0.07414457201957703,
-0.007617229595780373,
0.0009455184917896986,
-0.04841054603457451,
-0.054907750338315964,
0.00601416127756238,
-0.06225426495075226,
-0.004626073408871889,
0.016083767637610435,
-0.030808640643954277,
-0.01593513786792755,
-0.014884119853377342,
-0.01659335196018219,
-0.025840191170573235,
0.018090257421135902,
0.02660456858575344,
-0.018313199281692505,
0.00032777973683550954,
0.07325279712677002,
0.045183178037405014,
-0.08773349970579147,
-0.002736363559961319,
0.05507761240005493,
0.0746966227889061,
0.02231556363403797,
-0.04369688779115677,
-0.015988219529390335,
-0.005764676723629236,
0.02166796661913395,
0.0008745216764509678,
0.03293191269040108,
0.0035140111576765776,
-0.0020874394103884697,
0.0045331805013120174,
-0.01155058667063713,
-0.04526810720562935,
0.02130701020359993,
-0.042465392500162125,
-0.013334132730960846,
0.037157218903303146,
0.044758521020412445,
-0.06845421344041824,
-0.03467299044132233,
-0.011720447801053524,
0.035161342471838,
0.027963459491729736,
-0.008174587972462177,
-0.029810704290866852,
-0.03099973499774933,
0.07376238703727722,
0.016306709498167038,
0.022018305957317352,
0.0010742417071014643,
-0.009050436317920685,
0.034184638410806656,
0.00106163474265486,
-0.04424893856048584,
-0.0470091886818409,
-0.01227249763906002,
-0.014852270483970642,
0.03675379604101181,
-0.05469542369246483,
0.013652623631060123,
-0.020319689065217972,
0.04199827089905739,
0.0029672691598534584,
0.007702160160988569,
0.017124168574810028,
-0.018812168389558792,
0.032677117735147476,
0.043017443269491196,
-0.014225905761122704,
0.0030601623002439737,
0.05320913717150688,
0.004145683720707893,
-0.10064297914505005,
0.007505757734179497,
-0.023589525371789932,
0.012134485878050327,
-0.016306709498167038,
0.007325279992073774,
0.023525826632976532,
0.0013416409492492676,
0.059876203536987305,
-0.03046891838312149,
0.035585999488830566,
-0.024332668632268906,
0.05134065821766853,
-0.08025959134101868,
0.03337779641151428,
0.03989623486995697,
0.06955830752849579,
0.045183178037405014,
-0.0318065769970417,
0.04870780557394028,
0.0044694822281599045,
-0.019820721819996834,
0.010966687463223934,
0.006178714334964752,
0.010186385363340378,
0.020903589203953743,
-0.04849547520279884,
-0.011401957832276821,
0.05252968892455101,
-0.008785028010606766,
0.018801551312208176,
0.021975839510560036,
-0.005053381435573101,
0.028388114646077156,
-0.007882637903094292,
-0.05066121369600296,
0.04892013221979141,
-0.04858040809631348,
0.036902423948049545,
0.012410510331392288,
-0.03197643905878067,
0.0024152190890163183,
-0.04407907649874687,
0.0017132131615653634,
0.01513891201466322,
-0.027007989585399628,
-0.006815695203840733,
0.05528993904590607,
0.0014424963155761361,
0.038664739578962326,
-0.020765576511621475,
-0.0030734327156096697,
0.016667665913701057,
0.00015294176409952343,
-0.017633752897381783,
-0.04008733108639717,
-0.071214459836483,
0.06662819534540176,
0.010032448917627335,
0.012867013923823833,
-0.02117961458861828,
-0.02074434421956539,
0.11941268295049667,
-0.035331204533576965,
-0.02696552313864231,
-0.008100273087620735,
0.011805378831923008,
-0.009528172202408314,
0.031148364767432213,
0.007840173318982124,
-0.010313781909644604,
-0.008742562495172024,
0.0009249493014067411,
-0.006704223807901144,
0.048028357326984406,
-0.032740816473960876,
0.04879273474216461,
-0.035458602011203766,
0.07873083651065826,
0.0315517857670784,
0.031233295798301697,
-0.028812767937779427,
-0.045905087143182755,
-0.006571519188582897,
0.008684172295033932,
-0.07125692814588547,
0.07979246973991394,
-0.06909119337797165,
-0.02906756103038788,
-0.02271898463368416,
0.016158081591129303,
0.011370108462870121,
-0.03809145465493202,
-0.0745692253112793,
0.014119742438197136,
0.06985557079315186,
0.04235922917723656,
0.04097910225391388,
-0.033759985119104385,
-0.004103218205273151,
0.005411683116108179,
-0.02055324986577034,
-0.028451811522245407,
-0.03488532081246376,
0.006523745600134134,
-0.03263465315103531,
-0.020532017573714256,
0.044333867728710175,
-0.007941028103232384,
0.023292267695069313,
-0.030596313998103142,
0.04399414360523224,
-0.03082987479865551,
0.04819821938872337,
-0.02641347423195839,
0.007335896138101816,
-0.004703042097389698,
-0.03813392296433449,
-0.005225897300988436,
0.0097882729023695,
0.03299560770392418,
0.009613103233277798,
0.09393344819545746,
-0.007049255073070526,
-0.06887886673212051,
0.025903888046741486,
-0.017272798344492912,
-0.049174923449754715,
-0.0012122541666030884,
0.006438815034925938,
0.00015277588681783527,
-0.002877030288800597,
0.00036659574834629893,
-0.04913245886564255,
0.013440296053886414,
0.03887706622481346,
-0.05354885756969452,
-0.029534678906202316,
0.04807082191109657,
0.014523163437843323,
-0.03446066379547119,
-0.0138755664229393,
0.027899762615561485,
-0.04955711215734482,
-0.023058706894516945,
0.023738153278827667,
0.03630790859460831,
0.005332060623914003,
0.01091360580176115,
-0.03630790859460831,
0.022825147956609726,
-0.03736954554915428,
-0.05669129639863968,
-0.0830623060464859,
-0.0002990824286825955,
0.009400775656104088,
0.01135949231684208,
0.0022745525930076838,
-0.034120943397283554,
-0.019884418696165085,
-0.04214690253138542,
0.0028425271157175303,
-0.01907757669687271,
0.09724574536085129,
-0.010372172109782696,
0.00020618937560357153,
0.030256591737270355,
0.014363918453454971,
0.01513891201466322,
0.019385451450943947,
0.01402419526129961,
-0.04369688779115677,
0.006380424834787846,
-0.009867895394563675,
0.010531417094171047,
0.02490595169365406,
-0.004315545316785574,
-0.017400193959474564,
0.03371752053499222,
-0.01607315056025982,
0.00740490248426795,
-0.014448849484324455,
0.008923040702939034,
0.0024311435408890247,
0.024884719401597977,
0.021158380433917046,
-0.046584535390138626,
-0.014555012807250023,
0.06382548063993454,
0.006322035100311041,
0.058474842458963394,
0.010266008786857128,
0.00008650664676679298,
0.057158417999744415,
0.003954589366912842,
0.02156180329620838,
-0.003577709197998047,
-0.0176762193441391,
0.008737253956496716,
0.0026394894812256098,
-0.01423652283847332,
-0.01212386880069971,
-0.06989803165197372,
-0.0030309672001749277,
-0.0032937219366431236,
0.008864650502800941,
0.019204972311854362,
0.00015932816313579679,
0.00436066510155797,
0.004798589274287224,
0.06034332141280174,
-0.049302320927381516,
-0.017856696620583534,
-0.06093783676624298,
-0.05681869387626648,
-0.009045128710567951,
-0.002476263092830777,
0.032125066965818405,
0.033207934349775314,
-0.026158681139349937,
-0.010058989748358727,
0.026880592107772827,
0.029959334060549736,
-0.006682991050183773,
0.025649096816778183,
0.01750635728240013,
0.01227249763906002,
0.03165794909000397,
-0.018610456958413124,
0.04129759222269058,
0.003938665147870779,
0.0009939555311575532,
0.11134425550699234,
-0.07350759208202362,
-0.03615928068757057,
0.013918031938374043,
0.011401957832276821,
-0.010488951578736305,
0.02117961458861828,
0.019863186404109,
0.0036732563748955727,
0.0395352803170681,
0.018939564004540443,
-0.0010941473301500082,
0.05210503563284874,
-0.01353584323078394,
0.04148868843913078,
-0.04420647397637367,
-0.06921859085559845,
0.01499028317630291,
0.052444759756326675,
-0.008774411864578724,
0.06250905245542526,
-0.011370108462870121,
-0.05393104627728462,
0.033399030566215515,
0.00823297817260027,
0.018079640343785286,
-0.03288944438099861,
-0.012261881493031979,
-0.03280451521277428,
-0.03371752053499222,
-0.011985857039690018,
0.014512547291815281,
0.0012772793415933847,
0.026986755430698395,
0.013769403100013733,
-0.1251879781484604,
0.03590448945760727,
0.038409944623708725,
0.0004959824727848172,
0.028005925938487053,
0.049472179263830185,
-0.06577888876199722,
0.028430579230189323,
-0.030065497383475304,
-0.013737553730607033,
0.0053426772356033325,
0.005977003835141659,
0.05027902498841286,
0.003397231223061681,
-0.012803315185010433,
0.006433506961911917,
-0.05066121369600296,
-0.07206376641988754,
-0.0004405784420669079,
0.010234159417450428,
0.0910457968711853,
-0.042826347053050995,
0.02055324986577034,
-0.014077276922762394,
0.05168038234114647
]
|
32,063 | pingouin.equivalence | tost | Two One-Sided Test (TOST) for equivalence.
Parameters
----------
x, y : array_like
First and second set of observations. ``x`` and ``y`` should have the
same units. If ``y`` is a single value (e.g. 0), a one-sample test is
performed.
bound : float
Magnitude of region of similarity (a.k.a epsilon). Note that this
should be expressed in the same unit as ``x`` and ``y``.
paired : boolean
Specify whether the two observations are related (i.e. repeated
measures) or independent.
correction : auto or boolean
Specify whether or not to correct for unequal variances using Welch
separate variances T-test. This only applies if ``paired`` is False.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'bound'``: bound (= epsilon, or equivalence margin)
* ``'dof'``: degrees of freedom
* ``'pval'``: TOST p-value
See also
--------
ttest
References
----------
.. [1] Schuirmann, D.L. 1981. On hypothesis testing to determine if the
mean of a normal distribution is contained in a known interval.
Biometrics 37 617.
.. [2] https://cran.r-project.org/web/packages/equivalence/equivalence.pdf
Examples
--------
1. Independent two-sample TOST with a region of similarity of 1 (default)
>>> import pingouin as pg
>>> a = [4, 7, 8, 6, 3, 2]
>>> b = [6, 8, 7, 10, 11, 9]
>>> pg.tost(a, b)
bound dof pval
TOST 1 10 0.965097
2. Paired TOST with a different region of similarity
>>> pg.tost(a, b, bound=0.5, paired=True)
bound dof pval
TOST 0.5 5 0.954854
3. One sample TOST
>>> pg.tost(a, y=0, bound=4)
bound dof pval
TOST 4 5 0.825967
| def tost(x, y, bound=1, paired=False, correction=False):
"""Two One-Sided Test (TOST) for equivalence.
Parameters
----------
x, y : array_like
First and second set of observations. ``x`` and ``y`` should have the
same units. If ``y`` is a single value (e.g. 0), a one-sample test is
performed.
bound : float
Magnitude of region of similarity (a.k.a epsilon). Note that this
should be expressed in the same unit as ``x`` and ``y``.
paired : boolean
Specify whether the two observations are related (i.e. repeated
measures) or independent.
correction : auto or boolean
Specify whether or not to correct for unequal variances using Welch
separate variances T-test. This only applies if ``paired`` is False.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'bound'``: bound (= epsilon, or equivalence margin)
* ``'dof'``: degrees of freedom
* ``'pval'``: TOST p-value
See also
--------
ttest
References
----------
.. [1] Schuirmann, D.L. 1981. On hypothesis testing to determine if the
mean of a normal distribution is contained in a known interval.
Biometrics 37 617.
.. [2] https://cran.r-project.org/web/packages/equivalence/equivalence.pdf
Examples
--------
1. Independent two-sample TOST with a region of similarity of 1 (default)
>>> import pingouin as pg
>>> a = [4, 7, 8, 6, 3, 2]
>>> b = [6, 8, 7, 10, 11, 9]
>>> pg.tost(a, b)
bound dof pval
TOST 1 10 0.965097
2. Paired TOST with a different region of similarity
>>> pg.tost(a, b, bound=0.5, paired=True)
bound dof pval
TOST 0.5 5 0.954854
3. One sample TOST
>>> pg.tost(a, y=0, bound=4)
bound dof pval
TOST 4 5 0.825967
"""
x = np.asarray(x)
y = np.asarray(y)
assert isinstance(bound, (int, float)), "bound must be int or float."
# T-tests
df_a = ttest(x + bound, y, paired=paired, correction=correction, alternative="greater")
df_b = ttest(x - bound, y, paired=paired, correction=correction, alternative="less")
pval = max(df_a.at["T-test", "p-val"], df_b.at["T-test", "p-val"])
# Create output dataframe
stats = pd.DataFrame(
{"bound": bound, "dof": df_a.at["T-test", "dof"], "pval": pval}, index=["TOST"]
)
return _postprocess_dataframe(stats)
| (x, y, bound=1, paired=False, correction=False) | [
-0.01290096528828144,
0.014770813286304474,
0.042699817568063736,
-0.07055956870317459,
0.03595253452658653,
0.004531166981905699,
-0.04871499165892601,
0.02649446576833725,
0.03698144853115082,
-0.04416403919458389,
-0.007316153030842543,
0.0328855887055397,
0.008562718518078327,
0.014879640191793442,
-0.010289113037288189,
0.07463563978672028,
0.02613830380141735,
-0.03931628540158272,
-0.007434873376041651,
0.016482368111610413,
0.021745644509792328,
-0.016887996345758438,
0.031104780733585358,
-0.0013974396279081702,
-0.03043203055858612,
-0.03601189702749252,
-0.04143346846103668,
-0.0987754836678505,
0.02384304068982601,
0.010902502574026585,
0.04095858335494995,
-0.10803569108247757,
-0.02176543138921261,
0.0007518967031501234,
0.023110931739211082,
0.0032944949343800545,
0.0064702690578997135,
0.003489888971671462,
0.019044753164052963,
0.038089506328105927,
-0.06996596604585648,
-0.0639507919549942,
-0.025505129247903824,
0.008542931638658047,
-0.014127743430435658,
0.029858214780688286,
-0.010125872679054737,
0.007424980401992798,
-0.009561949409544468,
0.023546239361166954,
0.00963120348751545,
-0.03706059232354164,
-0.03624933585524559,
0.015512816607952118,
0.0022136433981359005,
-0.005718372296541929,
-0.0142365712672472,
0.010239645838737488,
0.03617018833756447,
-0.040800292044878006,
0.07677261531352997,
0.06153681129217148,
0.011199303902685642,
0.004531166981905699,
-0.0075239138677716255,
0.022537115961313248,
-0.0396922342479229,
-0.020380359143018723,
0.00288144638761878,
0.027820179238915443,
-0.03154008835554123,
0.007944382727146149,
-0.0326877199113369,
0.03183688968420029,
-0.006213041488081217,
0.058291781693696976,
0.014454225078225136,
-0.009596576914191246,
-0.021983085200190544,
-0.024753231555223465,
-0.035675521939992905,
0.019024966284632683,
0.023486878722906113,
-0.003895517671480775,
-0.031737957149744034,
0.04357043653726578,
0.0009831544011831284,
0.061022356152534485,
0.044995084404945374,
-0.029739493504166603,
-0.032905373722314835,
-0.005634278990328312,
0.05385955050587654,
-0.04004839435219765,
0.0553237684071064,
-0.009992311708629131,
-0.02419920265674591,
0.010566127486526966,
-0.05939984321594238,
-0.014127743430435658,
-0.006069587543606758,
0.06300102919340134,
0.0038608908653259277,
0.08152143657207489,
0.02805761992931366,
0.017184797674417496,
-0.026632973924279213,
0.023625386878848076,
-0.03233155980706215,
-0.01386062242090702,
-0.06735412031412125,
0.0035146225709468126,
0.010585914365947247,
-0.03037266992032528,
-0.011792906560003757,
-0.02651425264775753,
0.02380346693098545,
0.02538640797138214,
-0.05880624055862427,
-0.048121389001607895,
0.04681546613574028,
0.02382325381040573,
-0.0033192283008247614,
-0.006262508220970631,
0.0039054108783602715,
-0.008181823417544365,
0.04175005480647087,
0.019608674570918083,
-0.03157966211438179,
-0.031104780733585358,
0.028789730742573738,
-0.00573321245610714,
-0.01719469018280506,
0.10953947901725769,
-0.030709045007824898,
0.0037866905331611633,
-0.0016521940706297755,
0.03678357973694801,
0.022279886528849602,
-0.0013257126556709409,
0.03266793489456177,
-0.016472473740577698,
-0.031441155821084976,
-0.015077508054673672,
0.030174802988767624,
0.021270763128995895,
-0.05718372389674187,
0.00845389161258936,
0.0730922743678093,
0.06319890171289444,
-0.028651222586631775,
-0.032905373722314835,
0.006890737917274237,
-0.04942731559276581,
-0.023190077394247055,
-0.04046391695737839,
0.06901620328426361,
-0.05896453186869621,
0.0404045544564724,
-0.00508519634604454,
-0.011456531472504139,
-0.055165477097034454,
-0.011387278325855732,
0.03472575545310974,
0.033004309982061386,
0.02809719368815422,
-0.032193053513765335,
0.03183688968420029,
0.025188541039824486,
-0.04554911330342293,
-0.014968681149184704,
0.02376389317214489,
-0.019212940707802773,
-0.02459493838250637,
0.012307362630963326,
-0.0819171667098999,
0.035675521939992905,
0.005471038166433573,
-0.010853035375475883,
-0.07281526178121567,
0.03183688968420029,
-0.023724321275949478,
-0.05726287141442299,
0.005213810130953789,
-0.030174802988767624,
0.022438181564211845,
0.0040364982560276985,
-0.007949328981339931,
-0.022359034046530724,
0.02140926942229271,
0.024753231555223465,
-0.009824124164879322,
-0.010744208469986916,
0.03260857239365578,
0.054769739508628845,
0.009532270021736622,
-0.005846986547112465,
0.0007865235675126314,
0.012178747914731503,
0.050851963460445404,
-0.004793341737240553,
-0.03662528470158577,
0.026019584387540817,
0.005624385550618172,
0.04594484716653824,
0.02374410629272461,
-0.0675124078989029,
-0.011802799999713898,
-0.052078742533922195,
-0.0229922104626894,
0.03812908008694649,
-0.06034960597753525,
-0.0371001660823822,
-0.004167585633695126,
0.023269224911928177,
0.034112367779016495,
0.03702101856470108,
-0.03078819252550602,
-0.00029401882784441113,
-0.04357043653726578,
0.05188087373971939,
-0.06834345310926437,
0.04024626314640045,
0.04515337571501732,
0.027483804151415825,
0.05686713755130768,
0.026316385716199875,
0.024733444675803185,
0.023506665602326393,
-0.027008922770619392,
0.061774253845214844,
-0.0029284399934113026,
-0.006074534263461828,
-0.05366168171167374,
0.01681874319911003,
-0.08991102129220963,
-0.008750692941248417,
-0.0490315817296505,
-0.0013887829845771194,
-0.019420700147747993,
-0.007321099750697613,
-0.006757176946848631,
-0.012980111874639988,
-0.005475984886288643,
-0.03812908008694649,
-0.0793844684958458,
0.004553426988422871,
-0.07831598073244095,
0.025050032883882523,
-0.003967244643718004,
0.018935926258563995,
-0.02653403952717781,
0.02417941577732563,
-0.0436495840549469,
0.03597232326865196,
-0.036486778408288956,
-0.009784550406038761,
0.0037199100479483604,
0.023486878722906113,
-0.0012626423267647624,
0.014286037534475327,
0.010655168443918228,
-0.028176341205835342,
0.026613187044858932,
-0.0513664186000824,
-0.0057876259088516235,
-0.05496760830283165,
-0.022418394684791565,
0.04143346846103668,
0.009062333963811398,
-0.11729589104652405,
-0.021943511441349983,
-0.08152143657207489,
-0.011743439361453056,
-0.026632973924279213,
0.030926698818802834,
0.04614271596074104,
0.008171929977834225,
0.03745632991194725,
-0.0436495840549469,
-0.026593400165438652,
-0.008968346752226353,
-0.019371233880519867,
0.016878101974725723,
0.008612185716629028,
0.0007821951876394451,
-0.04277896508574486,
-0.012920751236379147,
0.10399919003248215,
-0.03975159302353859,
-0.026791267096996307,
0.01424646470695734,
-0.010056618601083755,
-0.004607840906828642,
0.0002739228948485106,
0.04083986580371857,
-0.0749126598238945,
-0.040800292044878006,
0.04562826082110405,
-0.050851963460445404,
0.004815601743757725,
-0.014830173924565315,
-0.019806543365120888,
0.08413328975439072,
-0.021132254973053932,
0.04175005480647087,
0.01623503305017948,
-0.0515642873942852,
-0.021250976249575615,
-0.02968013472855091,
-0.017125437036156654,
-0.027404656633734703,
0.03272729367017746,
-0.008676492609083652,
0.03003629483282566,
0.009101907722651958,
-0.05184129998087883,
-0.02453557774424553,
0.000042008210584754124,
0.029007384553551674,
-0.03193582594394684,
-0.0043481397442519665,
0.07447735220193863,
-0.009408602491021156,
0.08999016880989075,
0.027365082874894142,
-0.022457968443632126,
0.003190614515915513,
0.02570299617946148,
0.04942731559276581,
-0.013989236205816269,
0.004417393356561661,
0.07495222985744476,
0.03820822760462761,
-0.009413548745214939,
0.01596791297197342,
0.022082019597291946,
-0.006539522670209408,
0.011743439361453056,
-0.018579764291644096,
0.03037266992032528,
0.004630100913345814,
0.001637354027479887,
-0.0420270711183548,
0.03302409499883652,
0.012772350572049618,
-0.06308017671108246,
-0.025129180401563644,
0.046578023582696915,
-0.01954931579530239,
-0.029739493504166603,
0.05496760830283165,
0.0034799957647919655,
0.04022647440433502,
0.006396068725734949,
0.06632520258426666,
0.00809772964566946,
0.024436643347144127,
0.031777530908584595,
0.00965099036693573,
-0.02301199734210968,
0.02146863006055355,
0.0016002538613975048,
-0.04998134449124336,
-0.014968681149184704,
0.0043481397442519665,
0.025228112936019897,
0.013534140773117542,
-0.06383207440376282,
0.021983085200190544,
0.009042547084391117,
-0.06604818999767303,
-0.005510611459612846,
0.024753231555223465,
0.020756306126713753,
-0.018243389204144478,
0.008721012622117996,
-0.0229922104626894,
-0.003967244643718004,
-0.037258461117744446,
0.033380258828401566,
0.008236236870288849,
-0.027068281546235085,
0.06917449831962585,
-0.008829839527606964,
-0.038049932569265366,
0.005154449958354235,
-0.0059854937717318535,
0.01249533612281084,
-0.019420700147747993,
-0.02653403952717781,
-0.03245028108358383,
-0.01630428619682789,
0.03399364650249481,
0.0061586275696754456,
-0.004657307639718056,
-0.02774103172123432,
0.01013081893324852,
0.015324842184782028,
0.04281853884458542,
0.00760800763964653,
-0.02297242358326912,
-0.010576020926237106,
-0.02884908951818943,
-0.038049932569265366,
-0.006495002657175064,
0.01875784434378147,
-0.03357812389731407,
-0.01928219385445118,
-0.014355291612446308,
-0.054809313267469406,
0.020380359143018723,
-0.010427620261907578,
0.009774657897651196,
-0.004442126490175724,
0.048912860453128815,
-0.06280316412448883,
0.07803896814584732,
-0.0031139408238232136,
0.00624766806140542,
0.05184129998087883,
-0.037199102342128754,
0.004264045972377062,
-0.000919465790502727,
0.07135104387998581,
-0.012406296096742153,
-0.010081351734697819,
-0.011743439361453056,
0.00878531951457262,
0.04471806809306145,
0.02457515150308609,
0.003037267131730914,
-0.043055981397628784,
-0.0005840184749104083,
0.018975498154759407,
0.00761790107935667,
-0.018431363627314568,
0.006272401660680771,
0.07503137737512589,
0.019578995183110237,
0.0022433234844356775,
0.04052327573299408,
0.012109494768083096,
0.014266250655055046,
-0.03470597043633461,
-0.04178962856531143,
-0.0075239138677716255,
-0.04412446543574333,
-0.007865235209465027,
-0.048912860453128815,
0.03662528470158577,
-0.04792352393269539,
0.05290978401899338,
0.03630869835615158,
-0.04998134449124336,
-0.050851963460445404,
-0.01538420282304287,
-0.053542960435152054,
-0.08896125853061676,
0.04376830533146858,
-0.004350612871348858,
-0.0256832093000412,
-0.0057876259088516235,
0.014533372595906258,
-0.017066076397895813,
-0.036071255803108215,
0.008216449990868568,
-0.027107855305075645,
-0.009101907722651958,
-0.012277682311832905,
-0.01800594851374626,
0.005708479322493076,
-0.023110931739211082,
0.013563821092247963,
0.07843469828367233,
0.059914298355579376,
-0.07071786373853683,
-0.02495109848678112,
0.010125872679054737,
-0.004283832851797342,
-0.042264509946107864,
0.003400848712772131,
0.019104113802313805,
0.04479721561074257,
0.019569100812077522,
-0.028631435707211494,
-0.03828737139701843,
-0.027444230392575264,
0.026751693338155746,
-0.042660247534513474,
0.0476069338619709,
-0.02338794618844986,
0.011001436039805412,
0.004239312373101711,
-0.07558540999889374,
0.06640435010194778,
-0.0064554293639957905,
-0.033775992691516876,
-0.013494567945599556,
0.023467091843485832,
0.07479393482208252,
0.002161703072488308,
-0.01148621179163456,
0.004019184969365597,
0.06846217811107635,
0.0012150304391980171,
-0.04250195249915123,
-0.014266250655055046,
-0.0546114481985569,
0.03751568868756294,
0.018629230558872223,
-0.014642199501395226,
0.04258110001683235,
0.01035836711525917,
0.0276618842035532,
-0.008923826739192009,
0.03470597043633461,
-0.037634409964084625,
-0.001371469465084374,
-0.04281853884458542,
-0.03854459896683693,
0.02150820381939411,
0.02413984201848507,
0.04206664487719536,
0.03494340926408768,
-0.046934183686971664,
0.007385406643152237,
0.05848965048789978,
0.007499180734157562,
-0.01623503305017948,
0.037950996309518814,
-0.011426851153373718,
0.009136534295976162,
-0.011743439361453056,
-0.008345064707100391,
0.03739696741104126,
-0.0023620440624654293,
-0.05611523985862732,
0.12521059811115265,
-0.03347919136285782,
0.014503692276775837,
-0.014661986380815506,
-0.00525833060964942,
0.004761188291013241,
0.01896560564637184,
0.016205353662371635,
-0.04681546613574028,
-0.027028707787394524,
-0.013098832219839096,
0.01769925281405449,
-0.0019279720727354288,
-0.039652660489082336,
0.0898318737745285,
0.026791267096996307,
-0.060982782393693924,
0.005777732934802771,
0.009769710712134838,
0.05409698933362961,
0.0027726192492991686,
0.012920751236379147,
-0.023150503635406494,
-0.0343102365732193,
0.06308017671108246,
0.003957351204007864,
0.010041778907179832,
0.03868310898542404,
0.05453230068087578,
-0.0011834953911602497,
-0.009878537617623806,
-0.03990988805890083,
0.03229198604822159,
0.03480490297079086,
-0.009448176249861717,
-0.002042982494458556,
-0.011149836704134941,
0.003999398089945316,
-0.024773018434643745,
-0.024357495829463005,
-0.02928439900279045,
-0.026751693338155746,
-0.004340719431638718,
0.011773119680583477,
0.015542496927082539,
-0.004283832851797342,
-0.02148841693997383,
0.03211390599608421,
-0.06272401660680771,
0.037990570068359375,
0.000013767640666628722,
-0.03227219730615616,
-0.027365082874894142,
-0.018797418102622032,
0.029739493504166603,
-0.03862374648451805,
0.053186800330877304,
-0.05302850529551506,
-0.062169987708330154,
-0.019757075235247612,
0.0693327933549881,
-0.042699817568063736,
-0.021270763128995895,
0.036031682044267654,
-0.013791369274258614,
-0.07281526178121567,
0.02109268121421337,
-0.00963120348751545,
0.017639892175793648,
-0.037634409964084625,
-0.03737718239426613,
-0.01283171121031046,
0.07384417206048965,
0.029343759641051292,
-0.01017039269208908,
-0.0765351727604866,
0.03436959534883499,
-0.007860288955271244,
0.00001791242539184168,
0.013148299418389797,
-0.02764209732413292,
-0.04523252323269844,
0.051247697323560715,
0.03229198604822159,
0.010259432718157768,
0.04301640763878822,
0.0069946181029081345,
-0.015107188373804092,
0.05231618136167526,
-0.03003629483282566,
-0.008166983723640442,
-0.08848637342453003,
-0.0151764415204525,
-0.025544701144099236,
0.03711995482444763,
-0.04396617040038109,
-0.01148621179163456,
-0.04562826082110405,
0.035339146852493286,
0.002327417256310582,
0.0035467760171741247,
0.09640107303857803,
-0.031797315925359726,
-0.01542377658188343,
0.09070248901844025,
0.053226374089717865,
0.008607238531112671,
-0.031441155821084976,
0.021330123767256737,
0.004160165321081877,
-0.03322196379303932,
-0.01035836711525917,
0.028948023915290833,
0.06347591429948807,
-0.0021109995432198048,
-0.04875456541776657,
0.007133125327527523,
-0.015285269357264042,
0.02067716047167778,
-0.0037545368541032076,
-0.009314615279436111,
0.03884140029549599,
0.05184129998087883,
0.027444230392575264,
-0.026336172595620155,
0.06276358664035797,
0.04337256774306297,
0.06976810097694397,
0.034112367779016495,
0.07230080664157867,
-0.03745632991194725,
0.03280644118785858,
0.050931110978126526,
0.03650656342506409,
-0.01694735698401928,
0.004390186630189419,
0.025960223749279976,
-0.05112897604703903,
0.027543164789676666,
0.034884050488471985,
-0.0569462850689888,
-0.018480829894542694,
0.010942076332867146,
0.041314747184515,
0.04392659664154053,
-0.052395328879356384,
0.022299673408269882,
0.006321868393570185,
0.0031782477162778378,
-0.00874574575573206,
-0.03262836113572121,
-0.06280316412448883,
-0.008562718518078327,
-0.04717162624001503,
0.021607138216495514,
0.0029828534461557865,
-0.010704634711146355,
-0.012366722337901592,
-0.019420700147747993,
-0.0002244560164399445,
0.0031609341967850924,
-0.06125979498028755,
0.04357043653726578,
-0.0233483724296093,
0.023249438032507896,
0.006836323998868465,
0.04729034751653671,
0.022319460287690163,
-0.008582505397498608,
-0.014929107390344143,
0.048517126590013504,
-0.07570412755012512,
-0.02528747357428074,
-0.010477087460458279,
0.016670342534780502,
0.030649684369564056,
-0.014661986380815506,
-0.01711554452776909,
0.004390186630189419,
0.046617597341537476,
-0.013603394851088524,
0.009324508719146252,
-0.00345278880558908,
-0.07051999866962433,
0.03118392825126648,
-0.05781690031290054,
0.0007469500415027142,
0.042304083704948425,
0.0765351727604866,
0.023961761966347694,
-0.051247697323560715,
-0.0192624069750309,
-0.04606356844305992,
0.014711452648043633,
0.022359034046530724,
0.03183688968420029,
-0.057144150137901306,
0.011773119680583477,
-0.02005387656390667,
-0.03975159302353859,
0.07241952419281006,
0.0008186770137399435,
0.058687519282102585,
0.01984611712396145,
0.05718372389674187,
-0.07685176283121109,
-0.0142365712672472,
0.02261626161634922,
-0.016878101974725723,
-0.046617597341537476,
-0.011248771101236343,
-0.011159730143845081,
0.06165553256869316,
0.005213810130953789,
-0.009522376582026482,
-0.03929649665951729,
0.040721144527196884,
0.05342424288392067,
0.030709045007824898,
-0.008780373260378838,
-0.025129180401563644,
-0.02886887639760971,
-0.01542377658188343,
-0.004761188291013241,
0.04602399468421936,
0.06169510632753372,
-0.009136534295976162,
0.07657474279403687,
-0.04495551064610481,
0.09837975353002548
]
|
32,064 | pingouin.parametric | ttest | T-test.
Parameters
----------
x : array_like
First set of observations.
y : array_like or float
Second set of observations. If ``y`` is a single value, a one-sample
T-test is computed against that value (= "mu" in the t.test R
function).
paired : boolean
Specify whether the two observations are related (i.e. repeated
measures) or independent.
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of
"two-sided" (default), "greater" or "less". Both "greater" and "less" return one-sided
p-values. "greater" tests against the alternative hypothesis that the mean of ``x``
is greater than the mean of ``y``.
correction : string or boolean
For unpaired two sample T-tests, specify whether or not to correct for
unequal variances using Welch separate variances T-test. If 'auto', it
will automatically uses Welch T-test when the sample sizes are unequal,
as recommended by Zimmerman 2004.
r : float
Cauchy scale factor for computing the Bayes Factor.
Smaller values of r (e.g. 0.5), may be appropriate when small effect
sizes are expected a priori; larger values of r are appropriate when
large effect sizes are expected (Rouder et al 2009).
The default is 0.707 (= :math:`\sqrt{2} / 2`).
confidence : float
Confidence level for the confidence intervals (0.95 = 95%)
.. versionadded:: 0.3.9
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'T'``: T-value
* ``'dof'``: degrees of freedom
* ``'alternative'``: alternative of the test
* ``'p-val'``: p-value
* ``'CI95%'``: confidence intervals of the difference in means
* ``'cohen-d'``: Cohen d effect size
* ``'BF10'``: Bayes Factor of the alternative hypothesis
* ``'power'``: achieved power of the test ( = 1 - type II error)
See also
--------
mwu, wilcoxon, anova, rm_anova, pairwise_tests, compute_effsize
Notes
-----
Missing values are automatically removed from the data. If ``x`` and
``y`` are paired, the entire row is removed (= listwise deletion).
The **T-value for unpaired samples** is defined as:
.. math::
t = \frac{\overline{x} - \overline{y}}
{\sqrt{\frac{s^{2}_{x}}{n_{x}} + \frac{s^{2}_{y}}{n_{y}}}}
where :math:`\overline{x}` and :math:`\overline{y}` are the sample means,
:math:`n_{x}` and :math:`n_{y}` are the sample sizes, and
:math:`s^{2}_{x}` and :math:`s^{2}_{y}` are the sample variances.
The degrees of freedom :math:`v` are :math:`n_x + n_y - 2` when the sample
sizes are equal. When the sample sizes are unequal or when
:code:`correction=True`, the Welch–Satterthwaite equation is used to
approximate the adjusted degrees of freedom:
.. math::
v = \frac{(\frac{s^{2}_{x}}{n_{x}} + \frac{s^{2}_{y}}{n_{y}})^{2}}
{\frac{(\frac{s^{2}_{x}}{n_{x}})^{2}}{(n_{x}-1)} +
\frac{(\frac{s^{2}_{y}}{n_{y}})^{2}}{(n_{y}-1)}}
The p-value is then calculated using a T distribution with :math:`v`
degrees of freedom.
The T-value for **paired samples** is defined by:
.. math:: t = \frac{\overline{x}_d}{s_{\overline{x}}}
where
.. math:: s_{\overline{x}} = \frac{s_d}{\sqrt n}
where :math:`\overline{x}_d` is the sample mean of the differences
between the two paired samples, :math:`n` is the number of observations
(sample size), :math:`s_d` is the sample standard deviation of the
differences and :math:`s_{\overline{x}}` is the estimated standard error
of the mean of the differences. The p-value is then calculated using a
T-distribution with :math:`n-1` degrees of freedom.
The scaled Jeffrey-Zellner-Siow (JZS) Bayes Factor is approximated
using the :py:func:`pingouin.bayesfactor_ttest` function.
Results have been tested against JASP and the `t.test` R function.
References
----------
* https://www.itl.nist.gov/div898/handbook/eda/section3/eda353.htm
* Delacre, M., Lakens, D., & Leys, C. (2017). Why psychologists should
by default use Welch’s t-test instead of Student’s t-test.
International Review of Social Psychology, 30(1).
* Zimmerman, D. W. (2004). A note on preliminary tests of equality of
variances. British Journal of Mathematical and Statistical
Psychology, 57(1), 173-181.
* Rouder, J.N., Speckman, P.L., Sun, D., Morey, R.D., Iverson, G.,
2009. Bayesian t tests for accepting and rejecting the null
hypothesis. Psychon. Bull. Rev. 16, 225–237.
https://doi.org/10.3758/PBR.16.2.225
Examples
--------
1. One-sample T-test.
>>> from pingouin import ttest
>>> x = [5.5, 2.4, 6.8, 9.6, 4.2]
>>> ttest(x, 4).round(2)
T dof alternative p-val CI95% cohen-d BF10 power
T-test 1.4 4 two-sided 0.23 [2.32, 9.08] 0.62 0.766 0.19
2. One sided paired T-test.
>>> pre = [5.5, 2.4, 6.8, 9.6, 4.2]
>>> post = [6.4, 3.4, 6.4, 11., 4.8]
>>> ttest(pre, post, paired=True, alternative='less').round(2)
T dof alternative p-val CI95% cohen-d BF10 power
T-test -2.31 4 less 0.04 [-inf, -0.05] 0.25 3.122 0.12
Now testing the opposite alternative hypothesis
>>> ttest(pre, post, paired=True, alternative='greater').round(2)
T dof alternative p-val CI95% cohen-d BF10 power
T-test -2.31 4 greater 0.96 [-1.35, inf] 0.25 0.32 0.02
3. Paired T-test with missing values.
>>> import numpy as np
>>> pre = [5.5, 2.4, np.nan, 9.6, 4.2]
>>> post = [6.4, 3.4, 6.4, 11., 4.8]
>>> ttest(pre, post, paired=True).round(3)
T dof alternative p-val CI95% cohen-d BF10 power
T-test -5.902 3 two-sided 0.01 [-1.5, -0.45] 0.306 7.169 0.073
Compare with SciPy
>>> from scipy.stats import ttest_rel
>>> np.round(ttest_rel(pre, post, nan_policy="omit"), 3)
array([-5.902, 0.01 ])
4. Independent two-sample T-test with equal sample size.
>>> np.random.seed(123)
>>> x = np.random.normal(loc=7, size=20)
>>> y = np.random.normal(loc=4, size=20)
>>> ttest(x, y)
T dof alternative p-val CI95% cohen-d BF10 power
T-test 9.106452 38 two-sided 4.306971e-11 [2.64, 4.15] 2.879713 1.366e+08 1.0
5. Independent two-sample T-test with unequal sample size. A Welch's T-test is used.
>>> np.random.seed(123)
>>> y = np.random.normal(loc=6.5, size=15)
>>> ttest(x, y)
T dof alternative p-val CI95% cohen-d BF10 power
T-test 1.996537 31.567592 two-sided 0.054561 [-0.02, 1.65] 0.673518 1.469 0.481867
6. However, the Welch's correction can be disabled:
>>> ttest(x, y, correction=False)
T dof alternative p-val CI95% cohen-d BF10 power
T-test 1.971859 33 two-sided 0.057056 [-0.03, 1.66] 0.673518 1.418 0.481867
Compare with SciPy
>>> from scipy.stats import ttest_ind
>>> np.round(ttest_ind(x, y, equal_var=True), 6) # T value and p-value
array([1.971859, 0.057056])
| def ttest(x, y, paired=False, alternative="two-sided", correction="auto", r=0.707, confidence=0.95):
"""T-test.
Parameters
----------
x : array_like
First set of observations.
y : array_like or float
Second set of observations. If ``y`` is a single value, a one-sample
T-test is computed against that value (= "mu" in the t.test R
function).
paired : boolean
Specify whether the two observations are related (i.e. repeated
measures) or independent.
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of
"two-sided" (default), "greater" or "less". Both "greater" and "less" return one-sided
p-values. "greater" tests against the alternative hypothesis that the mean of ``x``
is greater than the mean of ``y``.
correction : string or boolean
For unpaired two sample T-tests, specify whether or not to correct for
unequal variances using Welch separate variances T-test. If 'auto', it
will automatically uses Welch T-test when the sample sizes are unequal,
as recommended by Zimmerman 2004.
r : float
Cauchy scale factor for computing the Bayes Factor.
Smaller values of r (e.g. 0.5), may be appropriate when small effect
sizes are expected a priori; larger values of r are appropriate when
large effect sizes are expected (Rouder et al 2009).
The default is 0.707 (= :math:`\\sqrt{2} / 2`).
confidence : float
Confidence level for the confidence intervals (0.95 = 95%)
.. versionadded:: 0.3.9
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'T'``: T-value
* ``'dof'``: degrees of freedom
* ``'alternative'``: alternative of the test
* ``'p-val'``: p-value
* ``'CI95%'``: confidence intervals of the difference in means
* ``'cohen-d'``: Cohen d effect size
* ``'BF10'``: Bayes Factor of the alternative hypothesis
* ``'power'``: achieved power of the test ( = 1 - type II error)
See also
--------
mwu, wilcoxon, anova, rm_anova, pairwise_tests, compute_effsize
Notes
-----
Missing values are automatically removed from the data. If ``x`` and
``y`` are paired, the entire row is removed (= listwise deletion).
The **T-value for unpaired samples** is defined as:
.. math::
t = \\frac{\\overline{x} - \\overline{y}}
{\\sqrt{\\frac{s^{2}_{x}}{n_{x}} + \\frac{s^{2}_{y}}{n_{y}}}}
where :math:`\\overline{x}` and :math:`\\overline{y}` are the sample means,
:math:`n_{x}` and :math:`n_{y}` are the sample sizes, and
:math:`s^{2}_{x}` and :math:`s^{2}_{y}` are the sample variances.
The degrees of freedom :math:`v` are :math:`n_x + n_y - 2` when the sample
sizes are equal. When the sample sizes are unequal or when
:code:`correction=True`, the Welch–Satterthwaite equation is used to
approximate the adjusted degrees of freedom:
.. math::
v = \\frac{(\\frac{s^{2}_{x}}{n_{x}} + \\frac{s^{2}_{y}}{n_{y}})^{2}}
{\\frac{(\\frac{s^{2}_{x}}{n_{x}})^{2}}{(n_{x}-1)} +
\\frac{(\\frac{s^{2}_{y}}{n_{y}})^{2}}{(n_{y}-1)}}
The p-value is then calculated using a T distribution with :math:`v`
degrees of freedom.
The T-value for **paired samples** is defined by:
.. math:: t = \\frac{\\overline{x}_d}{s_{\\overline{x}}}
where
.. math:: s_{\\overline{x}} = \\frac{s_d}{\\sqrt n}
where :math:`\\overline{x}_d` is the sample mean of the differences
between the two paired samples, :math:`n` is the number of observations
(sample size), :math:`s_d` is the sample standard deviation of the
differences and :math:`s_{\\overline{x}}` is the estimated standard error
of the mean of the differences. The p-value is then calculated using a
T-distribution with :math:`n-1` degrees of freedom.
The scaled Jeffrey-Zellner-Siow (JZS) Bayes Factor is approximated
using the :py:func:`pingouin.bayesfactor_ttest` function.
Results have been tested against JASP and the `t.test` R function.
References
----------
* https://www.itl.nist.gov/div898/handbook/eda/section3/eda353.htm
* Delacre, M., Lakens, D., & Leys, C. (2017). Why psychologists should
by default use Welch’s t-test instead of Student’s t-test.
International Review of Social Psychology, 30(1).
* Zimmerman, D. W. (2004). A note on preliminary tests of equality of
variances. British Journal of Mathematical and Statistical
Psychology, 57(1), 173-181.
* Rouder, J.N., Speckman, P.L., Sun, D., Morey, R.D., Iverson, G.,
2009. Bayesian t tests for accepting and rejecting the null
hypothesis. Psychon. Bull. Rev. 16, 225–237.
https://doi.org/10.3758/PBR.16.2.225
Examples
--------
1. One-sample T-test.
>>> from pingouin import ttest
>>> x = [5.5, 2.4, 6.8, 9.6, 4.2]
>>> ttest(x, 4).round(2)
T dof alternative p-val CI95% cohen-d BF10 power
T-test 1.4 4 two-sided 0.23 [2.32, 9.08] 0.62 0.766 0.19
2. One sided paired T-test.
>>> pre = [5.5, 2.4, 6.8, 9.6, 4.2]
>>> post = [6.4, 3.4, 6.4, 11., 4.8]
>>> ttest(pre, post, paired=True, alternative='less').round(2)
T dof alternative p-val CI95% cohen-d BF10 power
T-test -2.31 4 less 0.04 [-inf, -0.05] 0.25 3.122 0.12
Now testing the opposite alternative hypothesis
>>> ttest(pre, post, paired=True, alternative='greater').round(2)
T dof alternative p-val CI95% cohen-d BF10 power
T-test -2.31 4 greater 0.96 [-1.35, inf] 0.25 0.32 0.02
3. Paired T-test with missing values.
>>> import numpy as np
>>> pre = [5.5, 2.4, np.nan, 9.6, 4.2]
>>> post = [6.4, 3.4, 6.4, 11., 4.8]
>>> ttest(pre, post, paired=True).round(3)
T dof alternative p-val CI95% cohen-d BF10 power
T-test -5.902 3 two-sided 0.01 [-1.5, -0.45] 0.306 7.169 0.073
Compare with SciPy
>>> from scipy.stats import ttest_rel
>>> np.round(ttest_rel(pre, post, nan_policy="omit"), 3)
array([-5.902, 0.01 ])
4. Independent two-sample T-test with equal sample size.
>>> np.random.seed(123)
>>> x = np.random.normal(loc=7, size=20)
>>> y = np.random.normal(loc=4, size=20)
>>> ttest(x, y)
T dof alternative p-val CI95% cohen-d BF10 power
T-test 9.106452 38 two-sided 4.306971e-11 [2.64, 4.15] 2.879713 1.366e+08 1.0
5. Independent two-sample T-test with unequal sample size. A Welch's T-test is used.
>>> np.random.seed(123)
>>> y = np.random.normal(loc=6.5, size=15)
>>> ttest(x, y)
T dof alternative p-val CI95% cohen-d BF10 power
T-test 1.996537 31.567592 two-sided 0.054561 [-0.02, 1.65] 0.673518 1.469 0.481867
6. However, the Welch's correction can be disabled:
>>> ttest(x, y, correction=False)
T dof alternative p-val CI95% cohen-d BF10 power
T-test 1.971859 33 two-sided 0.057056 [-0.03, 1.66] 0.673518 1.418 0.481867
Compare with SciPy
>>> from scipy.stats import ttest_ind
>>> np.round(ttest_ind(x, y, equal_var=True), 6) # T value and p-value
array([1.971859, 0.057056])
"""
from scipy.stats import t, ttest_rel, ttest_ind, ttest_1samp
try: # pragma: no cover
from scipy.stats._stats_py import _unequal_var_ttest_denom, _equal_var_ttest_denom
except ImportError: # pragma: no cover
# Fallback for scipy<1.8.0
from scipy.stats.stats import _unequal_var_ttest_denom, _equal_var_ttest_denom
from pingouin import power_ttest, power_ttest2n, compute_effsize
# Check arguments
assert alternative in [
"two-sided",
"greater",
"less",
], "Alternative must be one of 'two-sided' (default), 'greater' or 'less'."
assert 0 < confidence < 1, "c | (x, y, paired=False, alternative='two-sided', correction='auto', r=0.707, confidence=0.95) | [
0.017911642789840698,
0.03548473119735718,
0.06385982036590576,
-0.02166748046875,
0.0334322452545166,
-0.027634503319859505,
-0.04553556442260742,
-0.011595487594604492,
0.0682610273361206,
-0.00192685064394027,
0.009363144636154175,
0.04274249076843262,
0.05048692226409912,
0.04934430122375488,
-0.024164319038391113,
0.05116403102874756,
-0.0008490309701301157,
0.02310633659362793,
-0.002260114997625351,
0.022217631340026855,
-0.014071167446672916,
-0.01693829894065857,
-0.011574327945709229,
0.01607075333595276,
-0.00733181880787015,
0.00616803765296936,
-0.019318759441375732,
-0.0776982307434082,
0.026893915608525276,
0.004792660474777222,
-0.014515520073473454,
-0.0829458236694336,
-0.05467653647065163,
0.014674217440187931,
-0.016039013862609863,
0.0034913423005491495,
-0.0473552942276001,
-0.012187957763671875,
-0.04879415035247803,
0.06580650806427002,
-0.012600570917129517,
-0.05035996437072754,
-0.0016861596377566457,
-0.014314503408968449,
-0.0188426673412323,
-0.011278092861175537,
-0.02264082431793213,
-0.01885324716567993,
-0.015351326204836369,
-0.049301981925964355,
0.027994217351078987,
-0.04879415035247803,
0.029940905049443245,
0.04591643810272217,
-0.0666952133178711,
0.05721569433808327,
-0.0072736297734081745,
0.00397801399230957,
0.0309565681964159,
-0.03590792417526245,
0.03279745578765869,
0.05133330821990967,
0.021022111177444458,
0.027909578755497932,
-0.03209918737411499,
-0.018525272607803345,
-0.015351326204836369,
-0.00025804853066802025,
0.00036996323615312576,
0.0024968385696411133,
-0.005162954330444336,
0.02865016646683216,
-0.04430830478668213,
-0.03851056098937988,
-0.0023593008518218994,
0.05539596453309059,
-0.01792222261428833,
-0.04570484161376953,
-0.050740838050842285,
-0.039441585540771484,
-0.02858668752014637,
0.05124866962432861,
0.043588876724243164,
0.008945241570472717,
-0.02922147698700428,
-0.03658503293991089,
0.010511055588722229,
0.03381311893463135,
0.026534201577305794,
0.013256520964205265,
-0.020091086626052856,
-0.04460453987121582,
0.06136298552155495,
-0.0365215539932251,
-0.0022402778267860413,
-0.04892110824584961,
0.02253502607345581,
0.009130388498306274,
-0.0309565681964159,
-0.054549578577280045,
0.013817251659929752,
0.012135058641433716,
0.0193081796169281,
0.028078855946660042,
0.030618013814091682,
0.02644956111907959,
-0.03647923469543457,
0.033114850521087646,
0.011616647243499756,
0.008426830172538757,
-0.02761334367096424,
-0.023719966411590576,
0.028226973488926888,
0.000710170716047287,
0.03578096628189087,
-0.010542795062065125,
-0.009177997708320618,
0.027994217351078987,
-0.06115138903260231,
-0.02621680498123169,
0.08459627628326416,
0.0315701961517334,
-0.0188426673412323,
0.0029253214597702026,
-0.00962764024734497,
-0.028438569977879524,
0.04354655742645264,
0.06830334663391113,
-0.015869736671447754,
0.008654296398162842,
0.012092739343643188,
-0.015340746380388737,
0.003517791861668229,
0.08489251136779785,
-0.026364922523498535,
0.010907799005508423,
0.04130363464355469,
0.04896342754364014,
0.056919459253549576,
-0.0894629955291748,
0.0451970100402832,
0.0372198224067688,
-0.0160178542137146,
0.0030099600553512573,
0.02668231911957264,
0.010008513927459717,
-0.013372899033129215,
0.015351326204836369,
0.04187494516372681,
0.04384279251098633,
-0.011976361274719238,
-0.02765566296875477,
-0.007321238983422518,
-0.06885349750518799,
0.02598404884338379,
-0.002719014883041382,
0.05306840315461159,
-0.05112171173095703,
-0.028798284009099007,
-0.027338268235325813,
0.01573219895362854,
-0.04507005214691162,
-0.004578419029712677,
0.042276978492736816,
0.046593546867370605,
0.0070779030211269855,
-0.04799008369445801,
0.032987892627716064,
-0.020038187503814697,
-0.05793512240052223,
-0.00462602823972702,
-0.005570277571678162,
-0.04337728023529053,
-0.01631408929824829,
0.00867016613483429,
-0.028861762955784798,
-0.0067605082876980305,
-0.058823827654123306,
0.011965781450271606,
-0.034426748752593994,
0.0030575692653656006,
-0.003940984606742859,
-0.07151961326599121,
-0.002268049865961075,
-0.0318029522895813,
0.024333596229553223,
0.04511237144470215,
0.011108815670013428,
-0.04413902759552002,
-0.00590883195400238,
0.0026608258485794067,
-0.022450387477874756,
-0.03980129957199097,
0.057723525911569595,
0.05653858557343483,
-0.015055091120302677,
0.02628028392791748,
0.0064166635274887085,
0.08895516395568848,
0.004811175167560577,
-0.027042033150792122,
0.05226433277130127,
-0.007881969213485718,
-0.007231310475617647,
0.033284127712249756,
-0.009786337614059448,
-0.062209371477365494,
-0.04481613636016846,
-0.08260726928710938,
-0.014124066568911076,
0.06466388702392578,
-0.034892261028289795,
0.0024796463549137115,
0.021635740995407104,
0.012526512145996094,
0.009294375777244568,
0.013785512186586857,
-0.03658503293991089,
0.0014084391295909882,
-0.047736167907714844,
0.017943382263183594,
-0.005892962217330933,
0.02575129270553589,
0.04143059253692627,
0.06758391857147217,
0.026893915608525276,
0.030681492760777473,
0.06965756416320801,
0.025603175163269043,
0.013478697277605534,
0.05988181009888649,
0.06622970104217529,
-0.00850088894367218,
-0.001996941864490509,
-0.01595437526702881,
-0.0680917501449585,
0.007765591610223055,
-0.07621705532073975,
-0.05543828383088112,
0.0046736374497413635,
-0.008342191576957703,
0.010675042867660522,
0.031147005036473274,
-0.017911642789840698,
-0.033114850521087646,
-0.04104971885681152,
0.030808450654149055,
-0.01010902225971222,
0.009040459990501404,
-0.020038187503814697,
0.010844320058822632,
-0.02939075417816639,
0.03159135580062866,
0.002454519271850586,
-0.004149936139583588,
-0.013901890255510807,
0.061574582010507584,
0.004247799515724182,
0.0546342171728611,
-0.014473200775682926,
0.044350624084472656,
-0.010352358222007751,
-0.04346191883087158,
0.049301981925964355,
-0.06470620632171631,
-0.020017027854919434,
-0.0297927875071764,
-0.0032030418515205383,
0.0003268173895776272,
-0.022175312042236328,
0.03618299961090088,
-0.013954789377748966,
-0.09953498840332031,
-0.03802388906478882,
-0.03398239612579346,
0.02558201551437378,
0.07617473602294922,
0.006987974513322115,
0.0066282604821026325,
-0.06288647651672363,
-0.05526900663971901,
0.00939488410949707,
0.019900649785995483,
-0.003911890089511871,
-0.0007002521306276321,
-0.015393645502626896,
-0.0718158483505249,
-0.02114906907081604,
0.06555259227752686,
-0.003575980896130204,
-0.044519901275634766,
-0.047863125801086426,
0.027422906830906868,
0.012463033199310303,
0.04096508026123047,
-0.0008827541605569422,
-0.0786292552947998,
-0.05522668734192848,
0.0341305136680603,
-0.03283977508544922,
0.0013343803584575653,
-0.011553168296813965,
0.022619664669036865,
0.05442262068390846,
-0.05569219961762428,
0.031549036502838135,
0.03872215747833252,
-0.04701673984527588,
-0.013372899033129215,
0.004382692277431488,
0.03671199083328247,
-0.004906393587589264,
0.011256933212280273,
-0.016229450702667236,
0.006707609165459871,
-0.022048354148864746,
-0.049471259117126465,
-0.031718313694000244,
0.011553168296813965,
-0.03008902259171009,
-0.012410134077072144,
-0.015446544624865055,
0.03724098205566406,
0.0060304999351501465,
0.0666952133178711,
0.0001240649726241827,
-0.00505451112985611,
-0.01872628927230835,
-0.021350085735321045,
0.05476117506623268,
-0.0037505479995161295,
-0.005506798624992371,
0.02333909273147583,
0.03444790840148926,
-0.01140505075454712,
0.0193081796169281,
0.001728478935547173,
-0.012420713901519775,
0.014187545515596867,
-0.015234948135912418,
0.02818465419113636,
0.0007643923163414001,
-0.01146852970123291,
-0.04748225212097168,
0.04329264163970947,
0.0059670209884643555,
-0.041980743408203125,
0.005871802568435669,
0.10156631469726562,
0.014229864813387394,
0.03205686807632446,
0.03925114870071411,
0.014504940249025822,
0.021984875202178955,
-0.02040848135948181,
0.017372071743011475,
-0.014303923584520817,
-0.012875646352767944,
0.06864190101623535,
0.051206350326538086,
-0.05569219961762428,
0.0327339768409729,
-0.0036103653255850077,
-0.0028195232152938843,
0.017096996307373047,
-0.004813820123672485,
0.00544331967830658,
0.02391040325164795,
-0.06606042385101318,
0.020091086626052856,
0.004964582622051239,
-0.06965756416320801,
0.021180808544158936,
0.013182461261749268,
0.07215440273284912,
-0.05620003119111061,
0.02253502607345581,
0.009003430604934692,
0.0061574578285217285,
-0.00047642274876125157,
0.022683143615722656,
0.010352358222007751,
-0.06965756416320801,
0.02501070499420166,
-0.048836469650268555,
-0.003851056331768632,
-0.02501070499420166,
0.019054263830184937,
-0.005051866173744202,
-0.04604339599609375,
-0.0068239872343838215,
-0.0393146276473999,
0.006273835897445679,
0.01014605164527893,
0.004723891615867615,
0.040880441665649414,
-0.01877918839454651,
-0.013700873591005802,
0.007485226262360811,
-0.010193660855293274,
0.021466463804244995,
0.0008642394677735865,
-0.024735629558563232,
-0.002188701182603836,
-0.019403398036956787,
0.02731710858643055,
0.028332771733403206,
-0.009611770510673523,
-0.02587825059890747,
-0.019054263830184937,
-0.00812530517578125,
0.05192577838897705,
-0.02945423312485218,
-0.04066884517669678,
-0.047397613525390625,
0.0725775957107544,
-0.09691119194030762,
0.03641575574874878,
0.058062080293893814,
0.009934455156326294,
0.08116841316223145,
-0.036161839962005615,
0.006861016619950533,
-0.02316981554031372,
0.07342398166656494,
-0.018313676118850708,
-0.004840269684791565,
-0.007030293811112642,
-0.020133405923843384,
0.039610862731933594,
0.024354755878448486,
-0.03112584538757801,
-0.0038775058928877115,
0.00925205647945404,
0.03317832946777344,
0.0026185065507888794,
-0.05954325571656227,
0.02443939447402954,
0.055184368044137955,
-0.0054486095905303955,
-0.016102492809295654,
0.02166748046875,
0.012801587581634521,
-0.009892135858535767,
-0.022556185722351074,
0.00032813986763358116,
0.013827831484377384,
-0.054718855768442154,
-0.06606042385101318,
-0.04113435745239258,
0.001355540007352829,
0.0010460801422595978,
0.006506592035293579,
0.048667192459106445,
-0.05967021360993385,
-0.027973057702183723,
-0.005205273628234863,
-0.03641575574874878,
-0.057554248720407486,
0.016388148069381714,
-0.02598404884338379,
0.004022978246212006,
-0.0376853346824646,
-0.0424039363861084,
0.009463652968406677,
-0.007950738072395325,
-0.02801537699997425,
-0.010907799005508423,
-0.007236600387841463,
-0.011373311281204224,
-0.030406417325139046,
0.026301443576812744,
-0.04799008369445801,
0.038172006607055664,
0.04697442054748535,
0.05319536104798317,
-0.050571560859680176,
0.027930738404393196,
0.001416373997926712,
-0.02905219979584217,
0.0131930410861969,
-0.008939951658248901,
0.048667192459106445,
0.011373311281204224,
0.0676262378692627,
-0.02300053834915161,
-0.04447758197784424,
-0.025095343589782715,
0.061870817095041275,
-0.052010416984558105,
0.05620003119111061,
-0.029813947156071663,
-0.0036077203694730997,
0.07549762725830078,
-0.11587024480104446,
-0.016218870878219604,
-0.010516345500946045,
-0.020535439252853394,
0.028396250680088997,
0.03387659788131714,
0.08353829383850098,
0.0013925693929195404,
-0.03262817859649658,
-0.06504476070404053,
0.06017804518342018,
0.00965408980846405,
-0.020948052406311035,
-0.026174485683441162,
-0.012769848108291626,
0.009379014372825623,
-0.03787577152252197,
-0.05336463823914528,
0.06885349750518799,
-0.01345753762871027,
0.0038325416389852762,
-0.04481613636016846,
0.018990784883499146,
-0.03290325403213501,
0.019752532243728638,
-0.029877426102757454,
0.011859983205795288,
0.012526512145996094,
0.033114850521087646,
0.04066884517669678,
0.0214347243309021,
-0.017298012971878052,
-0.035823285579681396,
0.05522668734192848,
-0.008611977100372314,
0.013171881437301636,
0.016229450702667236,
-0.0372198224067688,
0.0017668307991698384,
-0.007649213541299105,
-0.041515231132507324,
-0.014113486744463444,
-0.06508708000183105,
-0.010928958654403687,
0.10046601295471191,
-0.011849403381347656,
0.05746961012482643,
-0.005940571427345276,
0.029242636635899544,
-0.016091912984848022,
0.044689178466796875,
-0.024566352367401123,
-0.004052072763442993,
0.019667893648147583,
-0.02454519271850586,
0.01608133316040039,
0.029771627858281136,
-0.049640536308288574,
0.042044222354888916,
0.012410134077072144,
-0.023846924304962158,
-0.03895491361618042,
0.03508269786834717,
0.03055453486740589,
-0.026830436661839485,
-0.017827004194259644,
-0.04845559597015381,
-0.04166334867477417,
0.04337728023529053,
-0.08053362369537354,
0.03757953643798828,
0.02788841910660267,
0.024333596229553223,
-0.0005970988422632217,
-0.057258013635873795,
-0.04841327667236328,
0.005292557179927826,
0.0031977519392967224,
-0.00012480886653065681,
0.012589991092681885,
-0.0038801508489996195,
0.008172914385795593,
-0.040880441665649414,
-0.0028591975569725037,
0.021519362926483154,
-0.02414315938949585,
0.009971484541893005,
0.024524033069610596,
0.031485557556152344,
-0.030004383996129036,
-0.03677546977996826,
0.013711453415453434,
-0.003988593816757202,
0.03988593816757202,
-0.04234045743942261,
-0.0019744597375392914,
-0.07401645183563232,
-0.021138489246368408,
-0.022979378700256348,
-0.024354755878448486,
0.02547621726989746,
-0.002309046685695648,
0.004247799515724182,
0.01562640070915222,
0.0685572624206543,
0.017795264720916748,
-0.006369054317474365,
0.04073232412338257,
0.010019093751907349,
-0.030512215569615364,
-0.017298012971878052,
-0.010204240679740906,
-0.022958219051361084,
-0.010167211294174194,
-0.010865479707717896,
-0.059331659227609634,
0.041007399559020996,
0.015827417373657227,
-0.04026681184768677,
-0.07223904132843018,
0.06479084491729736,
0.024693310260772705,
-0.017096996307373047,
0.01437798235565424,
0.040774643421173096,
-0.017721205949783325,
-0.03624647855758667,
0.06242096796631813,
0.00730536924675107,
0.062040094286203384,
0.011394470930099487,
-0.005358681082725525,
0.0006334669888019562,
-0.04633963108062744,
-0.009204447269439697,
-0.10901451855897903,
-0.029708148911595345,
0.015192628838121891,
0.033220648765563965,
-0.0032612308859825134,
0.002771914005279541,
-0.011743605136871338,
0.05937397852540016,
-0.005022771656513214,
0.020831674337387085,
0.05361855402588844,
-0.050106048583984375,
0.028226973488926888,
0.10308980941772461,
0.052179694175720215,
0.00015150639228522778,
0.0038801508489996195,
0.011394470930099487,
-0.00038913916796445847,
0.008707195520401001,
0.012209117412567139,
0.022027194499969482,
0.044689178466796875,
-0.017953962087631226,
-0.029771627858281136,
-0.011627227067947388,
-0.014420301653444767,
0.03214150667190552,
0.014578999020159245,
0.0049936771392822266,
0.006125718355178833,
0.02939075417816639,
0.018937885761260986,
-0.06009340658783913,
0.05785048380494118,
0.05895078554749489,
0.02962351031601429,
0.01722395420074463,
0.08353829383850098,
-0.01699119806289673,
0.023423731327056885,
0.027761461213231087,
0.07604777812957764,
-0.03279745578765869,
0.013616234995424747,
0.026026368141174316,
-0.015975534915924072,
0.009088069200515747,
0.02103269100189209,
-0.01279100775718689,
-0.011976361274719238,
0.0372198224067688,
0.038404762744903564,
-0.025899410247802734,
-0.06102443113923073,
0.05488813295960426,
-0.017139315605163574,
-0.008104145526885986,
0.002909451723098755,
-0.05526900663971901,
-0.06381750106811523,
-0.03199338912963867,
-0.019202381372451782,
0.04667818546295166,
-0.00501483678817749,
-0.0155946621671319,
0.007051453460007906,
-0.014018268324434757,
0.057554248720407486,
0.003642104798927903,
-0.09064793586730957,
-0.016218870878219604,
-0.041345953941345215,
-0.011140555143356323,
0.017361491918563843,
-0.026237964630126953,
0.05023300647735596,
-0.010093152523040771,
-0.062209371477365494,
0.024799108505249023,
-0.1092684343457222,
-0.035061538219451904,
-0.023995041847229004,
0.02240806818008423,
-0.010928958654403687,
-0.015711039304733276,
-0.0002691242843866348,
-0.005110055208206177,
0.004850849509239197,
-0.014864654280245304,
0.019551515579223633,
0.0047397613525390625,
0.014483780600130558,
0.01553118322044611,
0.01862049102783203,
-0.03601372241973877,
-0.0074481968767941,
0.012992024421691895,
-0.03353804349899292,
-0.07109642028808594,
-0.007151961792260408,
0.018292516469955444,
0.005221143364906311,
-0.000835144950542599,
-0.019276440143585205,
-0.049005746841430664,
-0.029369594529271126,
0.013224780559539795,
-0.03914535045623779,
0.06656825542449951,
0.020948052406311035,
0.01614481210708618,
0.010426416993141174,
0.008426830172538757,
-0.05395710840821266,
0.0008212588727474213,
0.0219002366065979,
-0.0162506103515625,
0.021646320819854736,
0.019604414701461792,
-0.010865479707717896,
0.06462156772613525,
-0.02240806818008423,
-0.05450725927948952,
-0.023529529571533203,
0.05738497152924538,
0.0419384241104126,
0.06796479225158691,
-0.07604777812957764,
-0.01780584454536438,
-0.027634503319859505,
-0.015107990242540836,
0.03645807504653931,
0.06132066622376442,
0.07664024829864502,
-0.0024690665304660797,
0.02939075417816639,
-0.05319536104798317,
0.0911557674407959
]
|
32,066 | pingouin.parametric | welch_anova | One-way Welch ANOVA.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a
Pandas method, in which case this argument is no longer needed.
dv : string
Name of column containing the dependent variable.
between : string
Name of column containing the between factor.
Returns
-------
aov : :py:class:`pandas.DataFrame`
ANOVA summary:
* ``'Source'``: Factor names
* ``'ddof1'``: Numerator degrees of freedom
* ``'ddof2'``: Denominator degrees of freedom
* ``'F'``: F-values
* ``'p-unc'``: uncorrected p-values
* ``'np2'``: Partial eta-squared
See Also
--------
anova : One-way and N-way ANOVA
rm_anova : One-way and two-way repeated measures ANOVA
mixed_anova : Two way mixed ANOVA
kruskal : Non-parametric one-way ANOVA
Notes
-----
From Wikipedia:
*It is named for its creator, Bernard Lewis Welch, and is an adaptation of
Student's t-test, and is more reliable when the two samples have
unequal variances and/or unequal sample sizes.*
The classic ANOVA is very powerful when the groups are normally distributed
and have equal variances. However, when the groups have unequal variances,
it is best to use the Welch ANOVA that better controls for
type I error (Liu 2015). The homogeneity of variances can be measured with
the `homoscedasticity` function. The two other assumptions of
normality and independance remain.
The main idea of Welch ANOVA is to use a weight :math:`w_i` to reduce
the effect of unequal variances. This weight is calculated using the sample
size :math:`n_i` and variance :math:`s_i^2` of each group
:math:`i=1,...,r`:
.. math:: w_i = \frac{n_i}{s_i^2}
Using these weights, the adjusted grand mean of the data is:
.. math::
\overline{Y}_{\text{welch}} = \frac{\sum_{i=1}^r
w_i\overline{Y}_i}{\sum w}
where :math:`\overline{Y}_i` is the mean of the :math:`i` group.
The effect sums of squares is defined as:
.. math::
SS_{\text{effect}} = \sum_{i=1}^r w_i
(\overline{Y}_i - \overline{Y}_{\text{welch}})^2
We then need to calculate a term lambda:
.. math::
\Lambda = \frac{3\sum_{i=1}^r(\frac{1}{n_i-1})
(1 - \frac{w_i}{\sum w})^2}{r^2 - 1}
from which the F-value can be calculated:
.. math::
F_{\text{welch}} = \frac{SS_{\text{effect}} / (r-1)}
{1 + \frac{2\Lambda(r-2)}{3}}
and the p-value approximated using a F-distribution with
:math:`(r-1, 1 / \Lambda)` degrees of freedom.
When the groups are balanced and have equal variances, the optimal post-hoc
test is the Tukey-HSD test (:py:func:`pingouin.pairwise_tukey`).
If the groups have unequal variances, the Games-Howell test is more
adequate (:py:func:`pingouin.pairwise_gameshowell`).
Results have been tested against R.
References
----------
.. [1] Liu, Hangcheng. "Comparing Welch's ANOVA, a Kruskal-Wallis test and
traditional ANOVA in case of Heterogeneity of Variance." (2015).
.. [2] Welch, Bernard Lewis. "On the comparison of several mean values:
an alternative approach." Biometrika 38.3/4 (1951): 330-336.
Examples
--------
1. One-way Welch ANOVA on the pain threshold dataset.
>>> from pingouin import welch_anova, read_dataset
>>> df = read_dataset('anova')
>>> aov = welch_anova(dv='Pain threshold', between='Hair color', data=df)
>>> aov
Source ddof1 ddof2 F p-unc np2
0 Hair color 3 8.329841 5.890115 0.018813 0.575962
| @pf.register_dataframe_method
def welch_anova(data=None, dv=None, between=None):
"""One-way Welch ANOVA.
Parameters
----------
data : :py:class:`pandas.DataFrame`
DataFrame. Note that this function can also directly be used as a
Pandas method, in which case this argument is no longer needed.
dv : string
Name of column containing the dependent variable.
between : string
Name of column containing the between factor.
Returns
-------
aov : :py:class:`pandas.DataFrame`
ANOVA summary:
* ``'Source'``: Factor names
* ``'ddof1'``: Numerator degrees of freedom
* ``'ddof2'``: Denominator degrees of freedom
* ``'F'``: F-values
* ``'p-unc'``: uncorrected p-values
* ``'np2'``: Partial eta-squared
See Also
--------
anova : One-way and N-way ANOVA
rm_anova : One-way and two-way repeated measures ANOVA
mixed_anova : Two way mixed ANOVA
kruskal : Non-parametric one-way ANOVA
Notes
-----
From Wikipedia:
*It is named for its creator, Bernard Lewis Welch, and is an adaptation of
Student's t-test, and is more reliable when the two samples have
unequal variances and/or unequal sample sizes.*
The classic ANOVA is very powerful when the groups are normally distributed
and have equal variances. However, when the groups have unequal variances,
it is best to use the Welch ANOVA that better controls for
type I error (Liu 2015). The homogeneity of variances can be measured with
the `homoscedasticity` function. The two other assumptions of
normality and independance remain.
The main idea of Welch ANOVA is to use a weight :math:`w_i` to reduce
the effect of unequal variances. This weight is calculated using the sample
size :math:`n_i` and variance :math:`s_i^2` of each group
:math:`i=1,...,r`:
.. math:: w_i = \\frac{n_i}{s_i^2}
Using these weights, the adjusted grand mean of the data is:
.. math::
\\overline{Y}_{\\text{welch}} = \\frac{\\sum_{i=1}^r
w_i\\overline{Y}_i}{\\sum w}
where :math:`\\overline{Y}_i` is the mean of the :math:`i` group.
The effect sums of squares is defined as:
.. math::
SS_{\\text{effect}} = \\sum_{i=1}^r w_i
(\\overline{Y}_i - \\overline{Y}_{\\text{welch}})^2
We then need to calculate a term lambda:
.. math::
\\Lambda = \\frac{3\\sum_{i=1}^r(\\frac{1}{n_i-1})
(1 - \\frac{w_i}{\\sum w})^2}{r^2 - 1}
from which the F-value can be calculated:
.. math::
F_{\\text{welch}} = \\frac{SS_{\\text{effect}} / (r-1)}
{1 + \\frac{2\\Lambda(r-2)}{3}}
and the p-value approximated using a F-distribution with
:math:`(r-1, 1 / \\Lambda)` degrees of freedom.
When the groups are balanced and have equal variances, the optimal post-hoc
test is the Tukey-HSD test (:py:func:`pingouin.pairwise_tukey`).
If the groups have unequal variances, the Games-Howell test is more
adequate (:py:func:`pingouin.pairwise_gameshowell`).
Results have been tested against R.
References
----------
.. [1] Liu, Hangcheng. "Comparing Welch's ANOVA, a Kruskal-Wallis test and
traditional ANOVA in case of Heterogeneity of Variance." (2015).
.. [2] Welch, Bernard Lewis. "On the comparison of several mean values:
an alternative approach." Biometrika 38.3/4 (1951): 330-336.
Examples
--------
1. One-way Welch ANOVA on the pain threshold dataset.
>>> from pingouin import welch_anova, read_dataset
>>> df = read_dataset('anova')
>>> aov = welch_anova(dv='Pain threshold', between='Hair color', data=df)
>>> aov
Source ddof1 ddof2 F p-unc np2
0 Hair color 3 8.329841 5.890115 0.018813 0.575962
"""
# Check data
data = _check_dataframe(dv=dv, between=between, data=data, effects="between")
# Reset index (avoid duplicate axis error)
data = data.reset_index(drop=True)
# Number of groups
r = data[between].nunique()
ddof1 = r - 1
# Compute weights and ajusted means
grp = data.groupby(between, observed=True, group_keys=False)[dv]
weights = grp.count() / grp.var(numeric_only=True)
adj_grandmean = (weights * grp.mean(numeric_only=True)).sum() / weights.sum()
# Sums of squares (regular and adjusted)
ss_res = grp.apply(lambda x: (x - x.mean()) ** 2).sum()
ss_bet = (
(grp.mean(numeric_only=True) - data[dv].mean(numeric_only=True)) ** 2 * grp.count()
).sum()
ss_betadj = np.sum(weights * np.square(grp.mean(numeric_only=True) - adj_grandmean))
ms_betadj = ss_betadj / ddof1
# Calculate lambda, F-value, p-value and np2
lamb = (3 * np.sum((1 / (grp.count() - 1)) * (1 - (weights / weights.sum())) ** 2)) / (
r**2 - 1
)
ddof2 = 1 / lamb
fval = ms_betadj / (1 + (2 * lamb * (r - 2)) / 3)
pval = f.sf(fval, ddof1, ddof2)
np2 = ss_bet / (ss_bet + ss_res)
# Create output dataframe
aov = pd.DataFrame(
{
"Source": between,
"ddof1": ddof1,
"ddof2": ddof2,
"F": fval,
"p-unc": pval,
"np2": np2,
},
index=[0],
)
return _postprocess_dataframe(aov)
| (data=None, dv=None, between=None) | [
0.022777549922466278,
-0.04098265618085861,
0.04796833544969559,
-0.018946010619401932,
0.00628181966021657,
-0.04240095987915993,
0.003942675422877073,
-0.06685084104537964,
-0.020724182948470116,
0.06642746925354004,
-0.03685475513339043,
-0.01105007529258728,
0.05829867348074913,
0.029911411926150322,
-0.06045788526535034,
0.08289673179388046,
-0.023962998762726784,
0.029890242964029312,
0.065707728266716,
0.02773103304207325,
-0.03010193072259426,
-0.07112692296504974,
-0.018141599372029305,
0.0028260250110179186,
-0.00825580395758152,
0.04216810315847397,
-0.0603732094168663,
-0.0245345551520586,
-0.014722849242389202,
-0.024153517559170723,
0.0026209531351923943,
-0.06405656784772873,
-0.01947522908449173,
-0.034378014504909515,
0.051228318363428116,
-0.0490691103041172,
0.02214248850941658,
-0.028154406696558,
-0.051524680107831955,
0.008319309912621975,
0.01911536045372486,
-0.02256586216390133,
0.03014426678419113,
0.009959885850548744,
-0.062066707760095596,
0.02235417626798153,
-0.037172283977270126,
0.0981382206082344,
0.023200925439596176,
-0.01400311291217804,
-0.00105512875597924,
0.0022438850719481707,
0.04102499410510063,
0.015008627437055111,
0.026397403329610825,
0.05740958824753761,
-0.02796388790011406,
0.013473894447088242,
0.09297304600477219,
-0.09017878025770187,
0.04644418880343437,
0.017506537958979607,
0.0437345914542675,
-0.017813483253121376,
-0.024174686521291733,
-0.025592990219593048,
0.0010802665492519736,
0.021147558465600014,
-0.014744018204510212,
0.00991225615143776,
-0.017876990139484406,
0.03096984699368477,
0.009589433670043945,
0.03268451616168022,
-0.0452164001762867,
0.0379766970872879,
-0.025741172954440117,
-0.04113083705306053,
0.02470390498638153,
0.00245028012432158,
0.04779898747801781,
-0.002810148522257805,
-0.029720893129706383,
-0.03365827724337578,
0.026355065405368805,
-0.018596727401018143,
-0.03793435916304588,
0.023200925439596176,
0.08484426140785217,
-0.06066957116127014,
0.01915769837796688,
0.01928471028804779,
0.032134126871824265,
0.0020493974443525076,
0.016088232398033142,
-0.001721282140351832,
-0.01392902247607708,
-0.014627590775489807,
-0.0034002268221229315,
0.024576891213655472,
-0.014998042955994606,
0.059187762439250946,
0.059357110410928726,
0.09271902590990067,
-0.007562527898699045,
-0.003955905791372061,
-0.0450047142803669,
0.014648758806288242,
-0.02747700735926628,
-0.02449221722781658,
-0.08721515536308289,
-0.010071021504700184,
-0.03702410310506821,
-0.03130854666233063,
-0.013018767349421978,
-0.024428710341453552,
-0.026926619932055473,
0.03594449907541275,
-0.05558907613158226,
0.028895312920212746,
0.07028017193078995,
0.03875993937253952,
-0.020671261474490166,
-0.04898443445563316,
0.02212131954729557,
-0.04136369377374649,
0.009922840632498264,
-0.07311678677797318,
0.026482077315449715,
0.012055589817464352,
-0.01544258650392294,
0.028979986906051636,
-0.03772267326712608,
0.01947522908449173,
-0.01111358217895031,
-0.012987013906240463,
0.05529271438717842,
-0.0023312061093747616,
0.02470390498638153,
-0.039754871279001236,
0.024576891213655472,
0.010393844917416573,
0.0062236059457063675,
-0.03384879603981972,
0.011833318509161472,
0.00949946604669094,
0.05088961869478226,
0.018141599372029305,
-0.004643889609724283,
0.003304967423900962,
0.00239471229724586,
-0.010288001038134098,
0.018385039642453194,
-0.01097598485648632,
0.08420919626951218,
-0.037341635674238205,
0.00690629705786705,
-0.057282574474811554,
-0.0018800476100295782,
-0.029255181550979614,
-0.014140709303319454,
-0.02521195448935032,
-0.02241768129169941,
0.06879836320877075,
-0.0011517110979184508,
0.034526195377111435,
-0.003805078798905015,
0.015484923496842384,
0.02495792880654335,
-0.03247282654047012,
0.0037680333480238914,
-0.0049958196468651295,
-0.05215974524617195,
0.054530639201402664,
-0.03245165944099426,
0.08497127145528793,
-0.014447656460106373,
-0.02773103304207325,
0.00834577064961195,
-0.07028017193078995,
-0.006805745884776115,
0.01538966502994299,
-0.04210459813475609,
-0.0335947684943676,
-0.048772748559713364,
-0.009234856814146042,
0.020216133445501328,
0.008377524092793465,
-0.008388107642531395,
0.0009016554686240852,
-0.05177870765328407,
-0.07476794719696045,
0.03909863904118538,
-0.014130125753581524,
-0.013653828762471676,
-0.01687147468328476,
-0.01886133663356304,
-0.01126176305115223,
0.034716714173555374,
-0.06710486114025116,
0.008573334664106369,
0.004074980039149523,
0.010727252811193466,
0.012447211891412735,
-0.02201547659933567,
-0.0020665968768298626,
-0.03691826015710831,
0.03130854666233063,
-0.025762340053915977,
-0.03041946142911911,
0.037235792726278305,
-0.017548874020576477,
-0.0055991280823946,
0.05537739023566246,
0.02783687599003315,
-0.053895577788352966,
0.03611384704709053,
-0.01398194395005703,
0.018321532756090164,
0.0190412700176239,
-0.04432731494307518,
-0.03691826015710831,
-0.06304047256708145,
0.05266779288649559,
0.08094920963048935,
-0.00993342511355877,
0.03577514737844467,
0.026439739391207695,
0.04398861527442932,
-0.04517406225204468,
0.002618307014927268,
-0.012785911560058594,
-0.014913368038833141,
-0.03950084373354912,
-0.0070756468921899796,
0.013230454176664352,
-0.04386160150170326,
-0.020512497052550316,
-0.06253241747617722,
-0.01945406012237072,
0.02483091689646244,
-0.05910308659076691,
0.040601618587970734,
0.03873877227306366,
-0.039712533354759216,
-0.05893373489379883,
0.03801903501152992,
0.020332561805844307,
0.006091301329433918,
-0.03033478558063507,
-0.005773770157247782,
-0.04652886092662811,
-0.03096984699368477,
0.03664306551218033,
-0.05783296376466751,
-0.06346384435892105,
0.032324645668268204,
0.023518456146121025,
0.029339855536818504,
-0.06282877922058105,
0.020755937322974205,
-0.012277862057089806,
-0.017347771674394608,
0.03323490172624588,
-0.04155421257019043,
0.021031130105257034,
-0.0050222803838551044,
-0.05550440400838852,
0.02243885025382042,
-0.003101218491792679,
-0.03128737956285477,
0.025402473285794258,
0.00476825563237071,
-0.006678733509033918,
-0.06155866011977196,
0.04199875518679619,
0.01953873597085476,
-0.001085558789782226,
-0.00476825563237071,
-0.00772129325196147,
0.010806635022163391,
-0.02212131954729557,
-0.05639348924160004,
0.03427216783165932,
-0.021126389503479004,
0.020650092512369156,
-0.020660677924752235,
-0.0505509190261364,
0.059992171823978424,
-0.0276251882314682,
-0.009113136678934097,
-0.037553321570158005,
0.03566930443048477,
-0.01955990307033062,
0.018353287130594254,
0.06943342834711075,
0.028704794123768806,
-0.028260251507163048,
0.005477407947182655,
-0.008631548844277859,
-0.005556791089475155,
0.03442034870386124,
0.10694441199302673,
0.0275193452835083,
-0.06316748261451721,
0.004646535497158766,
0.037807345390319824,
-0.05635115131735802,
0.028789468109607697,
-0.09339642524719238,
0.0013825824717059731,
0.043036021292209625,
0.005183692090213299,
-0.005019634496420622,
0.028704794123768806,
-0.054276615381240845,
0.006371786817908287,
-0.0027387039735913277,
0.05766361206769943,
0.062405407428741455,
-0.032218802720308304,
0.0037415726110339165,
0.05516570433974266,
-0.03653722256422043,
0.05385323986411095,
-0.0077318777330219746,
0.07667312771081924,
-0.01654336042702198,
0.029064662754535675,
-0.007980610243976116,
-0.06943342834711075,
-0.04108849912881851,
0.04240095987915993,
0.024386374279856682,
-0.05029689520597458,
0.012690652161836624,
-0.0005751940188929439,
0.00011816449841717258,
0.017368940636515617,
0.010748420841991901,
0.035034243017435074,
0.07303211092948914,
-0.017580628395080566,
-0.005921951495110989,
0.0275193452835083,
-0.049153782427310944,
0.034526195377111435,
0.03386996313929558,
0.024301698431372643,
0.0011113581713289022,
0.008091745898127556,
0.01402428187429905,
0.020978208631277084,
0.03046179749071598,
0.07214301824569702,
0.014796940609812737,
-0.003307613544166088,
0.009991639293730259,
0.0062500666826963425,
-0.023200925439596176,
0.023306768387556076,
0.012087343260645866,
-0.020501911640167236,
0.00041312092798762023,
0.026376234367489815,
-0.014892199076712132,
0.010732544586062431,
0.0020745352376252413,
-0.003611914115026593,
-0.032388150691986084,
-0.013262207619845867,
-0.04381926357746124,
0.014489993453025818,
-0.02745583839714527,
0.03289620205760002,
0.007641910575330257,
0.011134750209748745,
-0.010721960105001926,
0.017527706921100616,
0.029720893129706383,
0.057240236550569534,
0.028408432379364967,
-0.039903052151203156,
0.02775220200419426,
0.05059325695037842,
-0.04079213738441467,
-0.02186729572713375,
-0.0048582227900624275,
-0.026291558519005775,
-0.03126620873808861,
0.03685475513339043,
0.0019872142001986504,
0.04166005551815033,
0.03530943766236305,
0.0019700147677212954,
0.018416792154312134,
-0.05258311703801155,
0.011494618840515614,
-0.07332847267389297,
-0.004008827731013298,
-0.003442564280703664,
-0.01915769837796688,
-0.03907747194170952,
-0.023645468056201935,
-0.05766361206769943,
-0.054530639201402664,
-0.008303433656692505,
0.017400693148374557,
-0.037256959825754166,
0.029509205371141434,
-0.03020777367055416,
0.02743466943502426,
-0.05512336641550064,
0.020618340000510216,
0.003172663040459156,
0.02459806017577648,
0.023835986852645874,
-0.013516232371330261,
0.014892199076712132,
0.013674997724592686,
0.0674012303352356,
-0.051651693880558014,
0.015855375677347183,
0.051312994211912155,
0.06405656784772873,
-0.03564813733100891,
-0.0447930246591568,
-0.014161878265440464,
0.01629992015659809,
-0.0014950413024052978,
0.03964902460575104,
-0.008737391792237759,
-0.0447930246591568,
-0.040114738047122955,
-0.008599795401096344,
-0.0053874412551522255,
-0.02754051424562931,
0.03905630111694336,
0.062363069504499435,
0.029763231053948402,
0.002605076413601637,
0.020777106285095215,
0.02180378884077072,
0.01229903008788824,
-0.09754549711942673,
-0.011081828735768795,
0.03833656385540962,
-0.030017254874110222,
-0.07553001493215561,
-0.0560971274971962,
0.08399751037359238,
0.04424263909459114,
0.037405140697956085,
0.028387263417243958,
-0.03702410310506821,
0.03886578232049942,
0.005720848683267832,
-0.03693942725658417,
-0.029022324830293655,
0.03279035910964012,
0.037701502442359924,
0.003950613550841808,
-0.04445432871580124,
0.028408432379364967,
-0.03537294268608093,
0.03947967663407326,
0.06050022318959236,
-0.04779898747801781,
0.02523312345147133,
0.008816774934530258,
0.013547984883189201,
-0.05072027072310448,
-0.014987458474934101,
-0.010700791142880917,
0.05783296376466751,
0.028937648981809616,
-0.042633816599845886,
-0.04775664955377579,
0.026609089225530624,
0.010933647863566875,
0.002521724672988057,
0.0005149954231455922,
0.06193969398736954,
0.002393389120697975,
-0.001857555820606649,
-0.027307657524943352,
0.0021274571772664785,
-0.008033531717956066,
-0.0221848264336586,
-0.004990527406334877,
0.01116650365293026,
0.017517121508717537,
0.021263986825942993,
0.032007116824388504,
-0.06388721615076065,
0.01405603438615799,
0.0501275472342968,
0.013262207619845867,
0.05444596707820892,
-0.07341314852237701,
0.03516125679016113,
-0.0034954859875142574,
-0.0989849641919136,
-0.045893799513578415,
0.020194966346025467,
-0.029297517612576485,
-0.003220292506739497,
-0.0074937292374670506,
-0.02538130432367325,
0.009187227115035057,
0.007525482680648565,
-0.04108849912881851,
0.02758285216987133,
0.01633167266845703,
0.017728809267282486,
-0.0028577782213687897,
-0.004416325595229864,
0.06790927797555923,
0.01713608391582966,
-0.02246001921594143,
0.025783509016036987,
-0.048942096531391144,
0.010515565052628517,
-0.007975317537784576,
0.005233967676758766,
0.03943733870983124,
-0.017464200034737587,
0.006975095719099045,
0.028683625161647797,
-0.009531219489872456,
-0.010817219503223896,
-0.02485208585858345,
0.03607150912284851,
0.045978475362062454,
0.007123276591300964,
-0.01976100727915764,
-0.048137687146663666,
-0.05571608990430832,
-0.1002550944685936,
0.028747132048010826,
-0.020036200061440468,
-0.01905185356736183,
-0.0452164001762867,
-0.0616433322429657,
0.034991905093193054,
0.010631993412971497,
0.006128346547484398,
-0.04767197370529175,
0.013600907288491726,
-0.03312905877828598,
0.02180378884077072,
-0.031096860766410828,
0.05224441736936569,
0.10508155822753906,
0.024111179634928703,
0.03708760812878609,
0.021041715517640114,
0.002995374845340848,
0.001497687422670424,
-0.02790038287639618,
-0.03583865612745285,
-0.08666476607322693,
0.03022894263267517,
-0.06748589873313904,
-0.018522636964917183,
0.020766520872712135,
0.045851461589336395,
0.04978884756565094,
-0.07481028139591217,
-0.03632553666830063,
-0.03619852289557457,
0.06829031556844711,
0.014246553182601929,
-0.042527973651885986,
-0.07193133234977722,
0.011896824464201927,
0.004133193753659725,
-0.023666637018322945,
-0.0009082707110792398,
-0.02233300730586052,
-0.03939500078558922,
-0.06282877922058105,
-0.018152182921767235,
-0.040072400122880936,
-0.004794716835021973,
0.0075307744555175304,
-0.0280485637485981,
0.04737561196088791,
-0.013018767349421978,
0.048899758607149124,
-0.04796833544969559,
-0.04492003843188286,
-0.03810370713472366,
-0.02184612676501274,
-0.00139052071608603,
0.045343413949012756,
-0.014966290444135666,
-0.01366441324353218,
0.08543698489665985,
0.033171396702528,
-0.02806973271071911,
0.00205468968488276,
-0.0009142244234681129,
-0.042887840420007706,
0.03128737956285477,
0.03653722256422043,
0.048349373042583466,
-0.01922120340168476,
0.03543644770979881,
-0.013600907288491726,
0.013558569364249706,
0.05330285429954529,
0.03386996313929558,
-0.01622582972049713,
0.009552388451993465,
0.001780819147825241,
-0.04206226021051407,
-0.051228318363428116,
0.02747700735926628,
0.01549550797790289,
-0.010409721173346043,
0.0275193452835083,
-0.020173797383904457,
0.008996709249913692,
-0.010150404646992683,
-0.042781997472047806,
0.06299813091754913,
-0.03922565281391144,
-0.05355687811970711,
-0.0450047142803669,
0.006705194246023893,
0.02806973271071911,
0.0276251882314682,
-0.023264430463314056,
-0.010097483173012733,
0.049280796200037,
0.03372178226709366,
0.008070576936006546,
-0.018522636964917183,
-0.004334297031164169,
0.012182602658867836,
-0.013653828762471676,
0.051101308315992355,
0.009457129053771496,
0.037765007466077805,
0.03520359471440315,
-0.04449666291475296,
-0.05592777580022812,
-0.032007116824388504,
-0.006345326080918312,
0.018596727401018143,
-0.03543644770979881,
-0.06346384435892105,
0.0013746442273259163,
0.010600239969789982,
0.029445698484778404,
0.031731922179460526,
0.00991225615143776,
0.040241751819849014,
0.004085564520210028,
-0.023899493739008904,
-0.01505096536129713,
-0.010621408931910992,
-0.00832989439368248,
0.07523365318775177,
0.012838833034038544,
0.05770594999194145,
0.022819887846708298,
-0.02233300730586052,
0.04420030117034912,
-0.000049200752982869744,
0.023518456146121025,
-0.03683358430862427,
0.028429601341485977,
0.026460908353328705,
-0.026630258187651634,
0.0022835764102637768,
0.014034866355359554,
-0.03933149576187134,
-0.023941829800605774,
0.03329840674996376,
0.05808698758482933,
0.03856942057609558,
-0.04364991560578346,
0.0552503764629364,
-0.0007342902245000005,
-0.003947967663407326,
-0.028260251507163048,
0.03630436584353447,
-0.05211740732192993,
-0.06812096387147903,
-0.03077933005988598,
-0.026037534698843956,
0.02235417626798153,
-0.005948412232100964,
-0.06786693632602692,
0.0009777306113392115,
-0.034483857452869415,
-0.017178421840071678,
-0.010473228059709072,
0.02521195448935032,
-0.010340923443436623,
0.043120697140693665,
-0.014542915858328342,
-0.0073402561247348785,
0.028366094455122948,
-0.008171129040420055,
0.01910477690398693,
0.054234277456998825,
-0.04089798033237457,
-0.03403931483626366,
0.04403095319867134,
-0.013357467018067837,
0.012669483199715614,
0.05444596707820892,
0.03075816109776497,
-0.0616433322429657,
0.021105220541357994,
-0.011325269006192684,
0.02495792880654335,
0.03543644770979881,
0.014458240941166878,
0.015686025843024254,
-0.026460908353328705,
-0.03823072090744972,
-0.005625589285045862,
0.007520190440118313,
0.010166280902922153,
0.020163211971521378,
-0.04678288847208023,
0.05571608990430832,
0.012288445606827736,
0.0110924132168293,
-0.0025693541392683983,
0.010594948194921017,
0.029043493792414665,
-0.013389219529926777,
-0.024132348597049713,
-0.017601797357201576,
0.03793435916304588,
0.01982451230287552,
0.013061104342341423,
-0.03323490172624588,
-0.08729983121156693,
0.028366094455122948,
0.0337006151676178,
0.03590216115117073,
0.01928471028804779,
0.04966183379292488,
-0.045724451541900635,
0.02201547659933567,
-0.03406048193573952,
0.017411278560757637,
0.04155421257019043,
0.03365827724337578,
0.03962785750627518,
0.05334519222378731,
-0.04121551290154457,
-0.030504135414958,
-0.05779062584042549,
-0.02188846468925476,
0.005784354638308287,
0.037151116877794266,
0.07459859549999237,
0.018882503733038902,
0.021560348570346832,
0.010526149533689022,
0.056986212730407715
]
|
32,067 | pingouin.nonparametric | wilcoxon |
Wilcoxon signed-rank test. It is the non-parametric version of the paired T-test.
Parameters
----------
x : array_like
Either the first set of measurements
(in which case y is the second set of measurements),
or the differences between two sets of measurements
(in which case y is not to be specified.) Must be one-dimensional.
y : array_like
Either the second set of measurements (if x is the first set of
measurements), or not specified (if x is the differences between
two sets of measurements.) Must be one-dimensional.
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of
"two-sided" (default), "greater" or "less". See :py:func:`scipy.stats.wilcoxon` for
more details.
**kwargs : dict
Additional keywords arguments that are passed to :py:func:`scipy.stats.wilcoxon`.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'W-val'``: W-value
* ``'alternative'``: tail of the test
* ``'p-val'``: p-value
* ``'RBC'`` : matched pairs rank-biserial correlation (effect size)
* ``'CLES'`` : common language effect size
See also
--------
scipy.stats.wilcoxon, mwu
Notes
-----
The Wilcoxon signed-rank test [1]_ tests the null hypothesis that two
related paired samples come from the same distribution. In particular,
it tests whether the distribution of the differences x - y is symmetric
about zero.
.. important:: Pingouin automatically applies a continuity correction.
Therefore, the p-values will be slightly different than
:py:func:`scipy.stats.wilcoxon` unless ``correction=True`` is
explicitly passed to the latter.
In addition to the test statistic and p-values, Pingouin also computes two
measures of effect size. The matched pairs rank biserial correlation [2]_
is the simple difference between the proportion of favorable and
unfavorable evidence; in the case of the Wilcoxon signed-rank test,
the evidence consists of rank sums (Kerby 2014):
.. math:: r = f - u
The common language effect size is the proportion of pairs where ``x`` is
higher than ``y``. It was first introduced by McGraw and Wong (1992) [3]_.
Pingouin uses a brute-force version of the formula given by Vargha and
Delaney 2000 [4]_:
.. math:: \text{CL} = P(X > Y) + .5 \times P(X = Y)
The advantage is of this method are twofold. First, the brute-force
approach pairs each observation of ``x`` to its ``y`` counterpart, and
therefore does not require normally distributed data. Second, the formula
takes ties into account and therefore works with ordinal data.
When tail is ``'less'``, the CLES is then set to :math:`1 - \text{CL}`,
which gives the proportion of pairs where ``x`` is *lower* than ``y``.
References
----------
.. [1] Wilcoxon, F. (1945). Individual comparisons by ranking methods.
Biometrics bulletin, 1(6), 80-83.
.. [2] Kerby, D. S. (2014). The simple difference formula: An approach to
teaching nonparametric correlation. Comprehensive Psychology,
3, 11-IT.
.. [3] McGraw, K. O., & Wong, S. P. (1992). A common language effect size
statistic. Psychological bulletin, 111(2), 361.
.. [4] Vargha, A., & Delaney, H. D. (2000). A Critique and Improvement of
the “CL” Common Language Effect Size Statistics of McGraw and Wong.
Journal of Educational and Behavioral Statistics: A Quarterly
Publication Sponsored by the American Educational Research
Association and the American Statistical Association, 25(2),
101–132. https://doi.org/10.2307/1165329
Examples
--------
Wilcoxon test on two related samples.
>>> import numpy as np
>>> import pingouin as pg
>>> x = np.array([20, 22, 19, 20, 22, 18, 24, 20, 19, 24, 26, 13])
>>> y = np.array([38, 37, 33, 29, 14, 12, 20, 22, 17, 25, 26, 16])
>>> pg.wilcoxon(x, y, alternative='two-sided')
W-val alternative p-val RBC CLES
Wilcoxon 20.5 two-sided 0.285765 -0.378788 0.395833
Same but using pre-computed differences. However, the CLES effect size
cannot be computed as it requires the raw data.
>>> pg.wilcoxon(x - y)
W-val alternative p-val RBC CLES
Wilcoxon 20.5 two-sided 0.285765 -0.378788 NaN
Compare with SciPy
>>> import scipy
>>> scipy.stats.wilcoxon(x, y)
WilcoxonResult(statistic=20.5, pvalue=0.2661660677806492)
The p-value is not exactly similar to Pingouin. This is because Pingouin automatically applies
a continuity correction. Disabling it gives the same p-value as scipy:
>>> pg.wilcoxon(x, y, alternative='two-sided', correction=False)
W-val alternative p-val RBC CLES
Wilcoxon 20.5 two-sided 0.266166 -0.378788 0.395833
One-sided test
>>> pg.wilcoxon(x, y, alternative='greater')
W-val alternative p-val RBC CLES
Wilcoxon 20.5 greater 0.876244 -0.378788 0.395833
>>> pg.wilcoxon(x, y, alternative='less')
W-val alternative p-val RBC CLES
Wilcoxon 20.5 less 0.142883 -0.378788 0.604167
| def wilcoxon(x, y=None, alternative="two-sided", **kwargs):
"""
Wilcoxon signed-rank test. It is the non-parametric version of the paired T-test.
Parameters
----------
x : array_like
Either the first set of measurements
(in which case y is the second set of measurements),
or the differences between two sets of measurements
(in which case y is not to be specified.) Must be one-dimensional.
y : array_like
Either the second set of measurements (if x is the first set of
measurements), or not specified (if x is the differences between
two sets of measurements.) Must be one-dimensional.
alternative : string
Defines the alternative hypothesis, or tail of the test. Must be one of
"two-sided" (default), "greater" or "less". See :py:func:`scipy.stats.wilcoxon` for
more details.
**kwargs : dict
Additional keywords arguments that are passed to :py:func:`scipy.stats.wilcoxon`.
Returns
-------
stats : :py:class:`pandas.DataFrame`
* ``'W-val'``: W-value
* ``'alternative'``: tail of the test
* ``'p-val'``: p-value
* ``'RBC'`` : matched pairs rank-biserial correlation (effect size)
* ``'CLES'`` : common language effect size
See also
--------
scipy.stats.wilcoxon, mwu
Notes
-----
The Wilcoxon signed-rank test [1]_ tests the null hypothesis that two
related paired samples come from the same distribution. In particular,
it tests whether the distribution of the differences x - y is symmetric
about zero.
.. important:: Pingouin automatically applies a continuity correction.
Therefore, the p-values will be slightly different than
:py:func:`scipy.stats.wilcoxon` unless ``correction=True`` is
explicitly passed to the latter.
In addition to the test statistic and p-values, Pingouin also computes two
measures of effect size. The matched pairs rank biserial correlation [2]_
is the simple difference between the proportion of favorable and
unfavorable evidence; in the case of the Wilcoxon signed-rank test,
the evidence consists of rank sums (Kerby 2014):
.. math:: r = f - u
The common language effect size is the proportion of pairs where ``x`` is
higher than ``y``. It was first introduced by McGraw and Wong (1992) [3]_.
Pingouin uses a brute-force version of the formula given by Vargha and
Delaney 2000 [4]_:
.. math:: \\text{CL} = P(X > Y) + .5 \\times P(X = Y)
The advantage is of this method are twofold. First, the brute-force
approach pairs each observation of ``x`` to its ``y`` counterpart, and
therefore does not require normally distributed data. Second, the formula
takes ties into account and therefore works with ordinal data.
When tail is ``'less'``, the CLES is then set to :math:`1 - \\text{CL}`,
which gives the proportion of pairs where ``x`` is *lower* than ``y``.
References
----------
.. [1] Wilcoxon, F. (1945). Individual comparisons by ranking methods.
Biometrics bulletin, 1(6), 80-83.
.. [2] Kerby, D. S. (2014). The simple difference formula: An approach to
teaching nonparametric correlation. Comprehensive Psychology,
3, 11-IT.
.. [3] McGraw, K. O., & Wong, S. P. (1992). A common language effect size
statistic. Psychological bulletin, 111(2), 361.
.. [4] Vargha, A., & Delaney, H. D. (2000). A Critique and Improvement of
the “CL” Common Language Effect Size Statistics of McGraw and Wong.
Journal of Educational and Behavioral Statistics: A Quarterly
Publication Sponsored by the American Educational Research
Association and the American Statistical Association, 25(2),
101–132. https://doi.org/10.2307/1165329
Examples
--------
Wilcoxon test on two related samples.
>>> import numpy as np
>>> import pingouin as pg
>>> x = np.array([20, 22, 19, 20, 22, 18, 24, 20, 19, 24, 26, 13])
>>> y = np.array([38, 37, 33, 29, 14, 12, 20, 22, 17, 25, 26, 16])
>>> pg.wilcoxon(x, y, alternative='two-sided')
W-val alternative p-val RBC CLES
Wilcoxon 20.5 two-sided 0.285765 -0.378788 0.395833
Same but using pre-computed differences. However, the CLES effect size
cannot be computed as it requires the raw data.
>>> pg.wilcoxon(x - y)
W-val alternative p-val RBC CLES
Wilcoxon 20.5 two-sided 0.285765 -0.378788 NaN
Compare with SciPy
>>> import scipy
>>> scipy.stats.wilcoxon(x, y)
WilcoxonResult(statistic=20.5, pvalue=0.2661660677806492)
The p-value is not exactly similar to Pingouin. This is because Pingouin automatically applies
a continuity correction. Disabling it gives the same p-value as scipy:
>>> pg.wilcoxon(x, y, alternative='two-sided', correction=False)
W-val alternative p-val RBC CLES
Wilcoxon 20.5 two-sided 0.266166 -0.378788 0.395833
One-sided test
>>> pg.wilcoxon(x, y, alternative='greater')
W-val alternative p-val RBC CLES
Wilcoxon 20.5 greater 0.876244 -0.378788 0.395833
>>> pg.wilcoxon(x, y, alternative='less')
W-val alternative p-val RBC CLES
Wilcoxon 20.5 less 0.142883 -0.378788 0.604167
"""
x = np.asarray(x)
if y is not None:
y = np.asarray(y)
x, y = remove_na(x, y, paired=True) # Remove NA
else:
x = x[~np.isnan(x)]
# Check tails
assert alternative in [
"two-sided",
"greater",
"less",
], "Alternative must be one of 'two-sided' (default), 'greater' or 'less'."
if "tail" in kwargs:
raise ValueError(
"Since Pingouin 0.4.0, the 'tail' argument has been renamed to 'alternative'."
)
# Compute test
if "correction" not in kwargs:
kwargs["correction"] = True
wval, pval = scipy.stats.wilcoxon(x=x, y=y, alternative=alternative, **kwargs)
# Effect size 1: Common Language Effect Size
# Since Pingouin v0.3.5, CLES is tail-specific and calculated
# according to the formula given in Vargha and Delaney 2000 which
# works with ordinal data.
if y is not None:
diff = x[:, None] - y
# cles = max((diff < 0).sum(), (diff > 0).sum()) / diff.size
# alternative = 'greater', with ties set to 0.5
# Note that alternative = 'two-sided' gives same output as alternative = 'greater'
cles = np.where(diff == 0, 0.5, diff > 0).mean()
cles = 1 - cles if alternative == "less" else cles
else:
# CLES cannot be computed if y is None
cles = np.nan
# Effect size 2: matched-pairs rank biserial correlation (Kerby 2014)
if y is not None:
d = x - y
d = d[d != 0]
else:
d = x[x != 0]
r = scipy.stats.rankdata(abs(d))
rsum = r.sum()
r_plus = np.sum((d > 0) * r)
r_minus = np.sum((d < 0) * r)
rbc = r_plus / rsum - r_minus / rsum
# Fill output DataFrame
stats = pd.DataFrame(
{"W-val": wval, "alternative": alternative, "p-val": pval, "RBC": rbc, "CLES": cles},
index=["Wilcoxon"],
)
return _postprocess_dataframe(stats)
| (x, y=None, alternative='two-sided', **kwargs) | [
-0.02517358586192131,
-0.007044079247862101,
0.03743131086230278,
0.004797172266989946,
0.07009115815162659,
-0.030582616105675697,
-0.04779690504074097,
0.0026865191757678986,
0.061165232211351395,
0.020463820546865463,
-0.00023346366651821882,
0.03498388081789017,
0.07749515771865845,
0.027991216629743576,
-0.06799335777759552,
0.016504740342497826,
-0.01859225519001484,
-0.01921953819692135,
0.03128188103437424,
0.013142092153429985,
0.00514937611296773,
-0.006062021479010582,
0.02021702192723751,
0.06124749779701233,
-0.018407156690955162,
0.04380697384476662,
-0.053473301231861115,
0.01624765805900097,
-0.07622002065181732,
-0.01060211006551981,
-0.03521011397242546,
-0.007234320975840092,
0.007074929308146238,
-0.07087269425392151,
0.02988334931433201,
0.02243822067975998,
0.05051170289516449,
-0.0003284237754996866,
-0.12068513035774231,
-0.027353649958968163,
-0.018705371767282486,
-0.028998984023928642,
0.02807348407804966,
0.01685437373816967,
-0.04265524074435234,
0.006247121375054121,
-0.04113331064581871,
0.07342296093702316,
-0.026613250374794006,
-0.004902576096355915,
0.009789727628231049,
-0.05528316646814346,
0.025831717997789383,
0.01605227403342724,
0.016895506531000137,
0.013028975576162338,
0.00221605715341866,
0.06017803028225899,
0.056229233741760254,
-0.049565639346838,
0.010684377513825893,
0.07383429259061813,
0.03438744693994522,
-0.035004448145627975,
0.01121911033987999,
-0.022787854075431824,
0.01780043914914131,
-0.024433186277747154,
0.008442611433565617,
0.01649445667862892,
0.008216378279030323,
0.033359114080667496,
-0.0008657276048325002,
-0.0001372181432088837,
-0.02640758454799652,
-0.027147984132170677,
0.013851641677320004,
-0.02272615395486355,
0.007018371019512415,
-0.013759092427790165,
0.0030027315951883793,
0.04598703980445862,
0.019404638558626175,
-0.0476323738694191,
0.021101387217640877,
-0.021121954545378685,
0.03932344540953636,
0.04393037408590317,
0.03987874463200569,
0.015568957664072514,
-0.0500592365860939,
0.019384071230888367,
0.0737520232796669,
-0.01927095465362072,
-0.012463392689824104,
0.04249070957303047,
-0.017779873684048653,
0.011435059830546379,
0.03932344540953636,
0.017162872478365898,
-0.025831717997789383,
0.040927641093730927,
-0.02217085286974907,
0.04779690504074097,
-0.0010225484147667885,
0.03150811418890953,
-0.016124257817864418,
0.03794547915458679,
-0.05569450184702873,
-0.061288632452487946,
-0.06453816592693329,
-0.06548422574996948,
0.007157195825129747,
-0.06832242757081985,
0.05836816504597664,
-0.011496759951114655,
-0.07288822531700134,
0.02544095180928707,
-0.019476622343063354,
0.017646189779043198,
-0.003432060591876507,
-0.02186235412955284,
0.014787424355745316,
-0.041092175990343094,
-0.02059750445187092,
-0.011568743735551834,
0.06778769195079803,
-0.015867173671722412,
0.002081088488921523,
0.049072038382291794,
-0.011784693226218224,
-0.009275561198592186,
-0.016669273376464844,
0.05791569873690605,
-0.011085426434874535,
0.007542820647358894,
0.027065716683864594,
-0.011537893675267696,
0.05215703696012497,
-0.061576563864946365,
0.050840768963098526,
0.049195438623428345,
0.0014319532783702016,
0.03358534723520279,
-0.008828236721456051,
0.045082107186317444,
0.010571260936558247,
-0.012566225603222847,
0.04516437277197838,
0.008895077742636204,
-0.019116705283522606,
-0.042860910296440125,
0.019980505108833313,
-0.058285899460315704,
0.00036762896343134344,
-0.03124074824154377,
0.010910610668361187,
-0.010746076703071594,
0.013594558462500572,
0.003601735457777977,
0.00763537036255002,
-0.012535376474261284,
0.01583632454276085,
0.056476034224033356,
-0.018150072544813156,
-0.010632960125803947,
0.015599807724356651,
-0.023713352158665657,
0.04841390624642372,
-0.02086487039923668,
0.01362540852278471,
-0.023733919486403465,
-0.006504204589873552,
-0.012782176025211811,
-0.00027347225113771856,
-0.0005565850879065692,
-0.03613561391830444,
-0.05182797089219093,
-0.028155749663710594,
-0.016957206651568413,
0.011085426434874535,
-0.02311692014336586,
-0.026201918721199036,
-0.03864474594593048,
-0.07173649221658707,
0.03757527843117714,
0.07482148706912994,
0.005195651203393936,
0.020391838625073433,
0.02819688431918621,
-0.002529698424041271,
-0.017707889899611473,
0.013573992066085339,
0.02932805009186268,
0.041482944041490555,
-0.024433186277747154,
0.026119651272892952,
0.00219420506618917,
-0.009836002252995968,
-0.0398993119597435,
-0.023055220022797585,
0.038459643721580505,
0.013059825636446476,
-0.02614021860063076,
0.03806887939572334,
-0.004334422294050455,
-0.01755364052951336,
0.02505018562078476,
-0.051663435995578766,
-0.029801081866025925,
0.08498141914606094,
0.004632638767361641,
-0.030109582468867302,
0.005583846941590309,
-0.02819688431918621,
-0.001925553078763187,
0.018900755792856216,
-0.021924054250121117,
-0.024556586518883705,
-0.054295968264341354,
0.012504526413977146,
0.008982486091554165,
-0.03815114498138428,
0.046028174459934235,
0.03354421257972717,
0.015435274690389633,
0.029142949730157852,
0.05215703696012497,
0.08884795010089874,
-0.06338643282651901,
0.0007706068572588265,
0.05487183481454849,
-0.000631460570730269,
-0.02906068228185177,
-0.024453751742839813,
-0.08983514457941055,
-0.03549804538488388,
-0.0070646461099386215,
-0.03975534439086914,
-0.0054501635022461414,
-0.025379251688718796,
-0.06540196388959885,
0.0336059145629406,
0.013059825636446476,
-0.03586824610829353,
-0.02891671657562256,
0.02461828477680683,
0.0050619677640497684,
-0.0072394623421132565,
0.018150072544813156,
0.028381982818245888,
-0.09493567794561386,
-0.019867388531565666,
-0.05499523505568504,
-0.018808206543326378,
-0.0217595212161541,
-0.049894705414772034,
-0.027168551459908485,
0.021718386560678482,
-0.06811676174402237,
0.009990252554416656,
0.016165390610694885,
-0.037636976689100266,
0.02161555364727974,
-0.03303004801273346,
-0.025379251688718796,
-0.04212050884962082,
0.03564201295375824,
-0.004730330780148506,
0.01113684382289648,
-0.05281516909599304,
-0.012370842508971691,
-0.01844828948378563,
-0.019743988290429115,
-0.07079042494297028,
0.0063088214956223965,
0.0379660427570343,
-0.010077660903334618,
0.049195438623428345,
0.008164961822330952,
-0.003956510219722986,
-0.01876707188785076,
-0.028690483421087265,
-0.0053473301231861115,
0.006324246525764465,
-0.04172974079847336,
-0.008848803117871284,
-0.014972524717450142,
0.01315237581729889,
-0.01694692298769951,
-0.03726677969098091,
-0.023158052936196327,
0.012154893018305302,
-0.004349847324192524,
0.023055220022797585,
0.042326174676418304,
-0.009013336151838303,
-0.05474843457341194,
0.0011285952059552073,
0.010900327004492283,
0.013512291945517063,
-0.006529912818223238,
-0.0019731135107576847,
-0.005712388549000025,
-0.0010418295860290527,
0.04119500890374184,
0.08321268856525421,
-0.07005002349615097,
-0.021533288061618805,
0.0030258691404014826,
-0.01876707188785076,
0.014314391650259495,
0.008915645070374012,
-0.004162176977843046,
0.02000107243657112,
-0.030582616105675697,
0.02451545186340809,
0.021841786801815033,
0.03000674955546856,
0.05886176601052284,
0.0386858768761158,
-0.03636184707283974,
0.04853730648756027,
0.04144180938601494,
-0.003617160487920046,
-0.011270526796579361,
-0.009470944292843342,
-0.005419313441962004,
0.043436773121356964,
-0.050018105655908585,
-0.06972096115350723,
0.006648171227425337,
-0.021944619715213776,
0.01721429079771042,
0.02350768633186817,
0.0268394835293293,
0.017275989055633545,
0.01694692298769951,
0.0514989048242569,
-0.026757217943668365,
-0.0017186010954901576,
0.01760505698621273,
-0.034737080335617065,
-0.007928445003926754,
0.03109678253531456,
-0.039837609976530075,
-0.016936639323830605,
0.002075946656987071,
0.015383857302367687,
-0.009100744500756264,
0.036279577761888504,
0.06293396651744843,
0.018201489001512527,
0.03187831491231918,
0.021224787458777428,
0.05762776732444763,
-0.027847250923514366,
-0.01726570725440979,
0.02173895388841629,
0.04940110445022583,
-0.03333854675292969,
0.041092175990343094,
0.0007108349818736315,
0.019291521981358528,
-0.022685019299387932,
0.003504043910652399,
0.0398993119597435,
0.03412007912993431,
-0.0870380848646164,
-0.0323924794793129,
-0.04467077553272247,
-0.03755471110343933,
-0.047262173146009445,
-0.0008952922071330249,
0.00946580246090889,
0.042572975158691406,
-0.007033796049654484,
-0.02669551782310009,
-0.011383643373847008,
-0.01769760623574257,
0.05573563277721405,
0.022664453834295273,
-0.05618809908628464,
0.020134754478931427,
-0.0001555353228468448,
0.02778555080294609,
-0.05116983875632286,
-0.00435241824015975,
-0.04783803969621658,
-0.014201275072991848,
0.03165208175778389,
-0.03315344825387001,
0.011620160192251205,
0.041359543800354004,
-0.037924911826848984,
0.02875218354165554,
0.02519415132701397,
0.018653955310583115,
-0.04471190646290779,
-0.006555621046572924,
0.041647475212812424,
-0.0003210326249245554,
-0.04446510598063469,
-0.012936425395309925,
-0.07749515771865845,
-0.024782819673419,
-0.007522253785282373,
0.03325628116726875,
-0.038027744740247726,
0.07074929028749466,
-0.061576563864946365,
0.029965616762638092,
-0.02299351990222931,
-0.04417717456817627,
-0.034819345921278,
0.00814953725785017,
-0.02282898686826229,
0.0062831128016114235,
0.03899437561631203,
-0.014232125133275986,
0.07654909044504166,
-0.09411301463842392,
0.07679589092731476,
0.008745970204472542,
0.047550104558467865,
-0.0437658429145813,
0.013563708402216434,
-0.08193755149841309,
0.012669059447944164,
0.012206309475004673,
-0.006894970778375864,
-0.017018906772136688,
-0.02626361884176731,
-0.03303004801273346,
0.02202688716351986,
-0.02889614924788475,
0.0009743452537804842,
0.03981704264879227,
-0.009188152849674225,
0.0279295165091753,
-0.03739017993211746,
0.05503636971116066,
0.028957849368453026,
0.019692571833729744,
-0.08999968320131302,
0.032269082963466644,
-0.0042110225185751915,
-0.05943763256072998,
-0.07663135230541229,
-0.011126560159027576,
0.04224390909075737,
0.013872209005057812,
0.07173649221658707,
0.010190777480602264,
-0.0217595212161541,
-0.015702640637755394,
-0.06544309854507446,
0.009440094232559204,
-0.04068084433674812,
-0.012566225603222847,
0.020114189013838768,
-0.027312517166137695,
-0.0013265492161735892,
-0.02887558378279209,
-0.05602356791496277,
0.0669650286436081,
-0.01590830832719803,
-0.0001418777828803286,
0.05293856933712959,
0.03483991324901581,
0.043148841708898544,
0.03298891335725784,
-0.006324246525764465,
0.007877028547227383,
0.069638691842556,
0.0087048364803195,
-0.10127020627260208,
0.028546515852212906,
0.05672283470630646,
-0.03730791062116623,
-0.05047057196497917,
0.04977130517363548,
0.0619056299328804,
-0.0367526113986969,
-0.005527288652956486,
-0.0418325774371624,
-0.02959541603922844,
-0.03837737813591957,
0.05499523505568504,
-0.014211558736860752,
0.04804370552301407,
0.08925928175449371,
0.025523219257593155,
-0.018489422276616096,
-0.0957583412528038,
0.02093685418367386,
0.012576509267091751,
-0.051951371133327484,
0.0669650286436081,
-0.026654385030269623,
0.019723420962691307,
0.022746719419956207,
-0.07223009318113327,
-0.07720722258090973,
0.01951775513589382,
-0.012226875871419907,
-0.02256162092089653,
-0.011990359984338284,
-0.008175245486199856,
-0.0035734563134610653,
-0.008905361406505108,
-0.06803449243307114,
0.047385573387145996,
-0.012021210044622421,
0.0159597247838974,
-0.016309356316924095,
0.005650688428431749,
0.10094114392995834,
0.013913341797888279,
-0.05684623494744301,
0.03352364897727966,
-0.011651010252535343,
0.042202774435281754,
0.03344137966632843,
0.04123614355921745,
0.009774303063750267,
-0.03496331349015236,
0.001942263450473547,
-0.005691821686923504,
0.014334958046674728,
-0.027065716683864594,
-0.034037813544273376,
-0.05836816504597664,
0.00773820374161005,
0.005105671938508749,
-0.02642815187573433,
-0.0558590330183506,
-0.002192919608205557,
0.05462503433227539,
0.04915430396795273,
-0.00636537978425622,
-0.051128704100847244,
0.05989009886980057,
-0.01746108941733837,
0.01211375929415226,
0.013028975576162338,
-0.0065710460767149925,
0.04156520962715149,
-0.048208240419626236,
0.0023703069891780615,
-0.0037585562095046043,
-0.07531508803367615,
-0.018499705940485,
0.038336243480443954,
0.029759949073195457,
0.042202774435281754,
0.035025011748075485,
0.01093117706477642,
-0.03613561391830444,
0.028937283903360367,
-0.032536447048187256,
-0.04717990756034851,
0.05956103280186653,
-0.06708842515945435,
-0.0004852444981224835,
0.052239302545785904,
0.03685544431209564,
0.014756575226783752,
-0.050018105655908585,
-0.013573992066085339,
0.019024156033992767,
0.08263681828975677,
-0.0009859140263870358,
-0.010643243789672852,
-0.022253120318055153,
0.0015167908277362585,
0.02072090469300747,
-0.007033796049654484,
-0.005185368005186319,
-0.03340024873614311,
-0.022952387109398842,
-0.005013122223317623,
0.04804370552301407,
-0.0737520232796669,
0.04857843741774559,
0.030438648536801338,
-0.04172974079847336,
0.024124685674905777,
0.030109582468867302,
0.028320282697677612,
-0.02367221936583519,
0.014736007899045944,
-0.040104977786540985,
-0.044794175773859024,
0.03109678253531456,
0.0051699429750442505,
-0.00790787860751152,
0.013594558462500572,
0.0877784788608551,
0.050182636827230453,
-0.00615971302613616,
0.011969792656600475,
-0.005645546596497297,
-0.045370038598775864,
-0.005239355377852917,
-0.018777355551719666,
0.009219002909958363,
-0.06137089803814888,
0.02778555080294609,
-0.04113331064581871,
0.009049328044056892,
0.003699427004903555,
-0.059355366975069046,
-0.042285043746232986,
0.017810722813010216,
-0.015898024663329124,
-0.005558138247579336,
-0.03438744693994522,
0.03272154927253723,
-0.024145253002643585,
0.020052488893270493,
0.03251587972044945,
0.0182529054582119,
0.007198329083621502,
0.00481773866340518,
0.008339778520166874,
0.0105198435485363,
-0.022068019956350327,
0.0032572438940405846,
0.004072197712957859,
0.029225217178463936,
0.012206309475004673,
0.06700616329908371,
-0.02340485341846943,
-0.06276942789554596,
0.039837609976530075,
0.005110813770443201,
-0.02350768633186817,
-0.01471544150263071,
0.056887365877628326,
0.004971988964825869,
0.023034652695059776,
0.05902630090713501,
0.00773820374161005,
-0.028525950387120247,
0.01721429079771042,
0.02059750445187092,
-0.012134326621890068,
-0.0079798623919487,
-0.029533715918660164,
0.011229393072426319,
-0.008278078399598598,
0.0014769429108127952,
-0.02753875032067299,
0.009100744500756264,
-0.00950179435312748,
-0.007224037311971188,
0.038603611290454865,
0.031981147825717926,
-0.049359969794750214,
0.04985357075929642,
-0.0004807455406989902,
0.020885437726974487,
0.022253120318055153,
0.06980322301387787,
0.021965187042951584,
0.06470269709825516,
-0.015527823939919472,
-0.051540035754442215,
-0.012905576266348362,
0.05701076611876488,
0.023836752399802208,
-0.012124042958021164,
-0.04845503717660904,
0.008442611433565617,
-0.02089572139084339,
-0.048084840178489685,
0.06523742526769638,
-0.036238446831703186,
-0.011733276769518852,
0.011609876528382301,
0.030993947759270668,
-0.0005498366663232446,
-0.027333084493875504,
0.052362702786922455,
-0.006766429170966148,
-0.013594558462500572,
-0.004154464229941368,
-0.028381982818245888,
-0.0025515505112707615,
0.006051738280802965,
0.02381618693470955,
0.02435091882944107,
0.029780516400933266,
-0.0021736384369432926,
-0.02850538305938244,
-0.022458786144852638,
0.011671576648950577,
0.03041808307170868,
-0.056352633982896805,
0.012710192240774632,
0.002658240031450987,
0.0279295165091753,
-0.0007333297980949283,
-0.033914413303136826,
0.001120882690884173,
0.008869369514286518,
-0.045740239322185516,
0.0960051417350769,
-0.017594773322343826,
-0.05067623779177666,
0.05943763256072998,
-0.012514809146523476,
-0.04915430396795273,
-0.012689625844359398,
0.0168029572814703,
-0.037636976689100266,
0.0309528149664402,
-0.020412404090166092,
-0.0009094317792914808,
0.009064752608537674,
0.03991987556219101,
0.0007969578728079796,
0.004460393451154232,
-0.004401264246553183,
0.019795404747128487,
0.1001184731721878,
-0.028258584439754486,
0.01046842709183693,
-0.05310310423374176,
0.02877275086939335,
0.000754539156332612,
-0.018078088760375977,
0.052897434681653976,
0.03276268020272255,
0.027847250923514366,
0.005031117703765631,
-0.035148411989212036,
0.05832703411579132,
-0.02028900571167469,
-0.03270098194479942,
0.016813240945339203,
-0.0018959884764626622,
-0.11542006582021713,
-0.003943656105548143,
0.03800717741250992,
0.0018805634463205934,
0.012514809146523476,
0.05075850337743759,
0.002190348692238331,
0.053720101714134216,
-0.02447431907057762,
-0.003043864853680134,
-0.0418325774371624,
0.061864499002695084,
0.055365435779094696,
0.006540196016430855,
-0.04265524074435234,
-0.032557014375925064,
-0.04783803969621658,
-0.024865085259079933,
0.021533288061618805,
0.007589095737785101,
0.06042483076453209,
-0.0023870174773037434,
0.025009052827954292,
-0.0259962510317564,
0.06778769195079803
]
|
32,068 | bqplot.scales | Albers | A geographical scale which is an alias for a conic equal area projection.
The Albers projection is a conic equal area map. It does not preserve scale
or shape, though it is recommended for chloropleths since it preserves the
relative areas of geographic features. Default values are US-centric.
Attributes
----------
scale_factor: float (default: 250)
Specifies the scale value for the projection
rotate: tuple (default: (96, 0))
Degree of rotation in each axis.
parallels: tuple (default: (29.5, 45.5))
Sets the two parallels for the conic projection.
center: tuple (default: (0, 60))
Specifies the longitude and latitude where the map is centered.
precision: float (default: 0.1)
Specifies the threshold for the projections adaptive resampling to the
specified value in pixels.
rtype: (Number, Number) (class-level attribute)
This attribute should not be modified. The range type of a geo
scale is a tuple.
dtype: type (class-level attribute)
the associated data type / domain type
| class Albers(GeoScale):
"""A geographical scale which is an alias for a conic equal area projection.
The Albers projection is a conic equal area map. It does not preserve scale
or shape, though it is recommended for chloropleths since it preserves the
relative areas of geographic features. Default values are US-centric.
Attributes
----------
scale_factor: float (default: 250)
Specifies the scale value for the projection
rotate: tuple (default: (96, 0))
Degree of rotation in each axis.
parallels: tuple (default: (29.5, 45.5))
Sets the two parallels for the conic projection.
center: tuple (default: (0, 60))
Specifies the longitude and latitude where the map is centered.
precision: float (default: 0.1)
Specifies the threshold for the projections adaptive resampling to the
specified value in pixels.
rtype: (Number, Number) (class-level attribute)
This attribute should not be modified. The range type of a geo
scale is a tuple.
dtype: type (class-level attribute)
the associated data type / domain type
"""
scale_factor = Float(250).tag(sync=True)
rotate = Tuple((96, 0)).tag(sync=True)
center = Tuple((0, 60)).tag(sync=True)
parallels = Tuple((29.5, 45.5)).tag(sync=True)
precision = Float(0.1).tag(sync=True)
rtype = '(Number, Number)'
dtype = np.number
_view_name = Unicode('Albers').tag(sync=True)
_model_name = Unicode('AlbersModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.01515866257250309,
-0.09210604429244995,
0.0024386669974774122,
0.08690355718135834,
-0.030115818604826927,
-0.04740860313177109,
-0.06404191255569458,
-0.08382602781057358,
-0.006480213720351458,
-0.050339583307504654,
-0.013546623289585114,
-0.00163035758305341,
0.023814212530851364,
0.0662035122513771,
-0.038139376789331436,
-0.019179601222276688,
-0.03788291662931442,
0.007620547898113728,
0.010441616177558899,
-0.0015731119783595204,
0.005330719985067844,
-0.026104040443897247,
0.0364723838865757,
0.02680014818906784,
-0.009864579886198044,
0.04282894358038902,
0.029786083847284317,
-0.007322870194911957,
-0.020187124609947205,
-0.018648359924554825,
-0.07397060841321945,
-0.03689371049404144,
-0.007038931827992201,
0.009544003754854202,
0.035574771463871,
-0.07217538356781006,
0.033248305320739746,
0.03348644822835922,
-0.0340726412832737,
-0.010331704281270504,
0.0027271853759884834,
-0.019472697749733925,
0.02405235543847084,
-0.03348644822835922,
0.03839583694934845,
0.012914630584418774,
-0.006773311644792557,
-0.004849855788052082,
-0.03240564838051796,
0.003283613594248891,
-0.01910632662475109,
-0.031837768852710724,
0.007684663403779268,
0.03412759676575661,
-0.02267845720052719,
0.05770367011427879,
0.016129549592733383,
0.09445083141326904,
0.016285257413983345,
-0.010469093918800354,
-0.037699729204177856,
-0.048580992966890335,
-0.009424932301044464,
-0.09188622236251831,
-0.003917895723134279,
0.014196934178471565,
-0.03674716129899025,
-0.0015318950172513723,
0.033871136605739594,
0.02394244261085987,
0.03916522115468979,
-0.02102978155016899,
0.00829375721514225,
0.004130850080400705,
0.03953159227967262,
0.06199022755026817,
-0.05455286428332329,
0.06774227321147919,
0.022312086075544357,
-0.03938504308462143,
0.005894017405807972,
-0.011439980939030647,
0.05059604346752167,
-0.02575598657131195,
0.028632011264562607,
-0.0865371823310852,
0.01780570298433304,
-0.006045146379619837,
0.027642805129289627,
-0.0388721227645874,
-0.03365131467580795,
-0.011540734209120274,
0.047811612486839294,
0.02767944149672985,
0.024528639391064644,
-0.002294407691806555,
-0.0146640595048666,
0.017219508066773415,
0.011201838962733746,
0.00971803069114685,
0.009983650408685207,
-0.03253387659788132,
-0.019527655094861984,
0.029016701504588127,
-0.009397454559803009,
0.014984635636210442,
0.017549242824316025,
-0.023704301565885544,
-0.044734083116054535,
0.046932317316532135,
-0.05345374718308449,
0.08111487329006195,
-0.025407932698726654,
0.014068704098463058,
-0.06547076255083084,
-0.007652605418115854,
0.00433693453669548,
0.019839070737361908,
-0.027111565694212914,
0.006896962411701679,
-0.02229376696050167,
0.0789899080991745,
-0.0001476939069107175,
0.044514257460832596,
0.01691725105047226,
0.014160296879708767,
0.02212889865040779,
-0.000542116817086935,
-0.057264022529125214,
-0.027606168761849403,
0.013912995345890522,
-0.015607468783855438,
-0.03346812725067139,
-0.013189409859478474,
0.10749369114637375,
-0.02229376696050167,
0.0696474090218544,
0.003782795974984765,
-0.01894145831465721,
0.1185581386089325,
0.024565275758504868,
0.012465824373066425,
0.06569059193134308,
-0.027972539886832237,
0.010533208958804607,
0.023319609463214874,
0.02855873666703701,
-0.03326662257313728,
-0.04337850585579872,
-0.03004254586994648,
-0.03145308047533035,
0.008824997581541538,
0.05008311942219734,
0.012246000580489635,
0.0008352147997356951,
-0.05612826719880104,
0.030427236109972,
0.0011151463259011507,
0.009727190248668194,
0.04543019086122513,
-0.05642136558890343,
0.047811612486839294,
-0.01609291136264801,
-0.039458319544792175,
-0.032936885952949524,
-0.04843444377183914,
-0.0024982024915516376,
-0.08455877006053925,
-0.017091277986764908,
0.003173701697960496,
-0.04041088744997978,
-0.09628269076347351,
-0.0293281190097332,
0.025609437376260757,
-0.0017288202652707696,
0.04806807264685631,
0.016935568302869797,
0.05986526608467102,
0.015012113377451897,
0.02031535468995571,
0.07869680970907211,
-0.020956506952643394,
-0.019839070737361908,
0.026818467304110527,
0.0035469436552375555,
0.061660490930080414,
0.01784234121441841,
-0.019307831302285194,
-0.008092252537608147,
-0.00812431052327156,
0.049020640552043915,
0.00656264740973711,
-0.0180621650069952,
-0.01340007409453392,
-0.010551528073847294,
-0.023740937933325768,
-0.02037031017243862,
-0.022385360673069954,
-0.04502718150615692,
0.0696474090218544,
-0.04762842506170273,
-0.020553497597575188,
0.01851097121834755,
0.0015708220889791846,
-0.010725555010139942,
0.011018653400242329,
0.05554207041859627,
-0.03876221179962158,
-0.0017391244182363153,
-0.015039591118693352,
0.02421722188591957,
-0.023246334865689278,
-0.052317991852760315,
0.01098201610147953,
0.02767944149672985,
-0.07620547711849213,
-0.00873340480029583,
0.009956172667443752,
0.046492669731378555,
0.053307197988033295,
0.07378742098808289,
-0.029859358444809914,
0.04008115082979202,
-0.04447762295603752,
0.0077304597944021225,
0.0031645423732697964,
0.06349235773086548,
0.02844882383942604,
0.028320593759417534,
-0.025719350203871727,
0.010011128149926662,
-0.09525685012340546,
-0.041656553745269775,
-0.023136423900723457,
-0.0024111890234053135,
-0.03081192634999752,
0.027496255934238434,
0.027258114889264107,
-0.017613358795642853,
-0.007158002816140652,
0.033797863870859146,
0.01905136927962303,
-0.06180704012513161,
0.04817798361182213,
-0.07199219614267349,
-0.0800890251994133,
0.00492771016433835,
0.028155727311968803,
0.00004615434954757802,
-0.055835168808698654,
-0.03674716129899025,
-0.05250117927789688,
0.014004589058458805,
0.032314054667949677,
0.02075500227510929,
-0.08902851492166519,
-0.0692443996667862,
-0.02773439884185791,
0.019472697749733925,
-0.052317991852760315,
-0.017824022099375725,
0.0052895029075443745,
-0.025169791653752327,
0.04235266149044037,
0.055835168808698654,
0.03663725033402443,
0.000509772973600775,
0.01745764911174774,
0.03989796340465546,
0.02383253164589405,
0.04722541570663452,
0.04433107376098633,
-0.05905924737453461,
0.008687607944011688,
0.023026511073112488,
0.026268908753991127,
0.025169791653752327,
0.0076617649756371975,
0.012896312400698662,
0.02971280924975872,
0.003100427333265543,
-0.04667585715651512,
-0.0293281190097332,
0.01202617771923542,
0.012804718688130379,
-0.06653324514627457,
-0.03031732514500618,
0.013986269943416119,
0.007739618886262178,
-0.01960092782974243,
-0.019344467669725418,
0.017549242824316025,
-0.02306314930319786,
-0.005610079038888216,
0.05008311942219734,
-0.03244228661060333,
0.03460388258099556,
-0.009388295002281666,
0.02520642802119255,
-0.06543412804603577,
0.031837768852710724,
-0.020443584769964218,
0.07920973747968674,
-0.00799607951194048,
-0.011082768440246582,
-0.008824997581541538,
-0.015964681282639503,
-0.030500510707497597,
0.025059878826141357,
0.056164905428886414,
-0.014270208775997162,
0.018364422023296356,
-0.017448490485548973,
0.010432456620037556,
-0.024528639391064644,
0.010148517787456512,
0.01690809056162834,
-0.02751457504928112,
0.013427551835775375,
0.05063267797231674,
-0.06499448418617249,
-0.017219508066773415,
-0.05905924737453461,
-0.043195318430662155,
0.04238929972052574,
-0.009118095971643925,
0.021396154537796974,
0.03531830757856369,
0.06558068096637726,
0.011733079329133034,
-0.05971871688961983,
-0.018428536131978035,
0.015607468783855438,
0.006576386280357838,
-0.05173179879784584,
-0.01636769063770771,
0.03810273855924606,
0.016010478138923645,
-0.019362786784768105,
-0.04183974117040634,
-0.016596674919128418,
-0.0087059261277318,
-0.07001378387212753,
0.05458950251340866,
-0.021597659215331078,
-0.009562321938574314,
-0.014178615994751453,
-0.05458950251340866,
0.010551528073847294,
-0.01753092370927334,
-0.013244366273283958,
-0.030903520062565804,
-0.0001408959797117859,
0.008055615238845348,
0.04499054327607155,
0.013592420145869255,
0.007350348401814699,
-0.010734714567661285,
0.00746941938996315,
-0.003736999584361911,
0.051438700407743454,
-0.07979592680931091,
-0.006498532369732857,
-0.012090292759239674,
-0.011696442030370235,
0.008646391332149506,
-0.008637231774628162,
-0.012126930058002472,
0.06876812130212784,
-0.020901551470160484,
0.029071656987071037,
-0.0722486600279808,
-0.038359202444553375,
0.016834815964102745,
-0.03150803595781326,
0.02630554512143135,
-0.003869809443131089,
0.011082768440246582,
-0.06257642060518265,
-0.057593755424022675,
0.019564291462302208,
0.020516859367489815,
0.03458556532859802,
0.06228332594037056,
0.013546623289585114,
-0.02570103108882904,
0.03346812725067139,
-0.007895327173173428,
0.012007858604192734,
-0.0007087017875164747,
0.01334511861205101,
-0.004185806028544903,
0.006278708577156067,
-0.012291797436773777,
-0.07484990358352661,
0.019307831302285194,
0.0007172886398620903,
0.03158130869269371,
0.004137719515711069,
0.004220153205096722,
-0.038469113409519196,
-0.048910729587078094,
0.04323195666074753,
0.00697481632232666,
-0.03086688369512558,
-0.04663921892642975,
0.062100138515233994,
-0.026781829074025154,
0.01840105839073658,
0.06411518901586533,
-0.0010533209424465895,
0.03603273630142212,
0.029144931584596634,
-0.020938187837600708,
-0.02982272207736969,
-0.019802434369921684,
0.011073608882725239,
-0.053746845573186874,
-0.00963559653609991,
-0.00933791883289814,
0.024620231240987778,
0.04565001279115677,
-0.008824997581541538,
0.040887169539928436,
0.08294673264026642,
-0.049240462481975555,
0.009983650408685207,
-0.016990523785352707,
0.004208703991025686,
0.017915615811944008,
-0.025224747136235237,
-0.030573785305023193,
-0.027990859001874924,
-0.046602580696344376,
0.040777258574962616,
0.025957491248846054,
0.005811583716422319,
0.0394216813147068,
-0.0072862328961491585,
-0.04685904458165169,
0.040557436645030975,
0.004373571835458279,
-0.016440965235233307,
-0.010203474201261997,
-0.0026584905572235584,
-0.09137330204248428,
-0.04920382797718048,
-0.016944728791713715,
-0.017540084198117256,
-0.030079182237386703,
0.07693822681903839,
0.021982349455356598,
0.034842025488615036,
-0.01701800338923931,
0.0364723838865757,
-0.02553616277873516,
-0.003388945711776614,
-0.0755460113286972,
0.011852150782942772,
-0.011412503197789192,
-0.02059013396501541,
-0.020571816712617874,
0.00593065470457077,
0.0009159312467090786,
0.010414138436317444,
0.029089976102113724,
0.04645603150129318,
0.00208832323551178,
-0.024913329631090164,
-0.023740937933325768,
0.03678379952907562,
0.002876024227589369,
0.016953887417912483,
-0.02800917811691761,
-0.028192363679409027,
0.040557436645030975,
-0.04180310294032097,
0.05689764767885208,
-0.048800818622112274,
-0.03277201950550079,
-0.003031732514500618,
-0.0019600929226726294,
0.05543215945363045,
0.030244050547480583,
0.02399739809334278,
0.04579656198620796,
0.01976579613983631,
0.011403343640267849,
-0.04059407114982605,
0.022055624052882195,
-0.060671284794807434,
0.061770401895046234,
0.010753032751381397,
0.0877828523516655,
-0.062100138515233994,
0.05579853057861328,
0.0707465261220932,
-0.04268239811062813,
-0.01730194129049778,
0.007684663403779268,
0.0146640595048666,
-0.04964347556233406,
-0.028192363679409027,
-0.03898203372955322,
0.06481129676103592,
-0.042535848915576935,
-0.07649857550859451,
0.01960092782974243,
0.0065580676309764385,
0.05488260090351105,
-0.08243381232023239,
-0.03817601501941681,
0.048251260071992874,
-0.014215253293514252,
0.03601441532373428,
0.029474668204784393,
-0.018959777429699898,
-0.023264653980731964,
-0.07811062037944794,
-0.0016853135311976075,
0.003764477325603366,
0.041656553745269775,
-0.012520779855549335,
0.030024226754903793,
0.005669614300131798,
0.05389339476823807,
0.004032387398183346,
-0.014673219062387943,
0.028705285862088203,
0.029346438124775887,
0.018318625167012215,
-0.02674519270658493,
-0.004403339698910713,
0.06037818640470505,
0.02614067867398262,
0.046712495386600494,
-0.03520839661359787,
-0.03504353016614914,
0.03619760274887085,
-0.020608453080058098,
-0.025407932698726654,
0.011678123846650124,
0.03103175014257431,
-0.042645759880542755,
0.016505081206560135,
-0.003356887958943844,
0.017448490485548973,
-0.0035240454599261284,
0.051658522337675095,
-0.00916847214102745,
0.06330917030572891,
0.02048022300004959,
0.026873422786593437,
-0.0013006223598495126,
0.03504353016614914,
0.06070792302489281,
-0.0520615316927433,
-0.022257128730416298,
-0.03872557356953621,
0.0036247980315238237,
0.00660386448726058,
0.00683742668479681,
0.08096832036972046,
0.08316655457019806,
-0.08455877006053925,
0.023319609463214874,
-0.005811583716422319,
0.08302000910043716,
0.027880948036909103,
0.002784430980682373,
0.012584895826876163,
-0.02152438461780548,
-0.04718877747654915,
-0.001155218342319131,
-0.01230095699429512,
0.0005836199270561337,
-0.0012136088917031884,
0.008193004876375198,
-0.03872557356953621,
-0.039348404854536057,
-0.010652280412614346,
0.03458556532859802,
-0.01746680960059166,
-0.04975338652729988,
0.020553497597575188,
0.03348644822835922,
-0.02427217736840248,
0.03561140596866608,
0.022202173247933388,
-0.03253387659788132,
-0.014096181839704514,
0.019729159772396088,
0.018098801374435425,
-0.0075930701568722725,
-0.05488260090351105,
-0.023081468418240547,
-0.05642136558890343,
-0.040227700024843216,
0.03780964016914368,
-0.011009493842720985,
-0.015369326807558537,
0.012246000580489635,
-0.04502718150615692,
0.0001521304511697963,
0.003720970591530204,
-0.01840105839073658,
0.0010464515071362257,
-0.015241095796227455,
-0.024620231240987778,
-0.030830245465040207,
0.010121040046215057,
-0.012108610942959785,
-0.04323195666074753,
-0.03989796340465546,
0.024913329631090164,
-0.08404584974050522,
-0.060231637209653854,
0.04345177859067917,
0.022110579535365105,
-0.0004124552942812443,
-0.019344467669725418,
0.013509985990822315,
-0.013583260588347912,
0.04458753392100334,
-0.023979080840945244,
-0.015442600473761559,
0.03920185565948486,
-0.006773311644792557,
0.020516859367489815,
-0.0017139363335445523,
0.031343165785074234,
-0.007528954651206732,
0.0005023310659453273,
-0.09071382880210876,
0.018428536131978035,
-0.015305210836231709,
-0.021267924457788467,
0.059132520109415054,
0.014334323816001415,
0.04751851409673691,
-0.002195945242419839,
-0.0141145009547472,
0.008339554071426392,
0.017824022099375725,
0.0015204459195956588,
-0.002353943418711424,
-0.02614067867398262,
0.008151788264513016,
-0.006484793033450842,
-0.012071973644196987,
-0.023576069623231888,
0.03229573741555214,
0.05686101317405701,
-0.019582610577344894,
-0.009837101213634014,
0.025224747136235237,
-0.03993460163474083,
0.03260715305805206,
0.011769716627895832,
-0.040007878094911575,
-0.05986526608467102,
-0.003331699874252081,
0.02938307449221611,
-0.020938187837600708,
0.04048416018486023,
-0.019692521542310715,
-0.01712791435420513,
0.017384374514222145,
0.006654240656644106,
0.04235266149044037,
-0.02954794280230999,
-0.0010029447730630636,
-0.0154883973300457,
0.0012055945117026567,
-0.023631026968359947,
0.003720970591530204,
0.02734970673918724,
-0.033742908388376236,
-0.0074831582605838776,
0.011815513484179974,
0.0017391244182363153,
0.0068053691647946835,
-0.03623424097895622,
0.045063816010951996,
0.017640836536884308,
0.00023570918710902333,
-0.007309131324291229,
0.004426237661391497,
0.0106797581538558,
0.00796402245759964,
0.061660490930080414,
-0.023521114140748978,
0.05444295331835747,
-0.004000329878181219,
0.04663921892642975,
-0.003125615417957306,
-0.09005436301231384,
-0.016065433621406555,
0.018281986936926842,
-0.005880278535187244,
0.024968285113573074,
-0.013912995345890522,
-0.05927906930446625,
0.06931767612695694,
0.031214937567710876,
0.04118026793003082,
-0.01580897346138954,
0.03817601501941681,
0.06481129676103592,
-0.0221838541328907,
0.006823687814176083,
0.09181294590234756,
0.028265638276934624,
-0.02410731092095375,
0.022605182603001595,
-0.011971221305429935,
0.050009846687316895,
0.06851165741682053,
-0.03762645646929741,
0.014572465792298317,
-0.024088991805911064,
0.053307197988033295,
0.05953552946448326,
-0.021670933812856674,
-0.009782145731151104,
0.01921623758971691,
0.020058894529938698,
-0.03222246095538139,
-0.04685904458165169,
-0.01035002339631319,
-0.023594388738274574,
0.04151000455021858,
0.001223913161084056,
0.04370823875069618,
-0.04773833602666855,
0.03031732514500618,
-0.013363436795771122,
-0.04205956310033798,
-0.01285051554441452,
0.02372261881828308,
0.005197909660637379,
-0.03568468242883682,
-0.0141145009547472,
-0.025004923343658447,
-0.027661124244332314,
0.03762645646929741,
0.010826307348906994,
0.05455286428332329,
-0.003173701697960496,
-0.008183845318853855,
0.025059878826141357,
0.06697289645671844,
0.03498857468366623,
0.004373571835458279,
0.021267924457788467,
-0.07723132520914078,
0.041106995195150375,
-0.02086491324007511,
-0.004863595124334097,
-0.062319960445165634,
-0.022586865350604057,
-0.025389613583683968,
-0.05378348380327225,
0.003281323704868555,
0.04260912165045738,
0.00945241004228592,
-0.02740466222167015,
0.016065433621406555
]
|
32,125 | bqplot.scales | AlbersUSA | A composite projection of four Albers projections meant specifically for
the United States.
Attributes
----------
scale_factor: float (default: 1200)
Specifies the scale value for the projection
translate: tuple (default: (600, 490))
rtype: (Number, Number) (class-level attribute)
This attribute should not be modified. The range type of a geo
scale is a tuple.
dtype: type (class-level attribute)
the associated data type / domain type
| class AlbersUSA(GeoScale):
"""A composite projection of four Albers projections meant specifically for
the United States.
Attributes
----------
scale_factor: float (default: 1200)
Specifies the scale value for the projection
translate: tuple (default: (600, 490))
rtype: (Number, Number) (class-level attribute)
This attribute should not be modified. The range type of a geo
scale is a tuple.
dtype: type (class-level attribute)
the associated data type / domain type
"""
scale_factor = Float(1200).tag(sync=True)
translate = Tuple((600, 490)).tag(sync=True)
rtype = '(Number, Number)'
dtype = np.number
_view_name = Unicode('AlbersUSA').tag(sync=True)
_model_name = Unicode('AlbersUSAModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
-0.0005148454220034182,
-0.07446473836898804,
-0.018275752663612366,
0.07991162687540054,
-0.03144504502415657,
-0.04726611450314522,
-0.058912429958581924,
-0.08736526966094971,
0.010562310926616192,
-0.04364680126309395,
0.010051663964986801,
0.007269987370818853,
0.0058186776004731655,
0.06317677348852158,
-0.019655393436551094,
0.007677608169615269,
-0.03945412486791611,
0.009585811756551266,
-0.0005221244064159691,
0.019297044724225998,
-0.018293671309947968,
-0.02101711742579937,
0.02388390153646469,
0.04124586656689644,
0.009639563970267773,
0.012416762299835682,
0.032107990235090256,
0.0027839168906211853,
-0.029151618480682373,
-0.031230038031935692,
-0.06328427791595459,
-0.032878439873456955,
-0.018275752663612366,
0.030011653900146484,
0.016967782750725746,
-0.02610565908253193,
0.015238753519952297,
0.02356138825416565,
-0.03690985590219498,
-0.011852364055812359,
-0.015400010161101818,
-0.04257175698876381,
-0.014701231382787228,
-0.019279127940535545,
0.04027832671999931,
0.002089617308229208,
-0.002768239239230752,
-0.02757488749921322,
-0.027144869789481163,
-0.009397679008543491,
-0.019673310220241547,
0.011072956956923008,
-0.0006500658928416669,
0.022145913913846016,
-0.0541105642914772,
0.03420432657003403,
0.019279127940535545,
0.11839821189641953,
-0.00037094627623446286,
0.012273422442376614,
-0.04898618534207344,
-0.041066691279411316,
-0.01868785358965397,
-0.06289009004831314,
-0.014665395952761173,
0.022217582911252975,
-0.03312928229570389,
-0.0021411299239844084,
0.02148296870291233,
0.024475175887346268,
0.02734195999801159,
-0.0022161591332405806,
0.011565685272216797,
0.011126709170639515,
0.04812614992260933,
0.056977350264787674,
-0.05712068825960159,
0.052426327019929886,
0.026768604293465614,
-0.03698152303695679,
-0.0028533467557281256,
-0.016869237646460533,
0.03173172473907471,
-0.01868785358965397,
0.022611765190958977,
-0.08091500401496887,
0.019064119085669518,
-0.02139338292181492,
0.03182131052017212,
-0.009415596723556519,
-0.04418432340025902,
-0.005375221837311983,
0.023507636040449142,
0.03701736032962799,
0.02141129970550537,
0.001947397948242724,
0.010544393211603165,
0.03522561863064766,
0.00042609829688444734,
0.005415535997599363,
0.021267959848046303,
-0.04271509498357773,
-0.04758862778544426,
0.008089708164334297,
-0.009908325038850307,
0.03343387693166733,
0.0181413721293211,
-0.011261089704930782,
-0.03508228063583374,
0.05611731484532356,
-0.030495423823595047,
0.05454058200120926,
-0.0031176286283880472,
0.011583602987229824,
-0.05862575024366379,
-0.015874821692705154,
0.026481924578547478,
0.041675884276628494,
-0.03020874597132206,
0.01517604198306799,
-0.008282320573925972,
0.08557353168725967,
-0.04049333557486534,
0.06665274500846863,
-0.00795980729162693,
0.02187715284526348,
0.05522144213318825,
0.012300298549234867,
-0.04135337099432945,
-0.038665760308504105,
0.029922066256403923,
-0.021966738626360893,
-0.03490310534834862,
-0.036121487617492676,
0.09481891244649887,
-0.03114045038819313,
0.07170545309782028,
-0.027771977707743645,
-0.031337540596723557,
0.10771944373846054,
-0.010714608244597912,
0.021733812987804413,
0.07675816118717194,
-0.0027951153460890055,
0.017263419926166534,
0.02813032642006874,
0.01645713672041893,
-0.032107990235090256,
-0.05525727942585945,
-0.03680235147476196,
-0.04217757284641266,
0.013796402141451836,
0.038988273590803146,
0.0064009930938482285,
-0.021984657272696495,
-0.07328218966722488,
0.037124864757061005,
-0.034419335424900055,
0.0324305035173893,
0.03909577801823616,
-0.03769822046160698,
0.05522144213318825,
-0.03848658502101898,
-0.007650732062757015,
-0.029223287478089333,
-0.044936854392290115,
-0.009764986112713814,
-0.08564519882202148,
-0.029330791905522346,
-0.00012633170990739018,
-0.03221549466252327,
-0.08141668885946274,
-0.009514141827821732,
0.03235883265733719,
-0.011422346346080303,
0.03927495330572128,
0.02078418992459774,
0.05006122961640358,
0.006727985572069883,
0.014226419851183891,
0.07862157374620438,
-0.003386389696970582,
-0.014414552599191666,
0.023973489180207253,
0.004038135055452585,
0.05733569711446762,
-0.00019023245840799063,
0.002689850516617298,
0.018060743808746338,
-0.00783886481076479,
0.05525727942585945,
0.013850154355168343,
-0.018508680164813995,
-0.029223287478089333,
-0.004273300990462303,
-0.024242250248789787,
-0.002340461127460003,
-0.0181413721293211,
-0.059521619230508804,
0.07460807263851166,
-0.06249590963125229,
-0.01753218099474907,
0.013662021607160568,
0.009747068397700787,
-0.03683818504214287,
0.020139163359999657,
0.03522561863064766,
-0.02866784855723381,
-0.018508680164813995,
-0.025603972375392914,
0.04009915143251419,
-0.013052829541265965,
-0.03640816733241081,
0.0072207143530249596,
0.040457502007484436,
-0.10341926664113998,
-0.03289635479450226,
0.005433453246951103,
0.07919493317604065,
0.04690776765346527,
0.07582645863294601,
-0.060990847647190094,
0.05708485469222069,
-0.04758862778544426,
0.01402932871133089,
-0.00012031257938360795,
0.025281459093093872,
0.011897156946361065,
0.016958823427557945,
-0.023740561679005623,
-0.023507636040449142,
-0.07489475607872009,
-0.04597606137394905,
-0.03945412486791611,
0.02558605559170246,
-0.01954788900911808,
0.028649931773543358,
0.028399087488651276,
-0.009478307329118252,
-0.013805360533297062,
0.029169535264372826,
-0.00739988824352622,
-0.06267508119344711,
0.03499269112944603,
-0.05826740339398384,
-0.05378805100917816,
-0.004284499678760767,
0.009845614433288574,
0.005751487333327532,
-0.03252008929848671,
-0.04429182782769203,
-0.017361965030431747,
0.01031146664172411,
0.04844866320490837,
0.025442715734243393,
-0.06392930448055267,
-0.05317885801196098,
-0.054576415568590164,
0.011950909160077572,
-0.04780363664031029,
-0.03158838674426079,
-0.015014785341918468,
-0.014763941988348961,
0.0486636720597744,
0.04296593740582466,
0.029151618480682373,
0.014701231382787228,
0.004069490823894739,
0.0602741502225399,
0.0181592907756567,
0.07396304607391357,
0.06253174692392349,
-0.04457850381731987,
0.0051691713742911816,
0.04081584885716438,
0.0009653001907281578,
0.010221879929304123,
-0.013885988853871822,
0.02829158306121826,
0.03151671588420868,
0.019744981080293655,
-0.026750685647130013,
-0.04332428798079491,
0.02101711742579937,
0.03350554779171944,
-0.044076818972826004,
-0.014118915423750877,
0.029689140617847443,
-0.002159047406166792,
-0.03268134593963623,
-0.010015829466283321,
0.01947622001171112,
-0.0006730225286446512,
-0.008878074586391449,
0.04081584885716438,
-0.024134745821356773,
0.03273509815335274,
0.026302751153707504,
0.025603972375392914,
-0.04511602595448494,
0.02132171206176281,
-0.012434679083526134,
0.09102042019367218,
0.008551081642508507,
0.0007105371332727373,
-0.0008359589264728129,
-0.03515394777059555,
-0.015883779153227806,
0.0018376539228484035,
0.0656493753194809,
-0.03599606826901436,
0.03035208396613598,
-0.02472602017223835,
0.011404428631067276,
-0.014244337566196918,
0.007829906418919563,
0.006463704165071249,
-0.02580106444656849,
0.02673276886343956,
0.020569181069731712,
-0.05260550230741501,
-0.05995163694024086,
-0.021912986412644386,
-0.03106878139078617,
0.03298594430088997,
-0.007225193548947573,
0.0025845856871455908,
0.02787948213517666,
0.04038583114743233,
-0.014307048171758652,
-0.05762237682938576,
-0.018365340307354927,
0.02108878642320633,
0.027718225494027138,
-0.0386299267411232,
-0.021285878494381905,
0.044614341109991074,
0.019422467797994614,
-0.009415596723556519,
-0.01669902168214321,
-0.015803150832653046,
-0.010553351603448391,
-0.08335176855325699,
0.060238316655159,
-0.019655393436551094,
-0.015364174731075764,
-0.038665760308504105,
-0.05769404396414757,
0.031875062733888626,
-0.027073198929429054,
-0.03375639021396637,
-0.051888804882764816,
0.02402724139392376,
0.025783145800232887,
0.06174337863922119,
0.0417117215692997,
0.014244337566196918,
-0.015543349087238312,
0.01069669146090746,
0.010669815354049206,
0.05747903510928154,
-0.07360470294952393,
-0.00021822839335072786,
-0.024779772385954857,
0.001996670849621296,
-0.0007609298336319625,
-0.00422626780346036,
-0.007570103742182255,
0.05059875175356865,
-0.012112165801227093,
0.01978081464767456,
-0.06633023172616959,
-0.020264584571123123,
0.02449309267103672,
-0.037196531891822815,
0.0133305499330163,
-0.0010431288974359632,
0.013142417185008526,
-0.08543018996715546,
-0.08055665343999863,
-0.00923642236739397,
0.013760567642748356,
0.012112165801227093,
0.04991789162158966,
0.02804073877632618,
-0.009630605578422546,
0.034885186702013016,
0.0015912895323708653,
-0.02682235650718212,
-0.002821991452947259,
0.022898444905877113,
0.014369758777320385,
0.003267686814069748,
-0.030549176037311554,
-0.04565354809165001,
0.01745155267417431,
-0.026016073301434517,
0.017263419926166534,
0.03667692840099335,
-0.01410099770873785,
-0.055508121848106384,
-0.0811300128698349,
0.024224331602454185,
0.025371046736836433,
-0.047552794218063354,
-0.06937619298696518,
0.060919176787137985,
-0.021052950993180275,
0.012345092371106148,
0.02882910519838333,
0.017514264211058617,
0.023471800610423088,
0.01567772962152958,
-0.01162839587777853,
-0.03493893891572952,
0.0005372422165237367,
0.012837820686399937,
-0.036031901836395264,
-0.014351841993629932,
0.0015050621004775167,
0.024761853739619255,
0.037196531891822815,
-0.007740319240838289,
0.022307170554995537,
0.06403680890798569,
-0.0626034140586853,
0.006772779393941164,
0.014575809240341187,
0.031337540596723557,
0.0378773957490921,
-0.024851441383361816,
-0.04117419570684433,
-0.016412343829870224,
-0.05507810413837433,
0.034186407923698425,
0.019028283655643463,
-0.007695525418967009,
0.03366680443286896,
0.0050795841962099075,
-0.04486518353223801,
0.052032146602869034,
0.01526562962681055,
-0.00670558912679553,
-0.019404549151659012,
-0.02133963070809841,
-0.0903753936290741,
-0.03816407173871994,
-0.016949865967035294,
-0.02218174748122692,
-0.03450892120599747,
0.061385031789541245,
0.032806769013404846,
0.027843648567795753,
-0.03097919374704361,
0.0702720656991005,
-0.029402462765574455,
-0.010418971069157124,
-0.07166962325572968,
0.016600476577878,
-0.01922537572681904,
-0.0362827442586422,
-0.0282019954174757,
0.04920119419693947,
-0.0021321712993085384,
0.01085794810205698,
0.03841491788625717,
0.026231082156300545,
-0.04002748429775238,
-0.020354172214865685,
-0.04081584885716438,
0.0060381656512618065,
0.01691403053700924,
0.007229673210531473,
-0.05540061742067337,
-0.0019462781492620707,
0.0289724450558424,
-0.03694568946957588,
0.06120585650205612,
-0.04228507727384567,
-0.03524353727698326,
-0.016743814572691917,
-0.0005380820948630571,
0.0502045713365078,
0.036031901836395264,
0.010248756036162376,
0.06314093619585037,
0.022450508549809456,
0.008345031179487705,
-0.04196256399154663,
0.01505957916378975,
-0.03522561863064766,
0.0640726387500763,
0.013124499469995499,
0.043073441833257675,
-0.055973973125219345,
0.05418223515152931,
0.07303134351968765,
-0.0393824577331543,
-0.03174964338541031,
-0.0021624069195240736,
0.006360678933560848,
-0.051028769463300705,
-0.03074626810848713,
-0.03601398319005966,
0.06457433104515076,
-0.04264342412352562,
-0.036730680614709854,
0.017818858847022057,
0.012103207409381866,
0.029169535264372826,
-0.1027742400765419,
-0.02633858658373356,
0.028936609625816345,
-0.014047245495021343,
0.02363305725157261,
0.03606773540377617,
-0.006504018325358629,
-0.015238753519952297,
-0.09202379733324051,
0.014871446415781975,
0.014118915423750877,
0.03407890349626541,
0.0039485483430325985,
0.051817137748003006,
0.006208381149917841,
0.037590716034173965,
0.005693255458027124,
0.0027279250789433718,
0.015865862369537354,
0.013975576497614384,
0.014763941988348961,
-0.0394182913005352,
0.006248695310205221,
0.06711860001087189,
0.034956857562065125,
0.04189089313149452,
-0.03339804336428642,
-0.022038409486413002,
0.023525552824139595,
-0.007740319240838289,
-0.008949743583798409,
0.008766090497374535,
0.016824442893266678,
-0.03452683985233307,
0.04042166471481323,
-0.02047959342598915,
0.0048018647357821465,
-0.015238753519952297,
0.06869532912969589,
0.01336638443171978,
0.059234943240880966,
0.014118915423750877,
0.03004748933017254,
-0.02495894581079483,
0.07292383909225464,
0.08457015454769135,
-0.06615106016397476,
-0.0133305499330163,
-0.036515671759843826,
-0.0054200151935219765,
0.0066025638952851295,
-0.010875864885747433,
0.07905159145593643,
0.10392095148563385,
-0.09496224671602249,
0.01901036687195301,
-0.021751729771494865,
0.055508121848106384,
0.029922066256403923,
-0.0075477068312466145,
0.036193158477544785,
-0.028417004272341728,
-0.0362827442586422,
0.03624691069126129,
-0.015480638481676579,
-0.02463643252849579,
0.005187089089304209,
-0.00552751962095499,
-0.01440559420734644,
-0.019798733294010162,
-0.007395409047603607,
0.028918692842125893,
-0.010642939247190952,
-0.03748321160674095,
-0.010141251608729362,
0.046083565801382065,
-0.011350676417350769,
0.018033867701888084,
0.028452839702367783,
-0.07367637008428574,
0.025084367021918297,
0.012031537480652332,
0.023704728111624718,
0.020605016499757767,
-0.04131753742694855,
-0.033720556646585464,
-0.06504017859697342,
-0.02388390153646469,
0.03762654960155487,
-0.0355481319129467,
-0.02689402550458908,
0.021536720916628838,
-0.040995024144649506,
0.002232956700026989,
0.026750685647130013,
-0.029079949483275414,
-0.022970113903284073,
-0.009406637400388718,
-0.010257714428007603,
-0.028381170704960823,
0.03269926458597183,
-0.010508558712899685,
-0.054898928850889206,
-0.04504435881972313,
0.020264584571123123,
-0.0911637619137764,
-0.06074000522494316,
0.022145913913846016,
-0.018365340307354927,
-0.004703318700194359,
-0.029796645045280457,
0.014916240237653255,
-0.014504139311611652,
0.04264342412352562,
-0.03090752474963665,
-0.01830262877047062,
0.0509929358959198,
-0.019135788083076477,
0.031785476952791214,
-0.010177086107432842,
0.027162786573171616,
0.021572556346654892,
-0.026840273290872574,
-0.08586020767688751,
0.0013135698391124606,
-0.026535676792263985,
-0.02535312809050083,
0.06772778928279877,
0.018015950918197632,
0.022468427196145058,
-0.007028102409094572,
0.008878074586391449,
0.005800759885460138,
0.011646313592791557,
0.0003446300979703665,
-0.009881448931992054,
-0.040134988725185394,
0.0038701596204191446,
-0.013375342823565006,
-0.012560101225972176,
-0.03597814962267876,
0.03524353727698326,
0.047015272080898285,
0.003923911601305008,
0.0013337269192561507,
0.035798974335193634,
-0.028094490990042686,
0.03366680443286896,
0.028918692842125893,
-0.01884911023080349,
-0.04515186324715614,
-0.014163709245622158,
0.029492048546671867,
-0.022826774045825005,
0.05414639785885811,
-0.0036349936854094267,
-0.00865410640835762,
0.01456685084849596,
0.014656437560915947,
0.01410099770873785,
-0.05278467759490013,
0.006669754162430763,
0.01143130473792553,
0.006831010803580284,
-0.025281459093093872,
0.007655211258679628,
0.029922066256403923,
-0.0293666273355484,
0.008766090497374535,
0.02967122383415699,
0.02117837406694889,
0.003984382841736078,
-0.017048411071300507,
0.022360922768712044,
0.011583602987229824,
-0.010329384356737137,
-0.026481924578547478,
-0.004125482402741909,
0.03339804336428642,
0.00610535591840744,
0.05733569711446762,
-0.03834324702620506,
0.033559300005435944,
-0.0017917405348271132,
0.04210590198636055,
0.007579062599688768,
-0.05554395541548729,
-0.01440559420734644,
-0.0146833136677742,
0.018365340307354927,
0.01398453488945961,
-0.01097441092133522,
-0.07518143206834793,
0.07869324088096619,
0.0332188680768013,
0.06074000522494316,
0.0022699113469570875,
0.034562673419713974,
0.06629440188407898,
-0.016779650002717972,
0.006530894432216883,
0.06683192402124405,
-0.009460389614105225,
-0.003912713378667831,
0.024941029027104378,
0.0027301646769046783,
0.04203423485159874,
0.09080541133880615,
-0.03004748933017254,
0.007117689121514559,
-0.01502374466508627,
0.03741154074668884,
0.038522422313690186,
-0.016188375651836395,
-0.011798611842095852,
0.03083585388958454,
0.007722401525825262,
-0.03004748933017254,
-0.05801655724644661,
-0.006754861678928137,
-0.025442715734243393,
0.040529169142246246,
-0.018248876556754112,
0.0036865060683339834,
-0.03447308763861656,
0.026374420151114464,
0.004501747898757458,
-0.004344970919191837,
-0.011771735735237598,
-0.01271239947527647,
-0.018723689019680023,
-0.010150210000574589,
0.02334637939929962,
-0.026643181219697,
-0.04762446507811546,
0.05382388457655907,
0.01232717465609312,
0.030961276963353157,
-0.02232508733868599,
0.004360648337751627,
0.050025396049022675,
0.08220505714416504,
0.04780363664031029,
-0.0010341702727600932,
0.035494379699230194,
-0.08786695450544357,
0.03683818504214287,
-0.009415596723556519,
-0.021536720916628838,
-0.06213756278157234,
-0.028488675132393837,
-0.010571269318461418,
-0.044686008244752884,
-0.01084898877888918,
0.03794906288385391,
0.005881388206034899,
-0.017442593351006508,
-0.005518560763448477
]
|
32,182 | traittypes.traittypes | Array | A numpy array trait type. | class Array(SciType):
"""A numpy array trait type."""
info_text = 'a numpy array'
dtype = None
def validate(self, obj, value):
if value is None and not self.allow_none:
self.error(obj, value)
if value is None or value is Undefined:
return super(Array, self).validate(obj, value)
try:
r = np.asarray(value, dtype=self.dtype)
if isinstance(value, np.ndarray) and r is not value:
warnings.warn(
'Given trait value dtype "%s" does not match required type "%s". '
'A coerced copy has been created.' % (
np.dtype(value.dtype).name,
np.dtype(self.dtype).name))
value = r
except (ValueError, TypeError) as e:
raise TraitError(e)
return super(Array, self).validate(obj, value)
def set(self, obj, value):
new_value = self._validate(obj, value)
old_value = obj._trait_values.get(self.name, self.default_value)
obj._trait_values[self.name] = new_value
if not np.array_equal(old_value, new_value):
obj._notify_trait(self.name, old_value, new_value)
def __init__(self, default_value=Empty, allow_none=False, dtype=None, **kwargs):
self.dtype = dtype
if default_value is Empty:
default_value = np.array(0, dtype=self.dtype)
elif default_value is not None and default_value is not Undefined:
default_value = np.asarray(default_value, dtype=self.dtype)
super(Array, self).__init__(default_value=default_value, allow_none=allow_none, **kwargs)
def make_dynamic_default(self):
if self.default_value is None or self.default_value is Undefined:
return self.default_value
else:
return np.copy(self.default_value)
| (default_value: Any = traittypes.Empty, allow_none: bool = False, dtype=None, **kwargs) | [
0.018182190135121346,
-0.0426822304725647,
0.012846911326050758,
-0.007676924578845501,
0.005440882407128811,
0.018824994564056396,
-0.06641090661287308,
-0.04121296480298042,
0.01829238422214985,
-0.005936760455369949,
0.016933312639594078,
0.004111654125154018,
-0.0036341422237455845,
-0.022792017087340355,
-0.02573055401444435,
0.01996367797255516,
0.06552934646606445,
0.029715942218899727,
0.007029528263956308,
0.0426822304725647,
0.008512570522725582,
-0.0342339426279068,
-0.014205983839929104,
-0.003308148356154561,
-0.0007168420124799013,
0.005532711744308472,
0.02475716359913349,
-0.0487796925008297,
0.009389540180563927,
-0.036933720111846924,
-0.08147090673446655,
-0.03933964669704437,
0.004802669398486614,
0.031019918620586395,
0.05649334937334061,
-0.09204963594675064,
-0.019633091986179352,
0.05204881355166435,
-0.031681086868047714,
0.06530895829200745,
0.0015082953032106161,
-0.043931107968091965,
-0.01879744604229927,
-0.05888091027736664,
-0.005252632778137922,
0.024004163220524788,
-0.0034114562440663576,
0.04712676629424095,
-0.04907354712486267,
0.0012351033510640264,
0.04382091388106346,
-0.05619949474930763,
0.02931189350783825,
0.033425845205783844,
-0.044775936752557755,
0.10835850238800049,
0.009651252999901772,
0.03151579573750496,
-0.010872581973671913,
0.016171129420399666,
-0.0031704045832157135,
0.009251795709133148,
0.07045139372348785,
-0.07159008085727692,
-0.00568882143124938,
-0.007672333158552647,
0.00458916649222374,
0.004788895137608051,
0.05355481430888176,
0.015776263549923897,
-0.04811852425336838,
0.010018570348620415,
0.011047057807445526,
0.016446616500616074,
0.07721002399921417,
0.0016414476558566093,
-0.05737490952014923,
0.011441923677921295,
0.04661252349615097,
-0.023159334436058998,
0.029936332255601883,
0.06556607782840729,
-0.002229154808446765,
0.02088196948170662,
-0.028632357716560364,
0.000974537804722786,
0.005858705844730139,
0.04007428139448166,
0.05355481430888176,
0.012424496002495289,
0.0019261183915659785,
0.019339239224791527,
0.03553791716694832,
0.07735695689916611,
-0.009871643967926502,
0.0316627211868763,
0.014453922398388386,
-0.07507959008216858,
-0.0019031610572710633,
-0.008462064899504185,
-0.021671701222658157,
-0.003925700206309557,
0.07408783584833145,
-0.002092558890581131,
-0.03425230830907822,
0.040294669568538666,
0.040037550032138824,
0.017410824075341225,
0.00021995973656885326,
-0.0038384622894227505,
0.000017612561350688338,
0.006304077338427305,
-0.02490409091114998,
0.020018775016069412,
-0.03274630755186081,
-0.026924334466457367,
-0.02560199238359928,
-0.024995919317007065,
0.006795363966375589,
0.020257530733942986,
-0.04014774411916733,
0.03441759943962097,
0.022975675761699677,
0.029018040746450424,
0.05219574272632599,
0.030432211235165596,
-0.009504326619207859,
0.030119990929961205,
0.01092767994850874,
0.0180811770260334,
-0.03489511087536812,
-0.05480369180440903,
-0.02367357909679413,
0.03882540389895439,
0.012856094166636467,
0.01653844676911831,
0.03162598982453346,
-0.01906375028192997,
-0.05355481430888176,
0.025271408259868622,
0.03105664998292923,
-0.008921210654079914,
0.020533017814159393,
-0.021892091259360313,
0.05149783939123154,
0.03338911384344101,
0.05891764163970947,
0.022608360275626183,
-0.036786794662475586,
-0.027310017496347427,
-0.05329769104719162,
-0.00836564414203167,
-0.03298506513237953,
0.021047262474894524,
0.048008326441049576,
0.0016873623244464397,
-0.008443699218332767,
-0.06270100921392441,
-0.02380213886499405,
-0.00442616967484355,
-0.06145212799310684,
-0.0009567459346726537,
-0.06064403057098389,
-0.029844503849744797,
-0.040221206843853,
0.038605011999607086,
-0.016446616500616074,
-0.01893519051373005,
-0.04951432719826698,
0.049000084400177,
-0.03691535443067551,
-0.058587055653333664,
-0.012424496002495289,
0.019431067630648613,
0.04837564378976822,
0.0378703810274601,
-0.005046017002314329,
0.014903886243700981,
0.03638274595141411,
0.00684127863496542,
-0.0010990812443196774,
0.009550240822136402,
-0.1052730455994606,
0.011267447844147682,
0.0033862031996250153,
0.04914700984954834,
-0.015280385501682758,
-0.01358154509216547,
0.05608930066227913,
0.062003105878829956,
0.047677744179964066,
0.06747612357139587,
0.023232799023389816,
-0.0067173088900744915,
0.04143335297703743,
-0.024793894961476326,
-0.040735453367233276,
-0.006992796901613474,
-0.05601583793759346,
0.041139502078294754,
-0.0024403620045632124,
-0.0280813816934824,
0.03897232934832573,
0.024353114888072014,
-0.04297608509659767,
-0.009908375330269337,
0.06604359298944473,
-0.016951678320765495,
-0.03922945261001587,
-0.04709003493189812,
-0.0561627633869648,
0.017539385706186295,
-0.009022222831845284,
-0.030817894265055656,
0.04492286592721939,
-0.05965227633714676,
0.036988817155361176,
-0.022736920043826103,
-0.03285650163888931,
0.025363236665725708,
0.10358338803052902,
0.01944943331182003,
0.0012500255834311247,
0.020404458045959473,
-0.018071994185447693,
-0.014205983839929104,
0.0019789200741797686,
-0.03897232934832573,
-0.00759886996820569,
0.051057059317827225,
0.018779080361127853,
-0.0021510999649763107,
-0.01710778847336769,
-0.033866625279188156,
-0.0165292639285326,
0.05693412944674492,
0.03146069869399071,
-0.01167149655520916,
-0.015923190861940384,
0.05293037369847298,
-0.025069383904337883,
0.011708227917551994,
-0.015592604875564575,
0.002013356192037463,
-0.07096564024686813,
0.008200351148843765,
0.0013246368616819382,
0.0722145140171051,
-0.030579136684536934,
-0.034013550728559494,
-0.003916517365723848,
-0.07151661068201065,
-0.03454615920782089,
-0.028705820441246033,
0.055795446038246155,
-0.029550649225711823,
-0.004926638677716255,
-0.012892825528979301,
0.04462901130318642,
-0.031791284680366516,
-0.001775747979991138,
0.002904099877923727,
0.031552527099847794,
0.0575585700571537,
-0.04506979137659073,
-0.030707698315382004,
0.019688189029693604,
0.05432618036866188,
-0.019614726305007935,
0.06387642025947571,
0.03311362490057945,
0.054950617253780365,
-0.013691740110516548,
-0.049110278487205505,
0.015620154328644276,
0.03790711238980293,
0.038935597985982895,
0.051718227565288544,
0.0771365612745285,
-0.006478553172200918,
0.009421680122613907,
-0.032636113464832306,
0.006570382043719292,
-0.00483021792024374,
0.006855052895843983,
-0.035886868834495544,
-0.029403723776340485,
-0.017135336995124817,
-0.015895642340183258,
0.007171863690018654,
0.013783569447696209,
0.0019215268548578024,
-0.01602420210838318,
0.013710105791687965,
-0.013811117969453335,
-0.016878215596079826,
-0.08411558717489243,
0.02742021158337593,
0.0366949662566185,
-0.04011101275682449,
0.012332667596638203,
0.019504530355334282,
0.03331564739346504,
0.017401641234755516,
-0.012295935302972794,
-0.06938617676496506,
-0.029807772487401962,
0.009531875140964985,
-0.02282875031232834,
0.025271408259868622,
0.013416252098977566,
0.003946361597627401,
-0.06483144313097,
0.01383866649121046,
0.020147334784269333,
0.04709003493189812,
0.03573993965983391,
-0.035556282848119736,
0.05270998552441597,
0.05575871467590332,
-0.024169456213712692,
-0.03292996436357498,
-0.042902622371912,
-0.10182026028633118,
-0.012479593977332115,
-0.01880662888288498,
0.06134193390607834,
-0.039964087307453156,
-0.03948657587170601,
0.05832993611693382,
0.02683250419795513,
0.004793486557900906,
-0.013719288632273674,
0.02664884552359581,
0.00045541563304141164,
0.013168313540518284,
-0.02049628645181656,
-0.0451432541012764,
-0.03500530868768692,
-0.04011101275682449,
-0.07684271037578583,
-0.005606175400316715,
-0.00207419297657907,
-0.005711778998374939,
0.017805689945816994,
-0.03261774778366089,
-0.0016908058896660805,
-0.00018222365179099143,
0.02126765251159668,
0.02334299311041832,
0.04499632865190506,
-0.01396722812205553,
0.019284140318632126,
0.018375031650066376,
-0.007479491643607616,
-0.0674026608467102,
0.008957942947745323,
-0.03118520975112915,
0.0012637999607250094,
-0.056566812098026276,
0.033480942249298096,
0.03937637805938721,
-0.0019594065379351377,
-0.006698943208903074,
0.02723655290901661,
0.007116766180843115,
-0.04683291167020798,
-0.027989553287625313,
0.03697045147418976,
-0.02710799314081669,
0.007075442932546139,
-0.039853889495134354,
-0.03333401307463646,
-0.020735042169690132,
0.027860991656780243,
0.006744857877492905,
-0.037319403141736984,
0.014463105238974094,
-0.042498573660850525,
-0.10666884481906891,
0.025657089427113533,
-0.007612644229084253,
-0.04363725706934929,
-0.0030785752460360527,
-0.019743287935853004,
-0.02769569866359234,
-0.020018775016069412,
0.024334749206900597,
-0.01730981282889843,
-0.005959718022495508,
0.021102359518408775,
-0.015408947132527828,
-0.02139621414244175,
-0.039853889495134354,
-0.03180965036153793,
0.018466860055923462,
-0.014242715202271938,
0.05315076559782028,
-0.007369296625256538,
0.004474380053579807,
0.015216105617582798,
-0.05399559438228607,
-0.001453197794035077,
0.020128969103097916,
-0.013893764466047287,
0.017530202865600586,
0.04323320835828781,
-0.06167251989245415,
-0.010073667392134666,
0.05484042316675186,
0.06005632504820824,
0.05899110436439514,
0.00755295529961586,
-0.04734715819358826,
0.03882540389895439,
-0.020643213763833046,
0.015711983665823936,
-0.010753204114735126,
0.02690596878528595,
0.03967023268342018,
0.03456452488899231,
0.03311362490057945,
0.012369398958981037,
0.06185617670416832,
0.0426822304725647,
0.020000409334897995,
-0.008347278460860252,
0.019100481644272804,
-0.020992165431380272,
0.00318417907692492,
0.016933312639594078,
0.03142396733164787,
-0.05153457075357437,
-0.04484940320253372,
-0.06464778631925583,
-0.05226920545101166,
-0.02365521341562271,
-0.05432618036866188,
-0.01718125119805336,
0.03632764890789986,
0.04011101275682449,
0.04011101275682449,
0.014610032550990582,
0.043416865170001984,
0.014215166680514812,
-0.03845808655023575,
-0.015500776469707489,
0.03700718283653259,
-0.061488859355449677,
-0.04786140099167824,
0.02354501746594906,
0.008094747550785542,
0.06086442247033119,
0.041470084339380264,
0.01874234899878502,
-0.0078054857440292835,
0.019541263580322266,
-0.057595301419496536,
0.05803608149290085,
-0.07089217752218246,
-0.017943434417247772,
0.03989062458276749,
-0.022130846977233887,
-0.06350910663604736,
0.007419802714139223,
-0.04264549911022186,
0.0027617644518613815,
-0.022718554362654686,
0.009945106692612171,
0.020735042169690132,
0.050799936056137085,
-0.015610971488058567,
0.057411640882492065,
-0.04462901130318642,
-0.02464696764945984,
-0.0014061352703720331,
-0.013232593424618244,
0.02295731008052826,
-0.07379397749900818,
-0.018384214490652084,
0.027199821546673775,
0.0008545859018340707,
-0.0427924282848835,
-0.007158089429140091,
-0.008475839160382748,
0.012194923125207424,
-0.012984654866158962,
-0.017263896763324738,
-0.02431638352572918,
0.08977226912975311,
-0.05950534716248512,
0.040551792830228806,
-0.028540529310703278,
0.024610236287117004,
0.02587748132646084,
0.008613582700490952,
0.06894539296627045,
0.03507877141237259,
0.023636847734451294,
0.0038017306942492723,
-0.002970675937831402,
-0.0025987676344811916,
-0.0841890498995781,
-0.03667660057544708,
0.0013166017597541213,
-0.07845890522003174,
0.03315035626292229,
-0.028577260673046112,
-0.02488572522997856,
0.0035239472053945065,
-0.041653744876384735,
0.005858705844730139,
-0.008411558344960213,
-0.04870622977614403,
0.027916088700294495,
-0.023691944777965546,
0.025234675034880638,
-0.039780426770448685,
-0.01990857906639576,
-0.03067096695303917,
-0.02611623704433441,
-0.023893969133496284,
-0.05465676635503769,
0.019155580550432205,
-0.0037466331850737333,
0.031552527099847794,
-0.00674026645720005,
-0.05035915598273277,
0.04194759950041771,
-0.011441923677921295,
0.039266183972358704,
-0.030652601271867752,
-0.00959615595638752,
0.09579626470804214,
0.013324422761797905,
0.04014774411916733,
0.073610320687294,
0.029220065101981163,
0.05821973830461502,
0.001953667029738426,
-0.029091503471136093,
0.09902865439653397,
0.04011101275682449,
0.01383866649121046,
0.029605748131871223,
0.02042282372713089,
-0.04532691463828087,
0.012617337517440319,
0.038017306476831436,
-0.0011398304486647248,
-0.07416129857301712,
0.024206187576055527,
0.04293935373425484,
0.015151824802160263,
-0.038605011999607086,
0.0060882787220180035,
0.012066362425684929,
-0.03933964669704437,
0.01815464161336422,
0.041323158890008926,
0.002226859098300338,
0.024922456592321396,
0.043600525707006454,
-0.011836789548397064,
-0.014986532740294933,
0.04007428139448166,
0.015161007642745972,
0.04727369546890259,
-0.006267345976084471,
0.0281364805996418,
0.032783038914203644,
-0.06593339890241623,
-0.03755816072225571,
0.010284875519573689,
0.02444494515657425,
0.04011101275682449,
-0.04955105856060982,
0.017980165779590607,
-0.061048079282045364,
-0.006965247914195061,
-0.009159967303276062,
0.015023264102637768,
-0.00008522901771357283,
-0.06383968889713287,
0.047420620918273926,
-0.034454330801963806,
0.0028122705407440662,
0.023838872089982033,
-0.08080973476171494,
-0.004653446841984987,
-0.03028528392314911,
0.02613460272550583,
-0.042572036385536194,
0.010863399133086205,
-0.012580606155097485,
0.045473840087652206,
-0.04106603562831879,
-0.033480942249298096,
0.03974369540810585,
-0.031148478388786316,
-0.006023998372256756,
0.0024288834538310766,
-0.0512407161295414,
-0.00450422428548336,
0.015482409857213497,
-0.0024472493678331375,
-0.009550240822136402,
0.010551179759204388,
0.05561178922653198,
-0.04047833010554314,
-0.008030467666685581,
0.0067173088900744915,
0.01091849710792303,
0.025234675034880638,
-0.01724553108215332,
-0.009251795709133148,
-0.05994613096117973,
0.04565750062465668,
0.03002816252410412,
-0.0012511734385043383,
-0.003533130045980215,
0.015491592697799206,
-0.020992165431380272,
-0.0355195514857769,
-0.018136275932192802,
-0.02093706652522087,
-0.013012203387916088,
0.002490868093445897,
0.017796507105231285,
-0.011111338622868061,
0.06159905716776848,
0.012369398958981037,
0.06942290812730789,
-0.03344421088695526,
-0.01833830028772354,
-0.06101134791970253,
-0.0299546979367733,
0.03619908541440964,
0.06005632504820824,
0.09983675181865692,
-0.02767733298242092,
-0.0280813816934824,
0.06872500479221344,
0.06490490585565567,
-0.026171334087848663,
-0.044775936752557755,
-0.016639458015561104,
-0.020055506378412247,
0.02872418612241745,
0.019229043275117874,
-0.009770631790161133,
0.03515223413705826,
-0.015445678494870663,
-0.05524447187781334,
0.006942290812730789,
0.029220065101981163,
0.02639172412455082,
0.0029821547213941813,
-0.02093706652522087,
-0.010587912052869797,
-0.06079095974564552,
0.027126358821988106,
-0.015730349346995354,
-0.020202433690428734,
0.06402334570884705,
-0.023893969133496284,
0.050285693258047104,
-0.02690596878528595,
0.03149743005633354,
0.025491798296570778,
-0.03967023268342018,
0.036529671400785446,
-0.030909722670912743,
-0.019302505999803543,
0.00988082680851221,
-0.005528120324015617,
0.023765407502651215,
-0.003971614874899387,
-0.0038040264043956995,
-0.01822810433804989,
0.009228838607668877,
0.010698107071220875,
-0.058587055653333664,
0.02483062632381916,
-0.029146600514650345,
-0.045473840087652206,
0.030891356989741325,
-0.009963472373783588,
-0.025253040716052055,
-0.11298669874668121,
0.012231655418872833,
0.0008017840445972979,
0.07684271037578583,
-0.02106562815606594,
-0.0239123348146677,
-0.041323158890008926,
-0.03203003853559494,
0.06163578853011131,
-0.050983596593141556,
0.028613992035388947,
0.047677744179964066,
-0.018843360245227814,
-0.06251734495162964,
0.0028168619610369205,
0.0029431271832436323,
0.06229695677757263,
-0.04238837957382202,
-0.006359174847602844,
0.07030446827411652,
-0.01816382445394993,
0.03267284482717514,
0.08844992518424988,
-0.01717206835746765,
-0.04011101275682449,
-0.058183006942272186,
0.006689760368317366,
-0.038678478449583054,
0.04540037736296654,
-0.02885274775326252,
0.02618969976902008,
0.017649579793214798,
0.01481205690652132,
0.02093706652522087,
0.023618480190634727,
-0.03687862306833267,
0.0354093573987484,
0.052746716886758804,
-0.02800791896879673,
0.07412456721067429,
0.004481267184019089,
0.034656357020139694,
-0.017429189756512642,
0.01196535024791956,
0.006446412764489651,
-0.030652601271867752,
-0.0137468371540308,
-0.02341645583510399,
-0.04602481797337532,
-0.0159415565431118,
0.006340809166431427,
0.005206718109548092,
-0.0013143060496076941,
0.021102359518408775,
0.03713574633002281,
0.025179577991366386,
-0.04602481797337532,
-0.009972656145691872,
0.03838462382555008,
0.008485022000968456,
0.006102052982896566,
-0.01842094585299492,
0.004811852239072323,
-0.03175455331802368,
0.03838462382555008,
0.03937637805938721,
-0.06563954055309296,
0.030817894265055656,
-0.030303649604320526,
-0.004733797628432512,
-0.012617337517440319,
-0.060203250497579575,
-0.038017306476831436,
-0.028503796085715294,
0.022792017087340355,
-0.01880662888288498,
-0.0019410406239330769,
-0.04018447548151016,
-0.020202433690428734
]
|
32,184 | traittypes.traittypes | __init__ | null | def __init__(self, default_value=Empty, allow_none=False, dtype=None, **kwargs):
self.dtype = dtype
if default_value is Empty:
default_value = np.array(0, dtype=self.dtype)
elif default_value is not None and default_value is not Undefined:
default_value = np.asarray(default_value, dtype=self.dtype)
super(Array, self).__init__(default_value=default_value, allow_none=allow_none, **kwargs)
| (self, default_value=traittypes.Empty, allow_none=False, dtype=None, **kwargs) | [
0.021410003304481506,
-0.0198590699583292,
0.026526298373937607,
0.00018272484885528684,
-0.0199482049793005,
0.005758061073720455,
-0.05579792708158493,
0.0032311100512742996,
0.04506618529558182,
-0.00577588751912117,
-0.027132410556077957,
0.02880813181400299,
-0.010098890401422977,
-0.033068738877773285,
0.0037213473115116358,
0.022283516824245453,
0.08207464963197708,
0.010847616009414196,
0.021320870146155357,
0.0603615902364254,
0.008240444585680962,
-0.01615109294652939,
-0.04274870082736015,
0.023495741188526154,
0.005004878155887127,
0.06043289974331856,
-0.014938870444893837,
-0.036865852773189545,
0.021463483572006226,
-0.028647689148783684,
-0.01996603235602379,
0.0022729188203811646,
-0.034298788756132126,
0.09355512261390686,
0.06606617569923401,
-0.0818607285618782,
-0.043212197721004486,
0.04021729156374931,
-0.05701015144586563,
0.0334787555038929,
0.04481660947203636,
-0.07087941467761993,
-0.0345127135515213,
-0.03547535836696625,
-0.010009756311774254,
0.036188431084156036,
0.0397181399166584,
0.05002203956246376,
-0.029752952978014946,
0.01789812184870243,
0.02504667267203331,
0.024155333638191223,
0.045814912766218185,
0.008962430991232395,
-0.06916803866624832,
0.11701520532369614,
0.013646425679326057,
0.05201864242553711,
-0.0411086343228817,
0.013236409053206444,
-0.054157860577106476,
0.03328265994787216,
0.05579792708158493,
-0.08335818350315094,
0.0026606519240885973,
0.041429515928030014,
-0.022033942863345146,
0.016240227967500687,
0.05455005168914795,
0.08164680749177933,
-0.013067054562270641,
0.02433360181748867,
-0.02447621524333954,
0.01987689733505249,
0.0761561468243599,
0.01930643990635872,
-0.07480131089687347,
0.025242768228054047,
-0.018325963988900185,
0.0032890471629798412,
0.001068494631908834,
0.07551438361406326,
0.00039943205774761736,
0.03588537499308586,
0.03672323748469353,
-0.020982159301638603,
-0.05854325741529465,
0.05594054237008095,
0.02444056235253811,
0.018290311098098755,
-0.009983016178011894,
-0.03385312110185623,
-0.003984292969107628,
0.06360606849193573,
0.006680598482489586,
0.015134965069591999,
0.004773129243403673,
-0.06613747775554657,
0.007072788197547197,
0.006841039750725031,
-0.015776731073856354,
-0.0541222058236599,
0.09947361797094345,
-0.024066198617219925,
-0.020714757964015007,
-0.01279965229332447,
0.028683343902230263,
-0.003707977244630456,
0.013477071188390255,
0.04599317908287048,
-0.009867141954600811,
0.0269719697535038,
0.010072150267660618,
-0.0006729622255079448,
-0.04089470952749252,
0.03130388632416725,
-0.009778007864952087,
-0.011034797877073288,
0.034976210445165634,
0.03551101312041283,
-0.02761373482644558,
0.022033942863345146,
-0.008035436272621155,
0.020893026143312454,
0.07815275341272354,
-0.00933233741670847,
-0.03502969071269035,
-0.0003648925921879709,
0.02761373482644558,
0.011801350861787796,
0.029842086136341095,
-0.029164668172597885,
-0.05262475460767746,
-0.005138579290360212,
-0.018227918073534966,
-0.011079364456236362,
0.06906107813119888,
0.03483359515666962,
-0.03413834795355797,
0.020661277696490288,
0.04189301282167435,
-0.0692036896944046,
0.05783018469810486,
-0.010865443386137486,
0.05326652154326439,
0.037436310201883316,
0.07508654147386551,
0.019769936800003052,
-0.047882821410894394,
0.010740655474364758,
-0.024030545726418495,
0.02114260196685791,
0.0014094325015321374,
0.01664132997393608,
0.056118808686733246,
-0.029717298224568367,
0.033781811594963074,
-0.06874019652605057,
-0.03765023127198219,
0.024511869996786118,
-0.018949903547763824,
0.03148215264081955,
-0.02379879727959633,
-0.0333004891872406,
-0.03274785727262497,
0.03921899199485779,
-0.03722238913178444,
-0.030341237783432007,
-0.020928679034113884,
0.004240553360432386,
0.004291805438697338,
-0.09198635816574097,
0.001674606348387897,
0.033692676573991776,
0.0641765296459198,
0.03157128766179085,
-0.01978776417672634,
0.002567061223089695,
0.01927078515291214,
0.031696073710918427,
-0.0030840388499200344,
0.06153815984725952,
-0.03893376141786575,
-0.006061116699129343,
0.020019512623548508,
0.008356318809092045,
-0.010892183519899845,
-0.002916912315413356,
0.027257198467850685,
0.022105248644948006,
0.04228520393371582,
0.0704159140586853,
0.015696508809924126,
0.0023865646217018366,
0.03932595252990723,
-0.013370110653340816,
0.009840400889515877,
-0.016935473307967186,
-0.02305006980895996,
0.04435311257839203,
0.008066633716225624,
-0.052909985184669495,
0.04763324558734894,
-0.026633260771632195,
-0.03337179496884346,
0.013129448518157005,
0.001458456157706678,
-0.01538453996181488,
-0.048453278839588165,
-0.03256958723068237,
-0.020732585340738297,
0.006649401504546404,
-0.02502884715795517,
-0.051091648638248444,
0.008360776118934155,
-0.028665516525506973,
-0.014511026442050934,
-0.01510822493582964,
-0.016418496146798134,
0.03479794040322304,
0.0818607285618782,
-0.0112754600122571,
-0.02490405924618244,
-0.00833849236369133,
0.02438708208501339,
0.04053817316889763,
0.02369183488190174,
-0.036241911351680756,
0.0024935256224125624,
0.0383276492357254,
-0.023994890972971916,
0.013878175057470798,
-0.07993543148040771,
-0.041964318603277206,
0.041286900639534,
-0.02117825485765934,
0.07915105670690536,
-0.02764938771724701,
-0.038149382919073105,
0.002319714054465294,
0.016516543924808502,
-0.0054460917599499226,
0.0010879926849156618,
-0.0069301738403737545,
-0.020322568714618683,
0.035653628408908844,
-0.023210512474179268,
0.060539860278367996,
0.013655339367687702,
-0.04549402743577957,
-0.02247961238026619,
-0.019769936800003052,
-0.008819816634058952,
-0.030626466497778893,
0.03142867237329483,
0.013209668919444084,
0.007001481018960476,
-0.007861624471843243,
0.011721130460500717,
-0.0118370046839118,
0.01802290976047516,
-0.02893291972577572,
0.0020656820852309465,
0.030002526938915253,
-0.028594208881258965,
0.012612470425665379,
0.02495753951370716,
-0.01800508238375187,
-0.016454149037599564,
0.05558400601148605,
0.07508654147386551,
0.03392442688345909,
0.005967525765299797,
-0.056796230375766754,
-0.001942008500918746,
0.04802543669939041,
-0.013370110653340816,
-0.013058140873908997,
0.02060779742896557,
0.006520157214254141,
-0.010401945561170578,
-0.03396008163690567,
0.014190143905580044,
0.0027542428579181433,
-0.006257211789488792,
-0.03918333724141121,
-0.03551101312041283,
-0.01120415236800909,
-0.0565466545522213,
-0.005209886468946934,
-0.012906612828373909,
0.07038026303052902,
-0.026508472859859467,
0.02686500921845436,
-0.005129665601998568,
-0.052981290966272354,
-0.02750677429139614,
0.03510099649429321,
0.03595668449997902,
0.009145155549049377,
-0.02827332727611065,
-0.0015464761527255177,
0.07715445011854172,
-0.0069301738403737545,
-0.03281916305422783,
-0.03982510045170784,
0.016837425529956818,
0.007638789713382721,
0.04314088821411133,
0.04349742457270622,
0.011756783351302147,
0.023460086435079575,
-0.04171474277973175,
0.025777572765946388,
0.02504667267203331,
0.04980811849236488,
0.05241083353757858,
-0.03461967408657074,
0.04499487951397896,
0.022747013717889786,
-0.0016835196875035763,
-0.02062562294304371,
-0.06228688731789589,
-0.0886349156498909,
-0.02681152895092964,
0.021320870146155357,
0.038755495101213455,
-0.01343250460922718,
-0.028415940701961517,
0.08578262478113174,
0.056689269840717316,
-0.0030394718050956726,
-0.003166487906128168,
0.007531828712671995,
-0.018219003453850746,
-0.005856108386069536,
-0.04538706690073013,
-0.02497536689043045,
-0.038113728165626526,
-0.011213066056370735,
-0.07451608031988144,
0.01128437276929617,
-0.03141084685921669,
0.004942484200000763,
0.03290829807519913,
-0.03904072195291519,
0.0333004891872406,
-0.0626077726483345,
0.04306958243250847,
-0.026062801480293274,
0.02058997005224228,
-0.013307716697454453,
0.002776526380330324,
0.01803182251751423,
0.045244455337524414,
-0.045208800584077835,
0.0016356101259589195,
0.011043711565434933,
-0.0028701170813292265,
-0.022230036556720734,
0.03403138741850853,
0.024690138176083565,
-0.01859336718916893,
-0.007901735603809357,
0.031678248196840286,
0.02182001993060112,
0.01537562720477581,
-0.022871801629662514,
-0.004033316858112812,
-0.0006807614699937403,
0.004857806954532862,
-0.041500821709632874,
-0.06317822635173798,
-0.012166800908744335,
0.0513412244617939,
-0.0011398019269108772,
-0.05198298767209053,
0.005570879206061363,
0.01861119456589222,
-0.08421386778354645,
-0.025385383516550064,
-0.012104406952857971,
-0.006693968549370766,
-0.028701171278953552,
-0.043889615684747696,
0.002206068253144622,
-0.0024690136779099703,
0.05401524528861046,
-0.01279965229332447,
-0.016890905797481537,
-0.005258909892290831,
-0.03194564953446388,
-0.03519013151526451,
-0.04114428535103798,
-0.01665915735065937,
0.04998638480901718,
0.03346092998981476,
0.06103901192545891,
-0.019573841243982315,
-0.025403209030628204,
-0.012897700071334839,
-0.039539873600006104,
-0.01601739227771759,
0.04513749107718468,
-0.030323410406708717,
-0.032516106963157654,
0.02495753951370716,
-0.050342921167612076,
0.0243692547082901,
0.05397959426045418,
0.08357210457324982,
0.014359498396515846,
0.007919562049210072,
-0.020821718499064445,
0.03579624369740486,
-0.016534369438886642,
-0.028344634920358658,
-0.04285566136240959,
0.040680788457393646,
-0.016258053481578827,
0.0036099296994507313,
0.03513665124773979,
-0.004724105820059776,
0.052196912467479706,
0.06453306972980499,
0.03606364503502846,
0.03158911317586899,
-0.03283699229359627,
-0.014992350712418556,
-0.03271220251917839,
0.0008952402858994901,
0.06118162348866463,
-0.0499507337808609,
-0.04178605228662491,
-0.008048806339502335,
-0.0013035857118666172,
0.004400994628667831,
-0.0653887540102005,
-0.03194564953446388,
0.010981317609548569,
0.01800508238375187,
0.0003704634727910161,
0.017782246693968773,
0.04563664272427559,
0.018468579277396202,
-0.06285734474658966,
0.018771635368466377,
0.03417400270700455,
-0.05137687921524048,
-0.05373001843690872,
-0.007571939378976822,
0.007932932116091251,
0.09533780068159103,
-0.019556015729904175,
0.0093679903075099,
-0.0076967268250882626,
-0.03424530848860741,
-0.00997410248965025,
0.054193515330553055,
-0.09398296475410461,
-0.013530551455914974,
-0.000031388422939926386,
-0.03847026452422142,
-0.11402030289173126,
-0.024190986528992653,
0.041999973356723785,
-0.0016222400590777397,
-0.01789812184870243,
-0.00832066498696804,
0.002130304230377078,
0.030983002856373787,
-0.004443333484232426,
0.015901517122983932,
-0.05586923658847809,
-0.013824693858623505,
-0.01117741223424673,
-0.0003562577476259321,
-0.020286913961172104,
-0.017158308997750282,
-0.015491501428186893,
-0.020964333787560463,
0.01085652969777584,
-0.018753807991743088,
0.01855771243572235,
-0.010990230366587639,
0.00625275494530797,
-0.013557291589677334,
-0.038826800882816315,
-0.004017718136310577,
0.047775860875844955,
-0.03467315435409546,
0.06150250881910324,
-0.036901503801345825,
0.020964333787560463,
0.03975379467010498,
0.035635799169540405,
0.061930350959300995,
0.002818865003064275,
0.026740221306681633,
0.025224940851330757,
0.015322146937251091,
-0.02825549989938736,
-0.06578094512224197,
-0.018103130161762238,
-0.01722070202231407,
-0.08164680749177933,
-0.031161271035671234,
-0.015794556587934494,
-0.04442442208528519,
0.006087856832891703,
-0.02174871228635311,
0.0601833239197731,
-0.04242781549692154,
-0.0334787555038929,
-0.002382108010351658,
0.007161922287195921,
-0.006622661370784044,
-0.054799627512693405,
-0.01215788722038269,
0.003516338998451829,
0.004091253969818354,
0.034352269023656845,
-0.05430047586560249,
-0.00797304231673479,
-0.021623924374580383,
0.038113728165626526,
-0.059149369597435,
-0.019252959638834,
0.03961117938160896,
0.019021211192011833,
0.005869478452950716,
-0.0766552984714508,
-0.02829115279018879,
0.13184711337089539,
-0.0409303642809391,
0.04178605228662491,
0.06963153183460236,
0.03551101312041283,
0.019074691459536552,
-0.008280554786324501,
-0.01122197974473238,
0.06592355668544769,
0.04378265514969826,
-0.02814853936433792,
0.007264426443725824,
0.012496596202254295,
-0.03638452664017677,
0.06984546035528183,
0.029717298224568367,
-0.016864165663719177,
-0.031072136014699936,
0.000530904799234122,
0.05886413902044296,
0.014332758262753487,
-0.0016311535146087408,
-0.035814069211483,
0.03021644987165928,
-0.03675888851284981,
0.018201176077127457,
0.012050925754010677,
0.031054310500621796,
0.014386238530278206,
-0.0043363724835217,
-0.006613748148083687,
-0.03185651823878288,
0.013272062875330448,
-0.004325230605900288,
0.04827501252293587,
0.020215606316924095,
0.02829115279018879,
-0.018379444256424904,
-0.07045156508684158,
-0.08000674098730087,
0.0021225051023066044,
0.011961791664361954,
0.031820863485336304,
-0.042641740292310715,
0.010696087963879108,
-0.06535310298204422,
-0.02563495747745037,
-0.016373928636312485,
-0.010143456980586052,
-0.04795413091778755,
-0.07565699517726898,
0.03524361178278923,
-0.06570963561534882,
-0.022247863933444023,
0.00330018880777061,
-0.03524361178278923,
-0.01932426542043686,
-0.005758061073720455,
0.02700762264430523,
-0.061966005712747574,
0.03410269320011139,
-0.026722393929958344,
0.058115411549806595,
-0.04945158213376999,
-0.034298788756132126,
0.053052596747875214,
-0.02559930458664894,
0.02939641661942005,
0.026187589392066002,
-0.02310355007648468,
0.05308825150132179,
0.021499138325452805,
-0.0003440018044784665,
-0.028986399993300438,
0.02706110291182995,
0.012220281176269054,
-0.03224870562553406,
-0.021606098860502243,
0.019359920173883438,
0.01806747540831566,
-0.01861119456589222,
-0.019556015729904175,
0.025224940851330757,
-0.044567033648490906,
0.04349742457270622,
0.005954155698418617,
0.009849314577877522,
-0.03861287981271744,
0.016418496146798134,
-0.024084025993943214,
-0.007509545423090458,
-0.029093360528349876,
-0.03672323748469353,
-0.023870103061199188,
-0.031143443658947945,
0.023941410705447197,
0.00739812757819891,
0.08321556448936462,
-0.002718589035794139,
-0.004376482684165239,
0.0015342201804742217,
-0.008490020409226418,
-0.04827501252293587,
-0.0575806088745594,
0.037436310201883316,
0.08899145573377609,
0.06849061697721481,
-0.018254658207297325,
-0.017505930736660957,
0.031000830233097076,
0.02319268509745598,
0.003886245423927903,
-0.0525534488260746,
-0.03775719180703163,
0.022764841094613075,
-0.01674829237163067,
0.005544139072299004,
-0.014225797727704048,
-0.011373506858944893,
-0.009171895682811737,
-0.024066198617219925,
-0.013387937098741531,
0.028701171278953552,
0.0018918706336989999,
0.020090818405151367,
0.027310678735375404,
-0.00829392485320568,
-0.06570963561534882,
0.013655339367687702,
-0.016471976414322853,
-0.0028790305368602276,
0.06374868750572205,
-0.0287903044372797,
0.044638343155384064,
-0.056689269840717316,
0.003324700752273202,
0.06153815984725952,
-0.03016296960413456,
0.01156960241496563,
-0.0051920595578849316,
0.008824273012578487,
0.0217665396630764,
-0.025795400142669678,
0.00007471942080883309,
0.024173159152269363,
0.024565350264310837,
0.004207128193229437,
0.04998638480901718,
-0.0099295349791646,
-0.04346177354454994,
-0.015883691608905792,
-0.015464761294424534,
-0.02818419225513935,
-0.01600847952067852,
0.012639211490750313,
0.012077666819095612,
-0.05504919961094856,
0.010918923653662205,
-0.03839895874261856,
0.052196912467479706,
-0.023460086435079575,
-0.04624275490641594,
-0.01593717187643051,
-0.04945158213376999,
0.00801315251737833,
-0.03800676763057709,
0.04043121263384819,
0.02693631500005722,
0.02180219255387783,
-0.10524950921535492,
0.03996771574020386,
0.01794268749654293,
0.02189132757484913,
-0.020037338137626648,
0.021962635219097137,
0.015589549206197262,
-0.02433360181748867,
0.027970271185040474,
0.07480131089687347,
-0.016471976414322853,
-0.08521217107772827,
-0.06210862100124359,
0.04189301282167435,
0.00039051863132044673,
0.047775860875844955,
-0.03502969071269035,
0.021445656195282936,
-0.0012957865837961435,
-0.0034383467864245176,
-0.002910227281972766,
0.03162476792931557,
-0.028612036257982254,
-0.0049647674895823,
0.0048711770214140415,
-0.04324784874916077,
0.029699472710490227,
-0.017229614779353142,
0.03921899199485779,
0.012906612828373909,
0.07080810517072678,
-0.030305583029985428,
-0.019769936800003052,
-0.04235650971531868,
-0.012193541042506695,
-0.03387094661593437,
0.0050004213117063046,
0.034904900938272476,
-0.050414230674505234,
-0.029164668172597885,
0.0319991298019886,
0.031054310500621796,
0.056867536157369614,
-0.03379964083433151,
-0.001994374906644225,
-0.0032467085402458906,
0.0035207958426326513,
0.0224617850035429,
-0.056225769221782684,
-0.020714757964015007,
-0.00120665249414742,
0.05708145722746849,
0.011008057743310928,
-0.042677391320466995,
-0.029129013419151306,
-0.006092313677072525,
0.015250839293003082,
-0.039468567818403244,
-0.06111031770706177,
-0.0374719612300396,
-0.025848880410194397,
0.029949046671390533,
-0.018468579277396202,
0.01615109294652939,
0.050342921167612076,
-0.0054772887378931046
]
|
32,200 | traittypes.traittypes | make_dynamic_default | null | def make_dynamic_default(self):
if self.default_value is None or self.default_value is Undefined:
return self.default_value
else:
return np.copy(self.default_value)
| (self) | [
0.057521235197782516,
-0.06272280216217041,
0.01739485375583172,
0.01842503435909748,
-0.01655888743698597,
0.007354814559221268,
0.03274623677134514,
0.008984526619315147,
0.04992154240608215,
-0.022748416289687157,
0.00915340892970562,
0.041241005063056946,
-0.038741547614336014,
-0.02585584670305252,
0.006713062524795532,
0.040937017649412155,
0.030179226770997047,
0.037187833338975906,
0.016178902238607407,
0.048570483922958374,
0.03671496361494064,
-0.06214860454201698,
-0.04157876595854759,
0.0015790474135428667,
0.006860834546387196,
-0.003751293057575822,
-0.00004720122160506435,
-0.030331220477819443,
0.02832152508199215,
0.0011367874685674906,
-0.0326617956161499,
-0.037930913269519806,
-0.021025817841291428,
0.06515470892190933,
0.060662440955638885,
-0.06586401164531708,
-0.05066462233662605,
0.07775330543518066,
-0.07376769185066223,
-0.0495162270963192,
0.04184897989034653,
-0.05117126926779747,
-0.021549353376030922,
-0.04343647137284279,
-0.02205600030720234,
0.013307907618582249,
0.03752559795975685,
0.027966871857643127,
0.017133086919784546,
-0.021144036203622818,
0.04637501761317253,
0.010276474058628082,
0.010960446670651436,
0.02685225009918213,
-0.04374045878648758,
0.05566353350877762,
0.00390750914812088,
0.04384178668260574,
-0.07451077550649643,
0.029773909598588943,
-0.008722759783267975,
-0.0020308070816099644,
-0.011374208144843578,
-0.08376551419496536,
0.00514668133109808,
0.03576922416687012,
-0.007152155973017216,
0.00833855289965868,
0.040464144200086594,
0.04009260609745979,
-0.03847133740782738,
-0.00565332779660821,
-0.019252557307481766,
-0.013003920204937458,
0.06285791099071503,
-0.01854325272142887,
-0.029942791908979416,
-0.0626552477478981,
0.022528870031237602,
-0.034485720098018646,
-0.023255061358213425,
0.016390005126595497,
-0.035532791167497635,
0.009567169472575188,
0.007962790317833424,
-0.023390168324112892,
-0.026261163875460625,
0.04772607609629631,
0.07694267481565475,
-0.00815278198570013,
0.014785625971853733,
-0.02617672272026539,
0.010377803817391396,
0.06917409598827362,
0.021110258996486664,
0.005889762658625841,
0.022191105410456657,
-0.021363582462072372,
0.07444322109222412,
-0.02469055913388729,
-0.011880854144692421,
-0.052049458026885986,
-0.01683754287660122,
-0.014658964239060879,
0.02843974158167839,
0.006261303089559078,
0.07147089391946793,
-0.00006138467870187014,
0.013443013653159142,
-0.008422994054853916,
-0.05394093692302704,
-0.01711619831621647,
-0.05485289916396141,
-0.0009700164664536715,
-0.04792873561382294,
-0.00009321499237557873,
-0.030922308564186096,
0.014954508282244205,
0.03850511461496353,
0.08410327136516571,
-0.09072345495223999,
-0.022140439599752426,
-0.049178462475538254,
-0.017361078411340714,
0.04556438326835632,
0.0072703734040260315,
0.02592339925467968,
0.00939828809350729,
0.0337764173746109,
0.028287747874855995,
0.009550281800329685,
-0.012759041041135788,
-0.029942791908979416,
-0.00868898257613182,
-0.032644905149936676,
-0.01756373606622219,
0.01584113948047161,
0.08943995088338852,
0.020856937393546104,
0.03423239663243294,
0.02124536596238613,
-0.006856612395495176,
0.03772825747728348,
-0.004821583162993193,
0.04583459720015526,
0.004517595749348402,
0.0663706585764885,
0.08308998495340347,
-0.09822181612253189,
0.024285241961479187,
0.010242697782814503,
0.08606230467557907,
-0.0034430832602083683,
0.020316513255238533,
0.01376388967037201,
-0.02501143515110016,
0.00512979319319129,
-0.0727543979883194,
-0.031108079478144646,
-0.010850673541426659,
-0.011095552705228329,
-0.010985779576003551,
0.012792817316949368,
-0.04826649650931358,
0.005678659770637751,
0.03374264016747475,
0.029655693098902702,
-0.003001878969371319,
0.01940455101430416,
0.0427609421312809,
-0.04661145433783531,
-0.05772389471530914,
-0.025197206065058708,
0.017597513273358345,
0.04390934109687805,
0.09322290867567062,
-0.02911527082324028,
-0.007071936968713999,
0.035532791167497635,
0.07011983543634415,
-0.01991119794547558,
0.014709629118442535,
-0.030820978805422783,
-0.04043037071824074,
0.03654608130455017,
0.018137935549020767,
0.024285241961479187,
-0.007439255714416504,
0.017850834876298904,
0.03465460240840912,
0.006130419671535492,
0.04343647137284279,
0.027443338185548782,
0.028541071340441704,
0.024623006582260132,
-0.029436146840453148,
0.020840048789978027,
-0.029436146840453148,
0.008482102304697037,
0.05610262602567673,
-0.002446679165586829,
-0.05258987843990326,
0.02075560763478279,
0.024048807099461555,
-0.04367290437221527,
0.011923074722290039,
-0.02788243070244789,
0.009786716662347317,
-0.08038786798715591,
-0.012294615618884563,
-0.07228153198957443,
0.009339178912341595,
-0.03728916123509407,
-0.0005256454460322857,
0.0048595815896987915,
-0.055562205612659454,
-0.019083674997091293,
0.00148194027133286,
-0.03360753506422043,
0.033641308546066284,
0.03880910202860832,
-0.06218238174915314,
0.030871644616127014,
0.014076321385800838,
0.0328475646674633,
0.007228152826428413,
-0.019252557307481766,
-0.03772825747728348,
-0.030989861115813255,
-0.001147342612966895,
0.00457670446485281,
-0.028237083926796913,
-0.037559375166893005,
-0.026244275271892548,
0.0817389264702797,
-0.005796877201646566,
0.058196764439344406,
-0.018526364117860794,
0.008764979429543018,
0.05522444099187851,
-0.0360056608915329,
0.010082259774208069,
0.03789713978767395,
0.036951400339603424,
0.023423943668603897,
0.029925905168056488,
-0.005273343063890934,
0.05640661343932152,
-0.013003920204937458,
-0.027426449581980705,
0.025264758616685867,
-0.014760293997824192,
-0.022444428876042366,
0.015089613385498524,
0.06208105385303497,
0.058635856956243515,
0.00980360433459282,
0.016018465161323547,
0.01492917537689209,
-0.005150903481990099,
-0.003472637850791216,
-0.01793527603149414,
-0.02149868942797184,
0.005193124059587717,
-0.055258214473724365,
-0.006400630809366703,
-0.02082316018640995,
0.021059595048427582,
-0.026261163875460625,
0.028490407392382622,
0.004602036438882351,
0.05904117599129677,
-0.021549353376030922,
-0.08802133798599243,
0.009018302895128727,
0.012919479049742222,
-0.030128562822937965,
0.017082422971725464,
0.015967801213264465,
-0.039045535027980804,
-0.012640823610126972,
-0.02629493921995163,
0.013797665946185589,
0.009592502377927303,
-0.06285791099071503,
0.006501960102468729,
-0.011500869877636433,
-0.05306274816393852,
-0.0031939824111759663,
-0.0348910391330719,
-0.01830681785941124,
0.06123664230108261,
-0.025264758616685867,
0.013426125049591064,
-0.010301806963980198,
-0.04772607609629631,
-0.047692298889160156,
0.023356391116976738,
0.02923348732292652,
0.04556438326835632,
-0.02783176675438881,
0.013350128196179867,
-0.0054084486328065395,
0.038302455097436905,
-0.029165934771299362,
-0.024048807099461555,
0.014211426489055157,
-0.02599095180630684,
0.050090424716472626,
0.030871644616127014,
-0.01977609097957611,
-0.005467557348310947,
0.002290463075041771,
0.022444428876042366,
0.05265743285417557,
-0.037559375166893005,
0.03465460240840912,
-0.03546523675322533,
0.048502933233976364,
0.05086728185415268,
-0.02296796254813671,
-0.03945085406303406,
-0.11693394929170609,
0.0042600505985319614,
-0.030449438840150833,
-0.020907601341605186,
0.007274595554918051,
0.012142620980739594,
-0.006417518947273493,
0.06528981029987335,
0.011762636713683605,
-0.029571251943707466,
-0.021464912220835686,
0.04279471933841705,
0.040261488407850266,
-0.02671714499592781,
0.009888045489788055,
-0.02904771827161312,
-0.02752777934074402,
-0.052049458026885986,
-0.05954781919717789,
0.0073928129859268665,
-0.05235344544053078,
0.009170296601951122,
0.06008824333548546,
-0.0001113566177082248,
0.06701240688562393,
-0.03955218195915222,
0.007025494240224361,
-0.053603172302246094,
-0.06528981029987335,
0.013772333040833473,
-0.019438326358795166,
0.007692578714340925,
0.06400630623102188,
-0.0009568225359544158,
-0.004118611570447683,
-0.009364510886371136,
0.004403600003570318,
0.004108056426048279,
0.037559375166893005,
-0.003609854495152831,
0.012252395041286945,
0.024842552840709686,
0.048502933233976364,
0.021600017324090004,
-0.013814553618431091,
0.024031920358538628,
-0.014743405394256115,
-0.047658521682024,
-0.016077574342489243,
-0.042051635682582855,
-0.007532140705734491,
-0.040700580924749374,
0.031479619443416595,
0.022376876324415207,
-0.09774895012378693,
-0.020232072100043297,
0.02138047106564045,
-0.07228153198957443,
0.016457557678222656,
0.003016656031832099,
-0.0540422648191452,
0.0302130039781332,
0.00620219437405467,
-0.0006823891308158636,
0.0255011934787035,
0.023795485496520996,
-0.015587816014885902,
-0.05238721892237663,
-0.005564664490520954,
-0.011230657808482647,
0.0124719412997365,
-0.029824575409293175,
0.03411417827010155,
-0.02727445587515831,
0.02426835522055626,
0.009964042343199253,
-0.025450529530644417,
0.004694921895861626,
-0.01004848349839449,
-0.0029955459758639336,
0.009474284946918488,
0.04620613530278206,
-0.07721288502216339,
-0.07403790205717087,
0.02825397253036499,
0.055866193026304245,
-0.01213417761027813,
0.03217203542590141,
-0.03360753506422043,
0.018154824152588844,
-0.019928084686398506,
-0.02715623751282692,
0.032830674201250076,
-0.0012961699394509196,
0.02610917016863823,
-0.0005478112143464386,
0.04627368971705437,
-0.022461315616965294,
-0.0367487408220768,
0.02040095441043377,
0.004551372025161982,
0.07478098571300507,
0.009685386903584003,
0.024031920358538628,
-0.008460992015898228,
0.014430973678827286,
-0.050225529819726944,
-0.004783584736287594,
0.026869138702750206,
0.004424710292369127,
-0.012547938153147697,
-0.0005747268442064524,
0.04860426113009453,
-0.03132762387394905,
0.03826867789030075,
-0.019066786393523216,
-0.01102800015360117,
0.01935388706624508,
0.03820112720131874,
-0.0007093047024682164,
-0.00917874090373516,
0.05468401685357094,
-0.023508384823799133,
-0.023271949961781502,
-0.014388753101229668,
0.0026641148142516613,
-0.04938111826777458,
-0.05836564674973488,
-0.01686287485063076,
-0.019809868186712265,
0.0735650360584259,
-0.004369823727756739,
-0.013375460170209408,
-0.01047068927437067,
-0.07518630474805832,
-0.08302243053913116,
0.04667900502681732,
-0.03864021971821785,
0.003377641551196575,
0.04458487033843994,
-0.00805989746004343,
-0.01348523423075676,
-0.0345194973051548,
0.027071796357631683,
0.011728860437870026,
-0.036039434373378754,
-0.03566789627075195,
0.0033903077710419893,
0.035971883684396744,
-0.03850511461496353,
0.0012191175483167171,
-0.07478098571300507,
-0.0037745144218206406,
-0.04404444620013237,
-0.0198943093419075,
0.02210666425526142,
-0.015410489402711391,
-0.01434653252363205,
-0.034181732684373856,
0.020992042496800423,
0.004678033757954836,
-0.003991950303316116,
0.006299301516264677,
0.02659892663359642,
-0.034924812614917755,
0.0018798686796799302,
0.017133086919784546,
0.03249291330575943,
-0.018458811566233635,
0.0630267933011055,
-0.003880065865814686,
0.0008987692999653518,
-0.03174982964992523,
0.014709629118442535,
0.0648844912648201,
-0.008866309188306332,
0.07059270888566971,
0.0008618263527750969,
-0.008705871179699898,
-0.009322290308773518,
-0.0667421966791153,
0.032476022839546204,
-0.014025656506419182,
-0.09139898419380188,
-0.046712782233953476,
0.01818859949707985,
-0.051069941371679306,
0.01437186449766159,
0.03847133740782738,
0.02568696439266205,
-0.03153028339147568,
-0.01739485375583172,
0.00350219220854342,
-0.024217689409852028,
0.0017310413531959057,
-0.042051635682582855,
0.004217830020934343,
-0.03539768233895302,
0.030736537650227547,
0.013882107101380825,
-0.0484016053378582,
-0.0630267933011055,
-0.025349199771881104,
0.05171169340610504,
-0.03397907316684723,
-0.01630556397140026,
0.0367487408220768,
0.028085090219974518,
-0.013248799368739128,
-0.06897144019603729,
0.001184285618364811,
0.1613161563873291,
-0.005049574188888073,
0.02242754027247429,
0.04245695471763611,
0.00754058500751853,
-0.08086074143648148,
-0.05769011750817299,
-0.010926670394837856,
-0.009254737757146358,
0.03803224489092827,
0.008680539205670357,
0.031851161271333694,
0.018441922962665558,
-0.032340917736291885,
0.09687075763940811,
0.0223093219101429,
-0.0348910391330719,
-0.04134233295917511,
-0.0006100864848122001,
0.028338413685560226,
0.007316816132515669,
-0.00980360433459282,
-0.0171668641269207,
-0.017479294911026955,
0.008705871179699898,
0.036208316683769226,
0.01728508062660694,
0.038910429924726486,
-0.02187022939324379,
0.07998254895210266,
0.005024241749197245,
-0.0307703148573637,
0.018965456634759903,
-0.09268248826265335,
0.03389463201165199,
0.02291729860007763,
0.012353723868727684,
-0.030685873702168465,
-0.03141206502914429,
0.042727164924144745,
0.003554967697709799,
0.03948463127017021,
0.031901825219392776,
0.01579047366976738,
-0.022934185341000557,
-0.037626925855875015,
0.01268304418772459,
0.00377662549726665,
0.020772496238350868,
0.026261163875460625,
-0.043132483959198,
0.014430973678827286,
-0.05177924409508705,
-0.016871320083737373,
0.048063840717077255,
-0.0217520110309124,
-0.018509475514292717,
-0.04900958016514778,
0.0668097510933876,
-0.07538896054029465,
0.02310306765139103,
-0.031597837805747986,
0.04036281630396843,
-0.034316837787628174,
-0.019252557307481766,
0.0653235912322998,
-0.01649133488535881,
-0.02892949990928173,
0.02192089334130287,
-0.029334817081689835,
0.0648844912648201,
0.017428630962967873,
-0.00031348736956715584,
-0.005982647649943829,
-0.018931681290268898,
0.028676176443696022,
-0.026497598737478256,
-0.0012201729696244001,
-0.006075532641261816,
-0.01569758914411068,
0.0012845592573285103,
-0.028490407392382622,
0.007109935395419598,
-0.027662884443998337,
0.023423943668603897,
-0.019438326358795166,
-0.015782030299305916,
-0.06069621816277504,
0.027629107236862183,
-0.030516991391777992,
-0.008169670589268208,
0.002594450954347849,
-0.014126986265182495,
0.016381561756134033,
0.004572482313960791,
-0.004433154594153166,
0.025028323754668236,
0.017985941842198372,
0.02604161575436592,
0.03242535889148712,
-0.016449114307761192,
-0.00006366062734741718,
0.03225647658109665,
0.006670841947197914,
0.02800064906477928,
0.06501960009336472,
0.0334048755466938,
0.008950750343501568,
-0.005923538934439421,
0.029520587995648384,
0.03968728706240654,
-0.01437186449766159,
-0.03311777487397194,
0.0040362817235291,
0.015300716273486614,
-0.020417843014001846,
-0.011255990713834763,
-0.07842883467674255,
-0.026497598737478256,
-0.006333077792078257,
-0.012843482196331024,
0.02396436780691147,
-0.011728860437870026,
0.02082316018640995,
0.008051453158259392,
0.032644905149936676,
-0.03999127447605133,
-0.0968032106757164,
-0.0021036374382674694,
-0.02610917016863823,
-0.011441760696470737,
0.06248636916279793,
0.010833784937858582,
-0.00044832914136350155,
-0.05823054164648056,
0.0017299858154729009,
-0.04509151354432106,
-0.01139109581708908,
-0.031783606857061386,
-0.019674761220812798,
-0.036951400339603424,
0.009600945748388767,
-0.06579645723104477,
0.022140439599752426,
0.0611690878868103,
0.01264926791191101,
-0.0009795160731300712,
0.11578555405139923,
-0.018070382997393608,
-0.04894202575087547,
0.05134015157818794,
-0.0065948450937867165,
-0.010217365808784962,
0.012269282713532448,
-0.011880854144692421,
0.016339341178536415,
0.004927134606987238,
-0.025518082082271576,
-0.0322902537882328,
0.039788618683815,
0.004678033757954836,
-0.022647086530923843,
-0.027122462168335915,
-0.06022334843873978,
0.06670842319726944,
-0.02935170568525791,
0.046712782233953476,
0.0123790567740798,
0.0019653651397675276,
-0.08167137205600739,
-0.0003818318364210427,
0.03426617383956909,
0.023913701996207237,
-0.019134338945150375,
0.01102800015360117,
-0.0017806504620239139,
-0.027358897030353546,
0.023052403703331947,
0.05823054164648056,
-0.005750434938818216,
-0.0124719412997365,
-0.04816516861319542,
0.02634560503065586,
-0.07113312929868698,
0.04725320637226105,
-0.07039005309343338,
0.05252232775092125,
0.020924489945173264,
-0.004496485460549593,
0.0178170595318079,
-0.008017676882445812,
-0.0124719412997365,
0.03392840921878815,
0.019134338945150375,
-0.06596533954143524,
0.010132924653589725,
0.04826649650931358,
0.026075392961502075,
0.049246013164520264,
0.06545869261026382,
-0.005526666063815355,
0.010445356369018555,
-0.028912611305713654,
0.05806165933609009,
-0.009584058076143265,
-0.08059053122997284,
0.014912287704646587,
-0.019944973289966583,
-0.010073816403746605,
0.013307907618582249,
0.03968728706240654,
0.020232072100043297,
-0.02168445847928524,
0.0071226018480956554,
0.012024403549730778,
-0.00591087294742465,
0.037863362580537796,
-0.012480385601520538,
0.008916974067687988,
0.01823926530778408,
0.0367487408220768,
0.026244275271892548,
-0.06512092798948288,
0.01004848349839449,
0.013645672239363194,
0.029773909598588943,
0.002695780247449875,
-0.055494651198387146,
-0.039721064269542694,
-0.04097079113125801,
0.07261929661035538,
-0.028051313012838364,
0.019387662410736084,
0.034063514322042465,
0.01545270998030901
]
|
32,201 | traittypes.traittypes | set | null | def set(self, obj, value):
new_value = self._validate(obj, value)
old_value = obj._trait_values.get(self.name, self.default_value)
obj._trait_values[self.name] = new_value
if not np.array_equal(old_value, new_value):
obj._notify_trait(self.name, old_value, new_value)
| (self, obj, value) | [
0.05561830848455429,
-0.0009684162214398384,
-0.007496718782931566,
-0.008576937951147556,
-0.03992488980293274,
-0.036917559802532196,
-0.013792234472930431,
0.034947242587804794,
-0.032130029052495956,
0.012487330473959446,
0.012340420857071877,
0.009246673434972763,
0.023695681244134903,
-0.024421587586402893,
-0.04915428161621094,
0.017292143777012825,
0.025579582899808884,
0.018234094604849815,
0.036744724959135056,
0.034307751804590225,
0.008736810646951199,
-0.03705582767724991,
-0.0022338926792144775,
0.006446746177971363,
0.023954933509230614,
-0.014232964254915714,
-0.02359198033809662,
0.01190833281725645,
0.012288570404052734,
-0.009307165630161762,
-0.047598764300346375,
-0.028621479868888855,
0.006049225572496653,
-0.0036230541300028563,
0.05454673245549202,
-0.04310505464673042,
-0.01911555416882038,
0.027221515774726868,
-0.02034268155694008,
0.040166858583688736,
-0.022036464884877205,
0.02103402279317379,
-0.007522644475102425,
0.016272416338324547,
0.00902198813855648,
0.045421041548252106,
0.011536737903952599,
0.11621426790952682,
0.03781630098819733,
-0.011519454419612885,
-0.023142609745264053,
-0.06903030723333359,
0.037124961614608765,
0.011398470029234886,
-0.04134213551878929,
0.06101076304912567,
-0.02022169716656208,
0.03420405089855194,
0.03031526319682598,
0.046319786459207535,
0.001810446847230196,
0.005012215580791235,
-0.012383629567921162,
-0.12451034784317017,
0.0007140247034840286,
-0.036779291927814484,
0.013576190918684006,
0.03632992133498192,
0.01953035779297352,
0.04065079614520073,
-0.045455608516931534,
-0.0004353281983640045,
0.05039869248867035,
-0.022727804258465767,
0.01342063955962658,
0.000717805465683341,
-0.055203504860401154,
0.059904616326093674,
0.02419690228998661,
-0.018700748682022095,
0.06135643273591995,
0.04628521949052811,
0.0166785791516304,
-0.017430411651730537,
-0.06951424479484558,
0.03933725133538246,
0.0025406747590750456,
-0.007915844209492207,
0.08005718141794205,
-0.00047718669520691037,
0.02500922791659832,
-0.012936701066792011,
0.04587041586637497,
0.010828114114701748,
-0.025977103039622307,
0.03420405089855194,
0.05675902217626572,
-0.052680112421512604,
-0.023280877619981766,
-0.006472671404480934,
-0.004891231190413237,
-0.020187130197882652,
0.00970468670129776,
0.02748076803982258,
-0.01062071230262518,
-0.03726322948932648,
0.029260968789458275,
-0.016566237434744835,
-0.014794677495956421,
-0.009177539497613907,
0.0069868555292487144,
0.025458598509430885,
-0.03906071558594704,
0.03282137215137482,
-0.00916889775544405,
-0.03098931908607483,
-0.05091719701886177,
-0.06636864691972733,
-0.015382316894829273,
0.016263775527477264,
-0.038369376212358475,
0.0037721244152635336,
0.027307933196425438,
0.041273001581430435,
0.011675005778670311,
0.017067458480596542,
0.044729702174663544,
0.07431905716657639,
0.045075371861457825,
-0.02625363878905773,
-0.022209299728274345,
-0.07342031598091125,
-0.040374260395765305,
0.02756718546152115,
0.003515032120049,
0.011657722294330597,
-0.00773868802934885,
-0.04175693914294243,
0.0016322106821462512,
-0.03868047893047333,
0.009903446771204472,
0.00676649110391736,
0.01590082235634327,
-0.02945108711719513,
0.06750936061143875,
0.044522300362586975,
-0.020446382462978363,
0.05834910273551941,
-0.05928241088986397,
-0.020636500790715218,
-0.04790986701846123,
-0.017715590074658394,
-0.019824177026748657,
-0.008818906731903553,
-0.06228974089026451,
0.0015619965270161629,
-0.04348529130220413,
-0.05527263879776001,
0.05015672370791435,
0.05295665189623833,
-0.00013286691682878882,
0.016816847026348114,
-0.026772145181894302,
0.04476426914334297,
-0.02048094943165779,
0.03733236342668533,
-0.0074059804901480675,
-0.006705998908728361,
-0.013757667504251003,
0.04901601001620293,
-0.02538946457207203,
-0.07832883298397064,
-0.022710520774126053,
0.0946444571018219,
0.05793429911136627,
0.04694199189543724,
-0.004986290354281664,
-0.011528096161782742,
0.030246129259467125,
0.024698125198483467,
0.01790570840239525,
0.014846527948975563,
-0.046112384647130966,
0.023108042776584625,
-0.026495609432458878,
0.015753911808133125,
-0.012686090543866158,
0.03223372995853424,
0.021950047463178635,
0.0344633013010025,
0.04929254949092865,
0.017594605684280396,
0.005932562053203583,
-0.015330466441810131,
-0.007552890572696924,
-0.0009532931726425886,
0.0006886395276524127,
-0.09623453766107559,
-0.031438689678907394,
0.021621661260724068,
0.020964888855814934,
-0.0456630140542984,
0.0498456209897995,
0.017672380432486534,
0.008326327428221703,
-0.00551343709230423,
0.06989448517560959,
0.029641205444931984,
0.018614331260323524,
-0.04839380457997322,
-0.03391022980213165,
-0.008430028334259987,
-0.05720839276909828,
-0.01361939962953329,
0.04901601001620293,
-0.08468916267156601,
0.036744724959135056,
-0.010897248052060604,
-0.02257225289940834,
0.03861134499311447,
0.03594968467950821,
0.04891230911016464,
-0.01028368342667818,
-0.008758414536714554,
0.006489954888820648,
0.01094045676290989,
-0.010802188888192177,
-0.08883719891309738,
-0.0001416437007719651,
0.020152563229203224,
-0.01297126803547144,
0.01611686497926712,
0.010612070560455322,
-0.015088497661054134,
-0.008391140028834343,
0.09492099285125732,
0.025320330634713173,
-0.02509564533829689,
-0.07411165535449982,
0.08254600316286087,
0.01564157009124756,
-0.03155967593193054,
0.014604559168219566,
0.060561392456293106,
-0.04943081736564636,
0.050640661269426346,
-0.010275041684508324,
0.030557231977581978,
-0.049741920083761215,
-0.015831688418984413,
0.01603044755756855,
-0.024870960041880608,
-0.06381069123744965,
-0.021950047463178635,
-0.0020524158608168364,
-0.021068589761853218,
0.008723847568035126,
-0.03232014924287796,
0.04078906401991844,
0.014518141746520996,
-0.04082363098859787,
-0.019858743995428085,
0.008123246021568775,
0.06135643273591995,
-0.017473621293902397,
-0.016341550275683403,
0.013308296911418438,
0.09001247584819794,
-0.023142609745264053,
0.012012033723294735,
0.026823995634913445,
-0.034428734332323074,
-0.002845296636223793,
0.02309075929224491,
0.03394479677081108,
-0.004778888542205095,
0.011510812677443027,
0.010517011396586895,
0.02480182610452175,
-0.03128314018249512,
0.023522846400737762,
-0.03788543492555618,
0.05278381332755089,
-0.0052585056982934475,
-0.03830024227499962,
-0.03408306464552879,
-0.014353948645293713,
0.029779473319649696,
-0.021189574152231216,
-0.01214165985584259,
-0.01970319263637066,
-0.012435480020940304,
-0.03325345739722252,
0.036917559802532196,
-0.013394714333117008,
-0.013800876215100288,
-0.09208650141954422,
0.00008115144009934738,
0.03795456886291504,
-0.004826418124139309,
0.03534476086497307,
0.007073273416608572,
-0.07418078929185867,
0.0057381228543818,
0.01586625538766384,
-0.04656175523996353,
0.053371455520391464,
-0.0037073111161589622,
-0.006770811975002289,
0.02445615455508232,
0.06488226354122162,
0.000990560743957758,
-0.07183023542165756,
0.05216160789132118,
0.09049641340970993,
0.029295535758137703,
0.01966862566769123,
-0.05869477242231369,
-0.007354130037128925,
0.03816197067499161,
-0.025786984711885452,
-0.039095282554626465,
-0.08054111897945404,
-0.041998911648988724,
0.013195953331887722,
-0.05503067001700401,
0.03850764408707619,
0.00765227060765028,
-0.025804268196225166,
0.019824177026748657,
-0.058245401829481125,
-0.02825852669775486,
0.05942067876458168,
0.04735679551959038,
0.015235407277941704,
0.003953601233661175,
0.002586043905466795,
-0.0069868555292487144,
0.020532799884676933,
0.035033658146858215,
-0.013930502347648144,
0.026685727760195732,
-0.01889086700975895,
-0.013714458793401718,
0.03406578302383423,
0.014457649551331997,
-0.031490541994571686,
0.006044904701411724,
0.05105546489357948,
0.050640661269426346,
-0.08932113647460938,
0.010205907747149467,
0.02608080394566059,
-0.03705582767724991,
-0.05544547364115715,
-0.04179150611162186,
0.02428331971168518,
-0.07272897660732269,
-0.0608033612370491,
-0.099207304418087,
-0.020843902602791786,
-0.010854039341211319,
-0.011398470029234886,
-0.004368405323475599,
-0.03954465314745903,
0.03615708649158478,
-0.06280824542045593,
-0.011268842965364456,
0.04752963036298752,
-0.014863811433315277,
0.024698125198483467,
0.02317717671394348,
-0.021224141120910645,
0.037505198270082474,
0.05053696036338806,
0.012400913052260876,
-0.029399236664175987,
0.03190534561872482,
0.004359763581305742,
-0.019011851400136948,
0.07577086985111237,
-0.0042301369830966,
-0.01830322854220867,
0.053717125207185745,
0.004467785358428955,
0.019219255074858665,
0.027498051524162292,
0.005932562053203583,
0.006520200986415148,
-0.02663387730717659,
0.0445568673312664,
0.044003795832395554,
0.005777010694146156,
-0.05147026851773262,
0.007112161256372929,
0.0037073111161589622,
-0.002536353887990117,
0.00628255307674408,
0.027670886367559433,
-0.012426838278770447,
0.0076738749630749226,
0.008347931317985058,
-0.008369536139070988,
0.051573969423770905,
0.0052585056982934475,
0.051919639110565186,
0.01816496066749096,
0.039994023740291595,
0.004809134639799595,
0.010370100848376751,
-0.010741696693003178,
0.02962392196059227,
0.02480182610452175,
-0.06218603998422623,
0.003964403178542852,
-0.005137520842254162,
0.0008549932390451431,
-0.05485783517360687,
0.04096189886331558,
0.008239910006523132,
-0.007596099283546209,
0.04206804558634758,
-0.03017699532210827,
0.03200904652476311,
-0.011407111771404743,
-0.03261396661400795,
0.0436926931142807,
-0.03954465314745903,
0.034653421491384506,
0.011770064942538738,
-0.0011655561393126845,
-0.013377430848777294,
-0.0023354331497102976,
0.020636500790715218,
0.002158277202397585,
-0.07853623479604721,
-0.010784905403852463,
-0.04441859945654869,
-0.0496036522090435,
-0.016298342496156693,
0.012461405247449875,
-0.031110303476452827,
0.00465790368616581,
0.03275223448872566,
-0.05945524573326111,
0.024473438039422035,
-0.0377817340195179,
0.0040097725577652454,
-0.02025626413524151,
-0.005608496256172657,
0.0470111258327961,
0.009281240403652191,
-0.02132784202694893,
0.051919639110565186,
-0.0021399136167019606,
-0.023436428979039192,
-0.06294651329517365,
-0.05178137123584747,
0.07528693228960037,
-0.060423124581575394,
-0.04970735311508179,
-0.01094045676290989,
-0.05019129067659378,
-0.015589718706905842,
-0.050122156739234924,
0.0489814430475235,
0.004476427100598812,
0.025372181087732315,
0.02646104246377945,
0.014552708715200424,
0.03843851014971733,
-0.06484770029783249,
0.042897652834653854,
-0.026184504851698875,
-0.05057152733206749,
0.02025626413524151,
0.002171240048483014,
0.04659632220864296,
-0.06975621730089188,
-0.005046782549470663,
0.04911971092224121,
0.021258708089590073,
0.036917559802532196,
-0.025786984711885452,
0.007609061896800995,
0.0028366546612232924,
-0.004696791525930166,
0.002313828794285655,
-0.00916889775544405,
0.04573214799165726,
-0.0228315070271492,
0.0037958892062306404,
-0.061494700610637665,
0.004068104084581137,
0.009825671091675758,
0.00964419450610876,
0.0270141139626503,
-0.022243866696953773,
-0.021310558542609215,
-0.018960000947117805,
-0.013334222137928009,
0.015598360449075699,
-0.06346502155065536,
-0.04552474617958069,
-0.030972035601735115,
-0.03698669373989105,
-0.007522644475102425,
-0.021708078682422638,
-0.03264853358268738,
-0.01011084858328104,
0.03743606433272362,
0.007686837576329708,
0.013895935378968716,
0.0046146949753165245,
0.06322304904460907,
-0.021863630041480064,
-0.0011936418013647199,
0.01056022010743618,
-0.03816197067499161,
-0.05019129067659378,
-0.01412926334887743,
-0.04752963036298752,
0.04141126945614815,
-0.02376481518149376,
0.021137723699212074,
-0.03435960039496422,
0.009523209184408188,
-0.05866020545363426,
0.05471956729888916,
-0.023401862010359764,
0.02309075929224491,
-0.011623155325651169,
0.008188058622181416,
0.09091121703386307,
0.04659632220864296,
0.005284430924803019,
0.019253822043538094,
-0.0036165728233754635,
0.017836574465036392,
0.00206861924380064,
-0.03416948392987251,
0.012988551519811153,
0.008589900098741055,
0.03391022980213165,
0.01885630004107952,
-0.04583584889769554,
-0.03702126070857048,
-0.027584468945860863,
0.03406578302383423,
-0.030591798946261406,
-0.03833480924367905,
-0.002938195364549756,
0.004740000236779451,
0.029485654085874557,
-0.07466472685337067,
0.03142140805721283,
0.03698669373989105,
-0.004100510850548744,
0.031214004382491112,
0.03275223448872566,
-0.031404122710227966,
0.017715590074658394,
0.11974009871482849,
0.020636500790715218,
0.038023702800273895,
0.010033072903752327,
-0.03264853358268738,
0.007730046287178993,
0.059178709983825684,
-0.010612070560455322,
0.024421587586402893,
0.01418975554406643,
-0.06705998629331589,
0.003800210077315569,
0.008425706997513771,
0.06228974089026451,
0.002337593585252762,
0.021621661260724068,
-0.0683043971657753,
-0.013334222137928009,
-0.0902198776602745,
0.035673148930072784,
0.013023118488490582,
-0.06951424479484558,
0.04030512645840645,
-0.02137969247996807,
0.008520766161382198,
0.07321291416883469,
-0.03774716705083847,
-0.011381186544895172,
-0.07030928879976273,
0.007233145646750927,
-0.061114463955163956,
-0.019945161417126656,
0.02347099594771862,
0.017542755231261253,
-0.020031578838825226,
-0.08462002873420715,
0.03228558227419853,
0.0021928444039076567,
0.012573747895658016,
0.0013481131754815578,
-0.03492995724081993,
0.02269323728978634,
0.004930119030177593,
0.0054097361862659454,
-0.019720476120710373,
-0.008810264989733696,
0.01641068607568741,
-0.021777212619781494,
-0.002186363097280264,
0.0445568673312664,
0.00825287215411663,
0.03301148861646652,
-0.021656228229403496,
-0.03282137215137482,
-0.007323883939534426,
0.03382381424307823,
-0.028673330321907997,
0.001341631868854165,
-0.027290649712085724,
-0.01361939962953329,
-0.03594968467950821,
-0.03646818920969963,
-0.006727603264153004,
-0.05779603123664856,
-0.005932562053203583,
-0.02462899126112461,
0.010810830630362034,
-0.04348529130220413,
-0.006127001252025366,
-0.001612766762264073,
0.0030678214970976114,
-0.03995945677161217,
0.004076745826750994,
-0.037124961614608765,
-0.0467691570520401,
0.024127768352627754,
0.02004886232316494,
0.013558907434344292,
-0.010439234785735607,
0.001784521620720625,
0.10860952734947205,
0.05261097848415375,
-0.028621479868888855,
0.059697214514017105,
-0.036779291927814484,
0.0024650595150887966,
-0.008222626522183418,
0.012349062599241734,
-0.003251458751037717,
-0.015192198567092419,
-0.040719930082559586,
-0.01235770434141159,
0.071622833609581,
0.03594968467950821,
0.04206804558634758,
0.0034286146983504295,
0.017853857949376106,
0.023920366540551186,
-0.08302994072437286,
0.015036647208034992,
0.008261513896286488,
-0.01863161474466324,
0.09706414490938187,
0.05274924635887146,
-0.031214004382491112,
-0.036399055272340775,
-0.04714939370751381,
-0.017508188262581825,
-0.01582304574549198,
-0.007207220420241356,
-0.05250727757811546,
-0.012798433192074299,
0.01807854324579239,
-0.060215722769498825,
0.0038715044502168894,
-0.01485516969114542,
-0.0062652695924043655,
-0.007868314161896706,
-0.03223372995853424,
0.020446382462978363,
-0.03472255542874336,
0.024559855461120605,
-0.0055868919007480145,
0.03014242835342884,
0.013394714333117008,
-0.01632426679134369,
-0.019634058699011803,
-0.05430476367473602,
-0.022848790511488914,
-0.023574696853756905,
-0.007591778412461281,
-0.006403537467122078,
-0.040754497051239014,
-0.03940638527274132,
-0.04351985827088356,
0.04407292976975441,
-0.021535243839025497,
0.0406162291765213,
0.05613681301474571,
0.009730611927807331,
-0.03173251077532768,
0.016108224168419838,
0.002193924505263567,
0.00042155542178079486,
-0.014725543558597565,
-0.015702061355113983,
0.04766789823770523,
-0.06332675367593765,
0.02991774119436741,
0.08662491291761398,
-0.00925531517714262,
-0.06225517392158508,
-0.007851030677556992,
0.027117814868688583,
-0.049396250396966934,
-0.0035431180149316788,
-0.007941769436001778,
-0.014569992199540138,
0.007743008900433779,
0.017672380432486534,
0.004817776381969452,
-0.07611653953790665,
0.013299655169248581,
0.00022522563813254237,
0.0667143166065216,
0.02646104246377945,
0.020913036540150642,
0.006062188185751438,
0.04790986701846123,
0.013749025762081146,
-0.033236175775527954,
0.009220748208463192,
-0.023108042776584625,
-0.032164596021175385,
-0.003681385889649391,
-0.02150067687034607,
-0.00870224367827177,
0.062220606952905655,
0.03347814455628395,
-0.010905889794230461,
0.05682815611362457,
-0.047218527644872665,
0.01459591742604971,
0.007600420154631138,
-0.043969228863716125,
0.0386459119617939,
0.02034268155694008,
0.06574644148349762,
0.02718694880604744,
-0.008715205825865269,
0.01663537137210369,
0.0456630140542984,
0.11732041090726852,
-0.05043325945734978,
0.0007442708010785282,
-0.008278797380626202,
0.04808270186185837,
0.013066327199339867,
-0.06228974089026451,
0.0030807843431830406,
-0.010758980177342892,
-0.02051551640033722,
-0.008468915708363056,
0.04808270186185837,
-0.018355078995227814,
0.01897728443145752
]
|
32,205 | traittypes.traittypes | valid |
Register new trait validators
Validators are functions that take two arguments.
- The trait instance
- The proposed value
Validators return the (potentially modified) value, which is either
assigned to the HasTraits attribute or input into the next validator.
They are evaluated in the order in which they are provided to the `valid`
function.
Example
-------
.. code:: python
# Test with a shape constraint
def shape(*dimensions):
def validator(trait, value):
if value.shape != dimensions:
raise TraitError('Expected an of shape %s and got and array with shape %s' % (dimensions, value.shape))
else:
return value
return validator
class Foo(HasTraits):
bar = Array(np.identity(2)).valid(shape(2, 2))
foo = Foo()
foo.bar = [1, 2] # Should raise a TraitError
| def valid(self, *validators):
"""
Register new trait validators
Validators are functions that take two arguments.
- The trait instance
- The proposed value
Validators return the (potentially modified) value, which is either
assigned to the HasTraits attribute or input into the next validator.
They are evaluated in the order in which they are provided to the `valid`
function.
Example
-------
.. code:: python
# Test with a shape constraint
def shape(*dimensions):
def validator(trait, value):
if value.shape != dimensions:
raise TraitError('Expected an of shape %s and got and array with shape %s' % (dimensions, value.shape))
else:
return value
return validator
class Foo(HasTraits):
bar = Array(np.identity(2)).valid(shape(2, 2))
foo = Foo()
foo.bar = [1, 2] # Should raise a TraitError
"""
self.validators.extend(validators)
return self
| (self, *validators) | [
0.04007228463888168,
0.0020019894000142813,
-0.024195637553930283,
-0.027909472584724426,
-0.03387017920613289,
0.05622746795415878,
-0.027222413569688797,
-0.0532192587852478,
-0.020611785352230072,
0.06257812678813934,
0.0693744421005249,
0.016080906614661217,
0.03821536526083946,
0.005840006284415722,
-0.010389454662799835,
-0.025811156257987022,
0.060572654008865356,
0.006703472696244717,
-0.016823673620820045,
-0.012023542076349258,
-0.00683809956535697,
0.02376854605972767,
0.0012708280701190233,
-0.012701316736638546,
0.009590979665517807,
0.095594123005867,
0.010612284764647484,
-0.023805685341358185,
0.043600428849458694,
-0.005663598887622356,
-0.03947807103395462,
0.0019625299610197544,
0.05325639992952347,
0.017650002613663673,
0.015997346490621567,
-0.022245874628424644,
0.01108579896390438,
0.033851608633995056,
-0.027556657791137695,
0.09945651143789291,
0.004584265407174826,
-0.016907235607504845,
0.03433440625667572,
-0.0241770688444376,
0.037658289074897766,
-0.008509324863553047,
0.018578460440039635,
0.07784198969602585,
-0.07553941011428833,
-0.023211471736431122,
0.040889326483011246,
-0.06684903800487518,
0.08794362097978592,
-0.03283030539751053,
-0.02007327973842621,
0.09752531349658966,
0.03340594843029976,
0.06216960400342941,
0.07312541455030441,
0.02215302735567093,
-0.009748817421495914,
-0.005450053606182337,
0.047574229538440704,
-0.04404608905315399,
-0.0074508823454380035,
-0.06332089006900787,
-0.02631252259016037,
-0.05734161660075188,
0.00998093280941248,
0.029097899794578552,
-0.019590482115745544,
-0.01777070201933384,
0.010101632215082645,
-0.005705379415303469,
0.015997346490621567,
0.01985044963657856,
-0.08192721009254456,
0.021373122930526733,
0.07732205092906952,
-0.01985044963657856,
0.03624703362584114,
0.029766390100121498,
0.009252091869711876,
-0.011531459167599678,
0.02111315354704857,
-0.010602999478578568,
-0.02371283806860447,
-0.04530879110097885,
0.024158498272299767,
0.04022083804011345,
-0.050805266946554184,
-0.01416828203946352,
0.05500190332531929,
-0.002878222381696105,
-0.021670229732990265,
0.061018314212560654,
0.032756026834249496,
-0.008811074309051037,
-0.006048909388482571,
-0.017148634418845177,
-0.014818202704191208,
0.035578541457653046,
0.005477907136082649,
0.04657149687409401,
-0.005166873335838318,
0.017269333824515343,
-0.07888185977935791,
-0.01910768263041973,
-0.034185852855443954,
0.045568760484457016,
-0.0033331671729683876,
-0.01801210083067417,
0.00211456511169672,
0.06688617169857025,
0.01642443612217903,
-0.06996865570545197,
-0.028058025985956192,
-0.03715692088007927,
-0.04820558428764343,
0.001918428111821413,
0.005064743105322123,
0.019831880927085876,
0.0425976924598217,
0.010723699815571308,
0.027333827689290047,
0.04957970231771469,
0.010045924223959446,
0.043303318321704865,
0.05269932374358177,
-0.04003514349460602,
-0.001651496160775423,
-0.031121939420700073,
0.025198372080922127,
0.008388625457882881,
0.024009944871068,
0.0029849952552467585,
0.024362759664654732,
-0.024919835850596428,
-0.03381447121500969,
0.028410840779542923,
0.0432661809027195,
0.06647765636444092,
-0.02007327973842621,
-0.03567138686776161,
-0.006689545698463917,
-0.01520815584808588,
-0.02187449112534523,
0.03069484978914261,
0.024047084152698517,
-0.0015424021985381842,
-0.043897535651922226,
-0.020853186026215553,
0.0648435652256012,
0.02815087139606476,
-0.016851527616381645,
-0.020853186026215553,
-0.013156261295080185,
-0.04044366627931595,
0.047648508101701736,
-0.017650002613663673,
-0.020500371232628822,
0.024009944871068,
-0.0703771784901619,
-0.022784380242228508,
-0.011874988675117493,
0.05385061353445053,
-0.036618415266275406,
-0.0007723617018200457,
0.0019694932270795107,
0.06053551658987999,
0.014818202704191208,
-0.020964600145816803,
0.016201606020331383,
0.041223570704460144,
-0.01571880839765072,
0.004106109030544758,
0.016851527616381645,
0.00554289948195219,
0.032811734825372696,
0.01719505712389946,
0.01664726622402668,
0.01962761953473091,
-0.05284787714481354,
-0.0004215783264953643,
0.02204161323606968,
0.04634866490960121,
-0.015560969710350037,
0.0055893221870064735,
-0.008741440251469612,
-0.008513967506587505,
0.02510552667081356,
0.041520677506923676,
0.01130862906575203,
0.018541323021054268,
-0.01593235321342945,
0.02781662717461586,
-0.026238245889544487,
0.02880079299211502,
-0.02204161323606968,
-0.007302328944206238,
0.012162811122834682,
0.009804525412619114,
-0.00124413485173136,
0.020853186026215553,
0.01260847132652998,
-0.001887092599645257,
0.027630934491753578,
-0.025012681260704994,
-0.0002090483030769974,
-0.08838928490877151,
-0.0035722453612834215,
-0.013202684931457043,
-0.015347424894571304,
0.021131722256541252,
0.010937245562672615,
-0.053590644150972366,
0.08163010329008102,
-0.06046123802661896,
-0.00578429875895381,
0.03502146899700165,
0.1391945481300354,
0.012376355938613415,
0.07056286931037903,
0.018049240112304688,
-0.004491419531404972,
-0.0019346760818734765,
-0.015430985949933529,
-0.07962463051080704,
-0.04987680912017822,
0.04200347885489464,
0.020908892154693604,
-0.0011965513695031404,
0.01070513017475605,
0.016610128805041313,
-0.04957970231771469,
0.06105545163154602,
0.013601922430098057,
0.001268506865017116,
0.017455026507377625,
0.06075834482908249,
-0.003992373123764992,
0.035002898424863815,
0.009804525412619114,
0.011113652028143406,
0.01968332752585411,
0.01067727617919445,
-0.014465388841927052,
0.04698001593351364,
-0.04007228463888168,
-0.016610128805041313,
-0.050805266946554184,
0.010287323966622353,
0.020871754735708237,
0.0055893221870064735,
-0.021317414939403534,
0.015895215794444084,
-0.05567039176821709,
-0.08660663664340973,
0.10071921348571777,
-0.01433540415018797,
0.03559711202979088,
0.020556079223752022,
0.029766390100121498,
0.10034783184528351,
-0.023100055754184723,
-0.03340594843029976,
0.03981231525540352,
0.055781807750463486,
-0.05065671354532242,
0.016220176592469215,
-0.025941139087080956,
0.05095382034778595,
-0.02077890932559967,
-0.024195637553930283,
0.04014655947685242,
-0.01829063892364502,
0.058084383606910706,
-0.040369391441345215,
0.03255176544189453,
-0.019404789432883263,
0.014251843094825745,
0.019237667322158813,
-0.030100636184215546,
-0.030546296387910843,
0.03619132563471794,
-0.046200111508369446,
-0.024919835850596428,
0.006178893614560366,
-0.034315839409828186,
0.007390532176941633,
0.017362181097269058,
-0.09700538218021393,
0.015923069790005684,
-0.005092596635222435,
0.03151189163327217,
-0.0583072155714035,
-0.03951520845293999,
0.018912706524133682,
0.011577881872653961,
-0.12671606242656708,
0.018253501504659653,
-0.007232694420963526,
-0.025476910173892975,
0.03000778891146183,
-0.02486412785947323,
-0.042969074100255966,
-0.020518939942121506,
0.024325622245669365,
-0.02642393857240677,
0.004280195105820894,
0.049431148916482925,
0.012562047690153122,
-0.07267975807189941,
-0.0027807343285530806,
0.07386818528175354,
-0.003098731394857168,
0.008448975160717964,
-0.024214206263422966,
-0.0035606396850198507,
0.05500190332531929,
0.033610209822654724,
0.01546812430024147,
0.004693359602242708,
-0.07442525774240494,
-0.06124114617705345,
-0.04196633771061897,
0.033610209822654724,
-0.03080626390874386,
-0.056524574756622314,
0.01587664522230625,
-0.026163969188928604,
-0.040480803698301315,
0.061946772038936615,
0.028837932273745537,
-0.04605155810713768,
0.0016561384545639157,
0.034185852855443954,
0.018745584413409233,
0.02850368618965149,
0.012153525836765766,
-0.0009394842782057822,
-0.03227322921156883,
-0.016006629914045334,
-0.01492033340036869,
-0.06127828359603882,
-0.019571911543607712,
-0.06358086317777634,
0.03375876322388649,
0.0010271075880154967,
0.021150292828679085,
0.030917679890990257,
0.016498712822794914,
0.019293375313282013,
-0.05541042238473892,
-0.03487291559576988,
-0.06280095875263214,
-0.00525043485686183,
-0.002027522074058652,
0.004554090555757284,
-0.051102373749017715,
0.01705578900873661,
0.031938984990119934,
-0.039849452674388885,
-0.01921909861266613,
-0.002287490526214242,
0.004066649824380875,
0.004649257753044367,
-0.0425976924598217,
0.053553506731987,
-0.02978495880961418,
0.04155781865119934,
0.049839671701192856,
0.007446239702403545,
0.024195637553930283,
0.02562546357512474,
0.040592219680547714,
0.012952000834047794,
0.04497454687952995,
-0.04612583667039871,
-0.04638580232858658,
0.01492033340036869,
0.01820707693696022,
0.01779855601489544,
-0.031084802001714706,
0.018745584413409233,
-0.04181778430938721,
-0.04928259551525116,
0.01779855601489544,
-0.028782224282622337,
0.030212050303816795,
0.018792007118463516,
-0.029692113399505615,
-0.04690574109554291,
-0.012803447432816029,
-0.10569575428962708,
0.0045958710834383965,
0.018662022426724434,
0.02428848296403885,
0.026906736195087433,
-0.039440929889678955,
0.04716571047902107,
-0.0481313057243824,
0.0374540276825428,
0.02187449112534523,
0.028132302686572075,
0.039218101650476456,
0.023582855239510536,
0.03918096423149109,
0.020407525822520256,
0.035411421209573746,
-0.0029896374326199293,
0.008509324863553047,
0.04664577171206474,
-0.039440929889678955,
-0.029914943501353264,
-0.03145618364214897,
-0.011865704320371151,
-0.011382905766367912,
0.004217524081468582,
-0.018309207633137703,
0.0214659683406353,
-0.033554501831531525,
-0.03814109042286873,
0.02551404945552349,
0.02776091918349266,
0.015969492495059967,
-0.009962363168597221,
0.004888335708528757,
0.0007932520238682628,
0.0009754620841704309,
0.0032287156209349632,
0.0029641047585755587,
-0.039960868656635284,
-0.042671967297792435,
-0.04285765811800957,
-0.06424935162067413,
-0.05262504518032074,
-0.03351736441254616,
-0.004252341575920582,
0.04077791050076485,
0.036395587027072906,
0.006568846292793751,
0.022301580756902695,
0.02850368618965149,
-0.017213627696037292,
-0.014530381187796593,
-0.000025315010134363547,
0.03910668566823006,
-0.019590482115745544,
-0.04386039450764656,
0.048094168305397034,
0.010667991824448109,
-0.004818701185286045,
0.04980253055691719,
0.052142247557640076,
0.00249523320235312,
0.03138190880417824,
-0.0751308873295784,
-0.033387381583452225,
-0.043711841106414795,
-0.002917681820690632,
0.019590482115745544,
-0.026238245889544487,
-0.016767967492341995,
-0.08838928490877151,
-0.016359444707632065,
-0.02233872003853321,
-0.0008849373552948236,
0.020500371232628822,
0.023452870547771454,
0.029302161186933517,
-0.030490588396787643,
0.0054686227813363075,
-0.037472598254680634,
-0.0637294128537178,
0.03452010080218315,
0.07089711725711823,
-0.0013404624769464135,
-0.05073099210858345,
-0.029413575306534767,
0.02694387547671795,
0.002446488942950964,
-0.0036697336472570896,
0.0040016574785113335,
0.006893807090818882,
0.007729419972747564,
-0.03758401423692703,
-0.024437036365270615,
-0.054741933941841125,
0.06562346965074539,
-0.020128987729549408,
-0.031066233292222023,
-0.024084221571683884,
0.03583851084113121,
-0.02272867225110531,
-0.03179043158888817,
0.047462817281484604,
-0.04137212410569191,
0.021893059834837914,
-0.01587664522230625,
0.010955814272165298,
0.037713997066020966,
0.00023820772184990346,
-0.010538008064031601,
0.0023640883155167103,
-0.049765393137931824,
-0.008244714699685574,
-0.02880079299211502,
-0.0215216763317585,
-0.01815137080848217,
-0.022988641634583473,
-0.009516702964901924,
-0.04490026831626892,
0.01388045959174633,
0.028577962890267372,
-0.04560589790344238,
-0.0065874154679477215,
-0.013026277534663677,
-0.006197462789714336,
0.016907235607504845,
0.014706787653267384,
0.03088054060935974,
0.04575445130467415,
-0.002051894087344408,
-0.004066649824380875,
0.0327003188431263,
-0.005946778692305088,
-0.06592057645320892,
0.008383983746170998,
-0.04460316151380539,
0.04230058565735817,
-0.04434319585561752,
-0.036451295018196106,
0.052142247557640076,
-0.05867859721183777,
-0.00861145555973053,
0.038401056081056595,
0.014604657888412476,
0.011206498369574547,
0.037194062024354935,
0.05154803395271301,
0.06060979142785072,
0.025644032284617424,
0.024919835850596428,
0.025439772754907608,
-0.03793682903051376,
-0.010538008064031601,
-0.06023840978741646,
0.042263444513082504,
-0.0022480308543890715,
-0.08482399582862854,
0.01130862906575203,
-0.024622729048132896,
0.01122506707906723,
-0.013258391991257668,
0.004612119402736425,
0.027482381090521812,
0.006299593020230532,
0.002434883266687393,
0.050693850964307785,
0.012394925579428673,
0.04924545809626579,
0.017130065709352493,
-0.02337859384715557,
-0.047648508101701736,
-0.0012487771455198526,
0.03513288125395775,
0.014131143689155579,
-0.009228880517184734,
0.04471457749605179,
0.014121859334409237,
0.017640717327594757,
-0.061723943799734116,
-0.02285865694284439,
0.005338638089597225,
0.012692032381892204,
-0.046200111508369446,
0.0427091047167778,
-0.07267975807189941,
-0.037194062024354935,
-0.024678435176610947,
-0.03151189163327217,
-0.008072949945926666,
-0.06655193120241165,
0.02770521119236946,
0.011652158573269844,
-0.06008985638618469,
0.050062499940395355,
-0.04646008089184761,
0.0014495563227683306,
-0.015486693009734154,
0.009331011213362217,
-0.05737875774502754,
-0.0045958710834383965,
0.041000742465257645,
0.004846555180847645,
-0.0372869074344635,
-0.03583851084113121,
-0.05593036115169525,
0.011865704320371151,
-0.032161813229322433,
0.00897819735109806,
-0.020500371232628822,
-0.010064493864774704,
0.02590400166809559,
-0.04159495607018471,
0.01096509862691164,
0.03866102546453476,
-0.025495478883385658,
-0.06736897677183151,
-0.010073778219521046,
-0.01777070201933384,
0.024251345545053482,
0.028930777683854103,
0.012719886377453804,
-0.027630934491753578,
-0.09121179580688477,
0.050990957766771317,
0.03140047937631607,
0.031827569007873535,
0.02170736715197563,
-0.006155682262033224,
-0.016832958906888962,
-0.004085218999534845,
-0.02245013415813446,
-0.06086976081132889,
0.00020252008107490838,
-0.012441348284482956,
-0.000899444508831948,
-0.051733724772930145,
0.030286327004432678,
0.02094603143632412,
0.06228101998567581,
-0.09373720735311508,
0.001095001120120287,
-0.018392769619822502,
-0.0032240732107311487,
0.02475271187722683,
0.03548569604754448,
-0.017844978719949722,
-0.08244714140892029,
-0.015607393346726894,
0.029673544690012932,
0.018931275233626366,
-0.014808918349444866,
0.022060181945562363,
-0.04148354008793831,
0.015728091821074486,
0.12263084203004837,
-0.023100055754184723,
0.04920831695199013,
0.06458359956741333,
-0.01485534105449915,
-0.026052555069327354,
0.0646207332611084,
-0.03312741219997406,
0.04920831695199013,
0.006081405561417341,
0.014827487990260124,
0.03140047937631607,
-0.011429328471422195,
0.005621818359941244,
0.0594213642179966,
-0.030286327004432678,
0.022227304056286812,
-0.008513967506587505,
-0.015124594792723656,
-0.020407525822520256,
-0.01338837668299675,
0.022245874628424644,
-0.06502925604581833,
-0.013026277534663677,
-0.05188227817416191,
-0.020797478035092354,
0.011466466821730137,
0.011856419034302235,
-0.018337061628699303,
-0.03966376185417175,
-0.030156342312693596,
0.0014379506465047598,
-0.04252341389656067,
0.009535272605717182,
-0.023675700649619102,
0.013889743946492672,
-0.055707529187202454,
-0.032644614577293396,
0.015412416309118271,
0.019089113920927048,
-0.022951502352952957,
-0.045271653681993484,
0.0006882201414555311,
-0.04081505164504051,
0.06569774448871613,
-0.005677525885403156,
-0.019757604226469994,
0.00969311036169529,
-0.029673544690012932,
0.03760258108377457,
0.003405122784897685,
0.01326767634600401,
0.02984066680073738,
-0.027612365782260895,
-0.05477907136082649,
0.01831849291920662,
-0.010231615975499153,
-0.006605984643101692,
0.012515624985098839,
-0.019980434328317642,
0.027166705578565598,
-0.021038876846432686,
0.018086377531290054,
0.043711841106414795,
0.038920994848012924,
-0.05043388530611992,
-0.013276961632072926,
-0.007933680899441242,
0.062132466584444046,
0.038586750626564026,
0.07104566693305969,
-0.04404608905315399,
0.048614103347063065,
0.030100636184215546,
-0.015542401000857353,
-0.0316418781876564,
-0.03110337071120739,
0.020797478035092354,
0.0325889065861702,
-0.015338139608502388,
0.06138969957828522,
-0.04081505164504051,
0.041297849267721176,
-0.013193399645388126,
-0.10510154068470001,
0.033034566789865494,
-0.0632837563753128,
-0.01951620541512966,
-0.03479863703250885,
-0.00002254051469208207,
-0.0070516448467969894,
0.015310286544263363,
0.021670229732990265,
0.04207775369286537,
0.0703771784901619,
-0.014678934589028358,
0.059755612164735794,
0.0010758517310023308,
0.014353973791003227,
0.017919255420565605,
0.004563375376164913,
0.005626460537314415,
-0.02649821527302265,
-0.004386967979371548,
-0.007553012575954199,
0.02781662717461586,
0.06528922915458679,
-0.03628417104482651,
0.037713997066020966,
-0.03633987903594971,
-0.018077094107866287,
-0.02089032344520092,
-0.03633987903594971,
0.010454446077346802,
0.01580236852169037,
-0.027389535680413246,
0.021725937724113464,
0.016721542924642563,
0.012357787229120731,
0.01743645779788494
]
|
32,206 | traittypes.traittypes | validate | null | def validate(self, obj, value):
if value is None and not self.allow_none:
self.error(obj, value)
if value is None or value is Undefined:
return super(Array, self).validate(obj, value)
try:
r = np.asarray(value, dtype=self.dtype)
if isinstance(value, np.ndarray) and r is not value:
warnings.warn(
'Given trait value dtype "%s" does not match required type "%s". '
'A coerced copy has been created.' % (
np.dtype(value.dtype).name,
np.dtype(self.dtype).name))
value = r
except (ValueError, TypeError) as e:
raise TraitError(e)
return super(Array, self).validate(obj, value)
| (self, obj, value) | [
0.05017097294330597,
-0.00977939274162054,
0.0018370006000623107,
0.007540898397564888,
-0.030109763145446777,
-0.010739387944340706,
-0.004835864529013634,
-0.016965899616479874,
-0.009564066305756569,
-0.00507810665294528,
0.042203910648822784,
-0.0023304561618715525,
0.0297508854418993,
-0.0503145270049572,
-0.005122966133058071,
0.04198858514428139,
0.034685440361499786,
0.03843570500612259,
0.029051076620817184,
0.058676354587078094,
-0.014480678364634514,
-0.04611566662788391,
-0.059071119874715805,
0.03012770600616932,
0.0019570000004023314,
0.03447011485695839,
0.04317287728190422,
-0.047945939004421234,
0.02530081383883953,
0.018482154235243797,
-0.04966854676604271,
0.023560261353850365,
0.050386302173137665,
0.05279077589511871,
0.025605859234929085,
-0.06050662696361542,
-0.023847362026572227,
-0.0169120691716671,
-0.05885579437017441,
0.03622861206531525,
-0.04356764256954193,
0.005311376415193081,
0.004113625269383192,
0.00536520779132843,
0.005248573143035173,
-0.021353168413043022,
-0.014983105473220348,
0.07493346929550171,
-0.0864175334572792,
0.004535305313766003,
0.016813376918435097,
-0.03434450924396515,
0.04701285809278488,
0.010757331736385822,
-0.01601487584412098,
0.0962507575750351,
0.005611935630440712,
0.03804093971848488,
0.028333323076367378,
0.018966637551784515,
-0.03459572046995163,
0.008837340399622917,
0.06524380296468735,
-0.07916821539402008,
0.009110984392464161,
-0.042598675936460495,
0.01533301081508398,
-0.006141278892755508,
0.012910592369735241,
0.04213213548064232,
-0.04396240785717964,
-0.000989154097624123,
0.013969278894364834,
0.035905621945858,
0.05236012488603592,
-0.012659378349781036,
-0.04227568581700325,
0.051534704864025116,
0.04148615524172783,
-0.04252690076828003,
0.02680809609591961,
0.07238544523715973,
0.0034923197235912085,
0.015476561151444912,
-0.020527752116322517,
0.004109139088541269,
-0.06294699013233185,
0.015961045399308205,
0.04281400144100189,
0.07008863985538483,
0.000266494054812938,
-0.02273484505712986,
0.0072223953902721405,
0.03933289647102356,
-0.01812327839434147,
0.07486169785261154,
0.021263450384140015,
-0.06517202407121658,
-0.016041792929172516,
0.007460151333361864,
0.011762186884880066,
-0.0063162315636873245,
0.060829613357782364,
0.036964308470487595,
0.017737485468387604,
0.015440673567354679,
0.0467616468667984,
-0.019845886155962944,
0.0005425207782536745,
0.04916612058877945,
-0.004988387227058411,
0.026269780471920967,
-0.035457026213407516,
0.022268304601311684,
-0.02208886668086052,
-0.06746883690357208,
-0.06822247803211212,
-0.029589390382170677,
-0.05566179007291794,
0.018212996423244476,
-0.006428380496799946,
0.025211093947291374,
0.03332170844078064,
0.006208568345755339,
0.06664341688156128,
0.03283722698688507,
-0.022537462413311005,
-0.009043695405125618,
0.03102489747107029,
-0.007724822964519262,
-0.0354929156601429,
-0.04661809280514717,
-0.022447742521762848,
-0.021101955324411392,
-0.022250359877943993,
0.037215523421764374,
0.0457209013402462,
-0.03283722698688507,
-0.019415233284235,
-0.02732846699655056,
0.04023008793592453,
0.02067130245268345,
0.07199068367481232,
-0.0678635984659195,
0.05541057512164116,
0.053580302745103836,
0.020617472007870674,
0.0640953928232193,
-0.046941082924604416,
-0.0032052183523774147,
-0.03836392983794212,
0.01954084075987339,
0.022663069888949394,
0.00932182464748621,
0.018679536879062653,
-0.020115043967962265,
-0.007294170558452606,
-0.09711205959320068,
0.03475721552968025,
-0.003853439586237073,
-0.03310638293623924,
0.0264133308082819,
-0.025857072323560715,
-0.0321553610265255,
-0.00397680327296257,
0.05910700559616089,
0.01667879894375801,
0.014471706002950668,
-0.03829215466976166,
0.03066602163016796,
-0.014758807606995106,
-0.06427483260631561,
0.0017977483803406358,
0.05182180926203728,
0.017486270517110825,
0.04561324045062065,
-0.005728570744395256,
0.012470968067646027,
-0.001683356473222375,
0.04712052270770073,
0.004723715595901012,
0.026072397828102112,
-0.04048130288720131,
0.02095840498805046,
0.020976347848773003,
0.03472132980823517,
-0.019827943295240402,
-0.0013110217405483127,
0.03750262409448624,
0.041952695697546005,
0.0010127053828909993,
0.07356973737478256,
0.026520993560552597,
-0.018553929403424263,
-0.019253740087151527,
-0.01878719963133335,
0.006082961335778236,
-0.01626609079539776,
-0.03427273407578468,
0.02094046026468277,
0.010416398756206036,
-0.070160411298275,
0.022250359877943993,
0.002637744415551424,
-0.0640953928232193,
-0.020994292572140694,
0.007078844588249922,
-0.013996195048093796,
0.020258594304323196,
-0.040158312767744064,
-0.04356764256954193,
-0.023847362026572227,
-0.05426216870546341,
-0.003638113383203745,
0.06326998025178909,
-0.059322331100702286,
0.02388324961066246,
-0.07324675470590591,
-0.01966644823551178,
0.059178780764341354,
0.09725560992956161,
0.031114617362618446,
0.005387637764215469,
-0.014032082632184029,
0.0211916733533144,
-0.009564066305756569,
0.0014366286341100931,
-0.048843130469322205,
0.00698912562802434,
0.03678486868739128,
0.0010261633433401585,
0.00042364283581264317,
-0.043424092233181,
-0.002604099689051509,
-0.01979205384850502,
0.10515090078115463,
0.04127082973718643,
-0.019504953175783157,
-0.015306094661355019,
0.04087606444954872,
-0.01651730388402939,
-0.02540847659111023,
0.01206723228096962,
0.005921466741710901,
-0.012596575543284416,
0.040158312767744064,
-0.015512448735535145,
0.07859401404857635,
-0.03202975168824196,
-0.024618947878479958,
-0.009501262567937374,
0.0033734417520463467,
-0.022196529433131218,
-0.03592356666922569,
0.018876919522881508,
-0.03753851354122162,
0.007128190249204636,
-0.07766093313694,
0.09718383103609085,
-0.006863518618047237,
-0.018464211374521255,
0.01366423349827528,
0.04956088587641716,
0.06894022971391678,
-0.07967064529657364,
-0.024852218106389046,
0.030432751402258873,
0.05559001490473747,
-0.0036605431232601404,
0.07356973737478256,
-0.05738439783453941,
0.024744553491473198,
0.016490388661623,
-0.009447431191802025,
0.012273586355149746,
0.029302289709448814,
0.03457777947187424,
0.03922523185610771,
0.06434660404920578,
0.01850009895861149,
0.019953548908233643,
-0.028656311333179474,
0.019361402839422226,
-0.03662337735295296,
-0.026933703571558,
-0.07346207648515701,
-0.0023259702138602734,
-0.028692198917269707,
-0.04819715395569801,
0.00394540186971426,
-0.019989436492323875,
-0.03470338508486748,
-0.013727037236094475,
-0.0015027965418994427,
-0.036479827016592026,
-0.006585388910025358,
-0.0367489829659462,
-0.03188620135188103,
0.03260395675897598,
-0.015162544324994087,
-0.02094046026468277,
0.041845034807920456,
-0.01277601346373558,
-0.0019704578444361687,
0.019002525135874748,
-0.03836392983794212,
-0.025246981531381607,
0.002268774202093482,
-0.020653359591960907,
0.020850740373134613,
0.04442894458770752,
0.013646289706230164,
-0.04762294888496399,
0.030307143926620483,
0.061870358884334564,
0.04762294888496399,
0.06344941258430481,
-0.02323727123439312,
-0.010039578191936016,
0.06301876157522202,
-0.022950170561671257,
-0.0097076166421175,
-0.012372276745736599,
-0.06772004812955856,
-0.02847687341272831,
-0.017611877992749214,
0.06011186167597771,
-0.010981629602611065,
-0.041701480746269226,
0.05878401920199394,
0.022501574829220772,
-0.021891484037041664,
0.017378607764840126,
0.016194315627217293,
0.05347264185547829,
0.011636579409241676,
-0.018446266651153564,
-0.03692842274904251,
-0.0002369147550780326,
0.030450696125626564,
-0.03222713619470596,
0.015566281042993069,
0.037610288709402084,
0.002162232529371977,
0.00654501561075449,
-0.019971493631601334,
-0.026018567383289337,
0.006181652657687664,
0.026592770591378212,
0.021478775888681412,
-0.03228096663951874,
0.02783089503645897,
0.008124073036015034,
-0.0168044064193964,
-0.047945939004421234,
-0.05515936017036438,
-0.0216043833643198,
-0.00341605837456882,
-0.030432751402258873,
-0.04432128369808197,
0.04414184391498566,
-0.010174157097935677,
0.027633512392640114,
0.001496067619882524,
-0.0036897019017487764,
0.03138377517461777,
-0.03836392983794212,
-0.08598687499761581,
0.03350114822387695,
-0.0211916733533144,
-0.027866782620549202,
0.043424092233181,
-0.037861499935388565,
-0.04945322126150131,
0.04277811199426651,
0.020330369472503662,
-0.013332272879779339,
0.029912380501627922,
-0.004463530145585537,
-0.017863091081380844,
0.037610288709402084,
0.011780130676925182,
-0.027633512392640114,
-0.025839129462838173,
-0.02287839539349079,
-0.02284250780940056,
-0.044787824153900146,
0.015270207077264786,
-0.05081695318222046,
-0.03375236317515373,
-0.0063745491206645966,
-0.00145232945214957,
0.010183128528296947,
-0.03393179923295975,
-0.046546317636966705,
0.030576301738619804,
0.02312960848212242,
0.01611356809735298,
-0.027741175144910812,
-0.024170352146029472,
-0.014489649794995785,
-0.002225036034360528,
-0.018177108839154243,
0.04518258571624756,
-0.0030392378102988005,
0.03380619361996651,
0.013691149652004242,
-0.00829902570694685,
0.0013626102590933442,
0.05092461407184601,
0.060865502804517746,
-0.0025323242880403996,
0.06466959416866302,
-0.030863404273986816,
0.006168194580823183,
-0.0022956898901611567,
-0.02196325920522213,
-0.027507904917001724,
0.007482580840587616,
-0.009815280325710773,
0.023039890453219414,
-0.005737542640417814,
-0.03077368438243866,
0.035331420600414276,
0.015629084780812263,
-0.0029495186172425747,
0.012282557785511017,
-0.022663069888949394,
0.02248363010585308,
-0.022537462413311005,
0.002888958202674985,
0.01661599427461624,
-0.034183014184236526,
-0.045900341123342514,
-0.024583060294389725,
-0.03283722698688507,
-0.030558358877897263,
-0.029930323362350464,
0.008918087929487228,
0.028835749253630638,
0.02361409179866314,
0.016490388661623,
0.035331420600414276,
0.07209834456443787,
0.002700547920539975,
-0.023309046402573586,
0.031114617362618446,
0.008801452815532684,
-0.07801981270313263,
-0.0297508854418993,
0.04331642761826515,
0.009061639197170734,
0.02578529715538025,
0.008496408350765705,
-0.03585179150104523,
-0.009119956754148006,
-0.016041792929172516,
-0.056379541754722595,
0.026592770591378212,
-0.05411861836910248,
-0.04633099213242531,
0.0413426049053669,
-0.04966854676604271,
-0.09696850925683975,
-0.018553929403424263,
0.040804289281368256,
-0.020348314195871353,
0.01757599040865898,
0.03628244251012802,
0.04582856595516205,
0.038112714886665344,
-0.056630756705999374,
0.049237895756959915,
-0.015602168627083302,
-0.02259129285812378,
0.04023008793592453,
0.03929700702428818,
0.0346495546400547,
-0.018275801092386246,
0.002105036750435829,
0.021514663472771645,
0.02120961807668209,
-0.010766303166747093,
-0.01699281670153141,
0.005001845303922892,
-0.005064648576080799,
-0.062121570110321045,
0.013457879424095154,
-0.02948172762989998,
0.08569977432489395,
-0.029284344986081123,
0.0074332356452941895,
-0.05856868997216225,
0.03515198081731796,
0.025767352432012558,
-0.009913971647620201,
0.04277811199426651,
-0.01533301081508398,
0.019110189750790596,
0.016562163829803467,
0.008868742734193802,
0.03127611055970192,
-0.041809145361185074,
-0.02399091236293316,
-0.045290250331163406,
-0.0649208128452301,
0.002062420127913356,
-0.008639958687126637,
-0.019899718463420868,
-0.0016082165529951453,
-0.05652309209108353,
0.06133204326033592,
0.008240708149969578,
0.007612674031406641,
0.042311571538448334,
-0.008563697338104248,
-0.006504641845822334,
-0.026861926540732384,
-0.044500719755887985,
-0.012300501577556133,
0.010362567380070686,
-0.008231736719608307,
-0.023685866966843605,
-0.03893813118338585,
0.001191022340208292,
0.03635421767830849,
-0.04392651841044426,
-0.07188302278518677,
0.041450269520282745,
-0.05788682401180267,
0.02705930918455124,
-0.03470338508486748,
0.03495460003614426,
0.07845046371221542,
-0.004149512853473425,
-0.011394337750971317,
0.036479827016592026,
0.02553408406674862,
-0.03217330202460289,
0.019487010315060616,
-0.010389482602477074,
0.04277811199426651,
0.038005050271749496,
0.016131510958075523,
-0.0027925099711865187,
0.019343458116054535,
0.0006560716428793967,
0.011789102107286453,
-0.00915584433823824,
0.004607080947607756,
-0.05142704397439957,
-0.0064552961848676205,
0.07450281828641891,
0.07500524818897247,
-0.026610713452100754,
0.007352488115429878,
0.02939200960099697,
0.013072086498141289,
0.029607335105538368,
0.020761022344231606,
0.010120325721800327,
-0.0060022142715752125,
0.02298605814576149,
-0.042455125600099564,
-0.048089489340782166,
0.0013805541675537825,
-0.01073041558265686,
0.053867407143116,
0.020976347848773003,
0.03176059573888779,
-0.00959098245948553,
-0.02668248862028122,
-0.08620220422744751,
-0.010954713448882103,
0.03893813118338585,
0.04432128369808197,
-0.056630756705999374,
0.03669515252113342,
-0.08964741975069046,
-0.027938557788729668,
-0.0411272794008255,
-0.027113141492009163,
0.024708665907382965,
-0.05993242189288139,
0.04417773336172104,
-0.04457249864935875,
-0.012300501577556133,
-0.009528178721666336,
-0.036731038242578506,
-0.021371113136410713,
-0.016131510958075523,
0.00753192650154233,
-0.057779163122177124,
-0.010120325721800327,
0.035905621945858,
0.05117582902312279,
-0.061367928981781006,
-0.046438656747341156,
0.013780868612229824,
-0.020258594304323196,
0.016885152086615562,
0.018589816987514496,
-0.01851804181933403,
0.013816756196320057,
0.008913601748645306,
0.015027965418994427,
-0.021137842908501625,
0.00845603458583355,
0.037359073758125305,
-0.051678258925676346,
-0.0039498875848948956,
0.06352119147777557,
0.01964850351214409,
-0.044787824153900146,
-0.013072086498141289,
-0.013439935632050037,
-0.06524380296468735,
0.047443512827157974,
-0.011403310112655163,
0.02298605814576149,
0.047838274389505386,
-0.006100905127823353,
-0.0028239116072654724,
-0.008505379781126976,
-0.02501371130347252,
-0.05993242189288139,
0.013727037236094475,
-0.014543482102453709,
-0.02847687341272831,
-0.05896345525979996,
0.047299958765506744,
0.013996195048093796,
0.026592770591378212,
-0.042957551777362823,
-0.038005050271749496,
-0.032496292144060135,
-0.018948694691061974,
-0.0059438967145979404,
0.031850315630435944,
0.052575450390577316,
-0.04084017872810364,
-0.025839129462838173,
0.01366423349827528,
0.0666075348854065,
-0.03692842274904251,
-0.009501262567937374,
-0.040553078055381775,
-0.0024919507559388876,
0.03353703394532204,
0.01630197837948799,
0.0245292279869318,
0.03316021338105202,
-0.05598478019237518,
-0.0678635984659195,
0.052180685102939606,
0.05106816813349724,
0.04062485322356224,
0.011708355508744717,
-0.03504431992769241,
0.018966637551784515,
-0.06326998025178909,
0.019469065591692924,
-0.00406652269884944,
-0.033285822719335556,
0.08699173480272293,
0.007540898397564888,
0.008882200345396996,
-0.03310638293623924,
0.004939041566103697,
0.01034462358802557,
-0.09208778291940689,
0.03228096663951874,
-0.062121570110321045,
0.028028277680277824,
-0.01091882586479187,
-0.021173730492591858,
-0.026610713452100754,
-0.026215950027108192,
-0.01533301081508398,
-0.023721756413578987,
-0.010281819850206375,
0.00813304539769888,
-0.057133182883262634,
0.04302932694554329,
-0.033895913511514664,
-0.059573546051979065,
0.01584441028535366,
0.023703811690211296,
-0.01954084075987339,
-0.08591510355472565,
-0.005212685093283653,
0.003081854432821274,
0.03664131835103035,
-0.026538938283920288,
-0.008482949808239937,
-0.05878401920199394,
-0.03253218159079552,
0.11821401119232178,
0.005028760991990566,
0.08110615611076355,
0.014202549122273922,
-0.019128132611513138,
-0.025516139343380928,
0.04048130288720131,
0.016050763428211212,
0.003386899596080184,
-0.047443512827157974,
-0.010613781400024891,
0.02824360318481922,
-0.04256278648972511,
0.004479230847209692,
0.06919144093990326,
-0.01918196491897106,
-0.09022162109613419,
-0.057420287281274796,
0.011887793429195881,
-0.006141278892755508,
0.01651730388402939,
0.03398563340306282,
-0.02363203652203083,
0.0010799948358908296,
0.04417773336172104,
-0.01334124431014061,
0.0066526783630251884,
-0.0008938274695537984,
0.041809145361185074,
0.02847687341272831,
-0.047192297875881195,
0.047335848212242126,
-0.001815692288801074,
0.07766093313694,
0.004939041566103697,
-0.003259049728512764,
0.030737796798348427,
-0.014328155666589737,
0.011286674998700619,
-0.037359073758125305,
-0.0069666956551373005,
-0.00622202642261982,
0.017297860234975815,
0.03961999714374542,
0.0026556882075965405,
0.046546317636966705,
-0.013682177290320396,
0.049991536885499954,
-0.012605546973645687,
-0.020491864532232285,
0.038112714886665344,
0.0183744914829731,
-0.027669399976730347,
0.008693790063261986,
-0.028710143640637398,
0.010793219320476055,
0.06061428785324097,
0.06926321983337402,
-0.05731262266635895,
0.004104653373360634,
-0.03037891909480095,
0.03897402063012123,
-0.0026399872731417418,
-0.055482350289821625,
0.0034609180875122547,
-0.03574412688612938,
0.038507480174303055,
-0.03929700702428818,
0.010820135474205017,
-0.023470541462302208,
0.029786773025989532
]
|
32,207 | bqplot.axes | Axis | A line axis.
A line axis is the visual representation of a numerical or date scale.
Attributes
----------
icon: string (class-level attribute)
The font-awesome icon name for this object.
axis_types: dict (class-level attribute)
A registry of existing axis types.
orientation: {'horizontal', 'vertical'}
The orientation of the axis, either vertical or horizontal
side: {'bottom', 'top', 'left', 'right'} or None (default: None)
The side of the axis, either bottom, top, left or right.
label: string (default: '')
The axis label
tick_format: string or None (default: '')
The tick format for the axis, for dates use d3 string formatting.
scale: Scale
The scale represented by the axis
num_ticks: int or None (default: None)
If tick_values is None, number of ticks
tick_values: numpy.ndarray or None (default: None)
Tick values for the axis
tick_labels: dict (default: None)
Override the tick labels with a dictionary of {value: label}.
Entries are optional, and if not provided, the default tick labels
will be used.
offset: dict (default: {})
Contains a scale and a value {'scale': scale or None,
'value': value of the offset}
If offset['scale'] is None, the corresponding figure scale is used
instead.
label_location: {'middle', 'start', 'end'}
The location of the label along the axis, one of 'start', 'end' or
'middle'
label_color: Color or None (default: None)
The color of the axis label
grid_lines: {'none', 'solid', 'dashed'}
The display of the grid lines
grid_color: Color or None (default: None)
The color of the grid lines
color: Color or None (default: None)
The color of the line
label_offset: string or None (default: None)
Label displacement from the axis line. Units allowed are 'em', 'px'
and 'ex'. Positive values are away from the figure and negative
values are towards the figure with respect to the axis line.
visible: bool (default: True)
A visibility toggle for the axis
tick_style: Dict (default: {})
Dictionary containing the CSS-style of the text for the ticks.
For example: font-size of the text can be changed by passing
`{'font-size': 14}`
tick_rotate: int (default: 0)
Degrees to rotate tick labels by.
| class Axis(BaseAxis):
"""A line axis.
A line axis is the visual representation of a numerical or date scale.
Attributes
----------
icon: string (class-level attribute)
The font-awesome icon name for this object.
axis_types: dict (class-level attribute)
A registry of existing axis types.
orientation: {'horizontal', 'vertical'}
The orientation of the axis, either vertical or horizontal
side: {'bottom', 'top', 'left', 'right'} or None (default: None)
The side of the axis, either bottom, top, left or right.
label: string (default: '')
The axis label
tick_format: string or None (default: '')
The tick format for the axis, for dates use d3 string formatting.
scale: Scale
The scale represented by the axis
num_ticks: int or None (default: None)
If tick_values is None, number of ticks
tick_values: numpy.ndarray or None (default: None)
Tick values for the axis
tick_labels: dict (default: None)
Override the tick labels with a dictionary of {value: label}.
Entries are optional, and if not provided, the default tick labels
will be used.
offset: dict (default: {})
Contains a scale and a value {'scale': scale or None,
'value': value of the offset}
If offset['scale'] is None, the corresponding figure scale is used
instead.
label_location: {'middle', 'start', 'end'}
The location of the label along the axis, one of 'start', 'end' or
'middle'
label_color: Color or None (default: None)
The color of the axis label
grid_lines: {'none', 'solid', 'dashed'}
The display of the grid lines
grid_color: Color or None (default: None)
The color of the grid lines
color: Color or None (default: None)
The color of the line
label_offset: string or None (default: None)
Label displacement from the axis line. Units allowed are 'em', 'px'
and 'ex'. Positive values are away from the figure and negative
values are towards the figure with respect to the axis line.
visible: bool (default: True)
A visibility toggle for the axis
tick_style: Dict (default: {})
Dictionary containing the CSS-style of the text for the ticks.
For example: font-size of the text can be changed by passing
`{'font-size': 14}`
tick_rotate: int (default: 0)
Degrees to rotate tick labels by.
"""
icon = 'fa-arrows'
orientation = Enum(['horizontal', 'vertical'], default_value='horizontal')\
.tag(sync=True)
side = Enum(['bottom', 'top', 'left', 'right'],
allow_none=True, default_value=None).tag(sync=True)
label = Unicode().tag(sync=True)
grid_lines = Enum(['none', 'solid', 'dashed'], default_value='solid')\
.tag(sync=True)
tick_format = Unicode(None, allow_none=True).tag(sync=True)
scale = Instance(Scale).tag(sync=True, **widget_serialization)
num_ticks = Int(default_value=None, allow_none=True).tag(sync=True)
tick_values = Array(None, allow_none=True)\
.tag(sync=True, **array_serialization)\
.valid(array_dimension_bounds(1, 1))
tick_labels = Dict(None, allow_none=True).tag(sync=True)
offset = Dict().tag(sync=True, **widget_serialization)
label_location = Enum(['middle', 'start', 'end'],
default_value='middle').tag(sync=True)
label_color = Color(None, allow_none=True).tag(sync=True)
grid_color = Color(None, allow_none=True).tag(sync=True)
color = Color(None, allow_none=True).tag(sync=True)
label_offset = Unicode(default_value=None, allow_none=True).tag(sync=True)
visible = Bool(True).tag(sync=True)
tick_style = Dict().tag(sync=True)
tick_rotate = Int(0).tag(sync=True)
_view_name = Unicode('Axis').tag(sync=True)
_model_name = Unicode('AxisModel').tag(sync=True)
_ipython_display_ = None # We cannot display an axis outside of a figure.
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.025294357910752296,
-0.027900103479623795,
-0.0268764179199934,
0.031101450324058533,
0.0006863350863568485,
-0.011539735831320286,
-0.060565002262592316,
0.028979627415537834,
-0.016741923987865448,
-0.013652252033352852,
0.04091022536158562,
0.008035937324166298,
0.06413859874010086,
0.010097268968820572,
-0.003438655287027359,
0.017235154286026955,
0.008412839844822884,
0.004574016202241182,
0.008547780103981495,
-0.03031972609460354,
0.025741055607795715,
-0.02927742712199688,
-0.02624359354376793,
0.014108258299529552,
0.030859487131237984,
0.042510900646448135,
0.0056814588606357574,
0.002132291905581951,
-0.02683919295668602,
-0.04932306706905365,
-0.05970882996916771,
-0.009124767035245895,
-0.020976262167096138,
-0.04336707293987274,
0.02600163035094738,
-0.0673399418592453,
-0.026783354580402374,
-0.024214833974838257,
-0.04493052139878273,
0.07262589037418365,
0.023395884782075882,
-0.007291438058018684,
0.057251982390880585,
-0.057326432317495346,
-0.00012018135021207854,
0.032534610480070114,
-0.014852757565677166,
0.06026720255613327,
-0.02592718042433262,
-0.04150582477450371,
0.034842558205127716,
-0.04385099560022354,
0.03635016828775406,
0.06365467607975006,
-0.07750235497951508,
0.06871726363897324,
0.026020243763923645,
0.09045664221048355,
-0.012330766767263412,
0.049062490463256836,
-0.026969479396939278,
0.0458611436188221,
0.01046021282672882,
-0.03763442859053612,
-0.0243265088647604,
0.028644602745771408,
0.014210626482963562,
-0.012042272835969925,
-0.01972922682762146,
0.004487933591008186,
0.0011981782736256719,
0.017942428588867188,
0.01861247792840004,
-0.023507559671998024,
-0.018621783703565598,
-0.02544325776398182,
-0.04444659501314163,
0.04638229310512543,
-0.008533821441233158,
-0.04943474009633064,
0.016955967992544174,
0.06860559433698654,
0.01924530230462551,
0.0128612220287323,
0.021497411653399467,
-0.031008386984467506,
-0.006593469996005297,
0.06488309800624847,
-0.028104841709136963,
-0.030096376314759254,
-0.03167843818664551,
-0.02631804347038269,
0.00880835484713316,
0.05025368928909302,
-0.01997118815779686,
-0.06864281743764877,
-0.008398880250751972,
-0.05464623495936394,
-0.033241886645555496,
-0.017104867845773697,
-0.0073007442988455296,
-0.026969479396939278,
-0.022502485662698746,
0.011130261234939098,
-0.031808722764253616,
-0.03823002800345421,
-0.061086151748895645,
-0.014275770634412766,
-0.03990515321493149,
0.015141250565648079,
-0.000748570600990206,
0.04835521802306175,
-0.01937558874487877,
0.03214374929666519,
-0.0035107785370200872,
0.018463578075170517,
-0.05542795732617378,
-0.008198796771466732,
0.012507584877312183,
-0.02401009574532509,
-0.032851021736860275,
0.06022997573018074,
-0.004988144151866436,
0.017467809841036797,
0.012274929322302341,
0.002435907954350114,
0.03782055526971817,
0.04429769515991211,
-0.05312000960111618,
-0.05032813921570778,
0.03031972609460354,
-0.031045611947774887,
-0.001718164305202663,
0.00878974236547947,
0.041394151747226715,
-0.006211914587765932,
0.09425358474254608,
0.03413528576493263,
-0.10512327402830124,
0.1005818322300911,
0.030375562608242035,
0.0024242752697318792,
0.005313862580806017,
-0.011995742097496986,
-0.041915301233530045,
0.018640397116541862,
-0.04638229310512543,
0.002092740498483181,
-0.03718772903084755,
-0.03471226990222931,
-0.02436373382806778,
-0.025666605681180954,
0.006984332110732794,
0.0003233918105252087,
0.04042630270123482,
-0.049583639949560165,
-0.030933937057852745,
-0.025015169754624367,
0.011707248166203499,
0.0678238719701767,
-0.08732974529266357,
0.00021433431538753211,
0.03893730416893959,
-0.04098467528820038,
0.0008771130233071744,
0.07184416055679321,
0.002652278169989586,
-0.08308610320091248,
-0.015243618749082088,
0.06659544259309769,
-0.009939063340425491,
-0.05051426589488983,
-0.030691975727677345,
0.02160908654332161,
-0.06153285130858421,
0.0383417047560215,
0.02635526843369007,
0.07698120921850204,
0.005118431523442268,
0.022837510332465172,
-0.014862063340842724,
0.010274088010191917,
-0.06008107587695122,
-0.048578567802906036,
-0.04228755086660385,
0.013680171221494675,
0.007440337911248207,
-0.02136712521314621,
0.030282501131296158,
-0.0024731329176574945,
0.07236531376838684,
0.035252030938863754,
-0.007919609546661377,
0.02304224669933319,
-0.023116696625947952,
-0.0009079399169422686,
-0.010674255900084972,
-0.03815557807683945,
0.056619156152009964,
0.0018717172788456082,
0.03439585864543915,
0.050625938922166824,
0.07054129242897034,
0.0006031605880707502,
-0.01338237151503563,
0.006630694959312677,
0.018072715029120445,
0.01455495785921812,
-0.04861579090356827,
0.006579510867595673,
-0.014238545671105385,
-0.041915301233530045,
-0.08621299266815186,
0.02188827283680439,
-0.008538474328815937,
0.001520406804047525,
-0.033651359379291534,
-0.0014668959192931652,
-0.03793222829699516,
0.012414522469043732,
0.09514698386192322,
0.03994237631559372,
0.0018880032002925873,
-0.03134341165423393,
0.026094693690538406,
-0.044037122279405594,
0.07727900892496109,
-0.005267331376671791,
0.008175530470907688,
-0.06246347352862358,
0.031455088406801224,
-0.016686085611581802,
-0.01896611414849758,
0.035922080278396606,
0.005918767768889666,
0.01582060568034649,
0.026746129617094994,
0.006281711161136627,
-0.01453634537756443,
0.025499094277620316,
0.0023207433987408876,
-0.005295250099152327,
-0.0315481498837471,
0.010367150418460369,
-0.016639554873108864,
0.010357843711972237,
0.028923790901899338,
0.052263837307691574,
-0.05788480490446091,
-0.06417582184076309,
-0.037559978663921356,
-0.016760535538196564,
0.018035490065813065,
0.006723757367581129,
0.026429718360304832,
-0.012823997065424919,
-0.023340046405792236,
-0.032609060406684875,
0.05918768048286438,
-0.028849340975284576,
0.017477115616202354,
-0.013280002400279045,
-0.011697942391037941,
0.07054129242897034,
0.06469697505235672,
0.009259707294404507,
0.01889166422188282,
0.02108793705701828,
0.015848524868488312,
0.017988959327340126,
-0.012516891583800316,
0.04091022536158562,
-0.0421014241874218,
0.010153106413781643,
0.031734272837638855,
0.001846125116571784,
0.00725886644795537,
-0.05468345806002617,
0.006830779369920492,
0.021776597946882248,
-0.01805410347878933,
-0.07448713481426239,
-0.0000848467243486084,
0.010171718895435333,
-0.029779965057969093,
-0.08814869076013565,
-0.03067336231470108,
-0.04705234244465828,
0.000259993044892326,
-0.006193302106112242,
-0.01535529363900423,
0.02237219735980034,
-0.008654802106320858,
-0.027620917186141014,
-0.0032920818775892258,
-0.009576119482517242,
-0.02868182770907879,
-0.0007096006884239614,
-0.013633639551699162,
-0.03175288811326027,
0.057810354977846146,
0.009799469262361526,
0.062202900648117065,
-0.005123084411025047,
0.010041431523859501,
-0.008710639551281929,
0.05431120842695236,
0.02464292012155056,
0.06890339404344559,
-0.0016565105179324746,
0.015225006267428398,
0.06022997573018074,
0.004936959594488144,
-0.002072964794933796,
-0.02756507880985737,
0.023935645818710327,
-0.0006421305006369948,
-0.03011498786509037,
0.05025368928909302,
0.06923841685056686,
-0.022707222029566765,
-0.021311286836862564,
-0.05539073422551155,
-0.035289257764816284,
0.02276306040585041,
0.014992350712418556,
0.03439585864543915,
-0.009957675822079182,
0.0411335751414299,
0.002524317242205143,
0.030580300837755203,
-0.027974553406238556,
-0.004550750833004713,
0.02691364288330078,
0.00492300046607852,
-0.0799592062830925,
0.0015122637851163745,
0.021516023203730583,
0.010823155753314495,
-0.02495933324098587,
-0.00635150820016861,
0.011697942391037941,
-0.04701511934399605,
0.013531271368265152,
-0.0268764179199934,
-0.01721654087305069,
0.05088651552796364,
-0.008040590211749077,
0.028570152819156647,
0.08948878943920135,
-0.0060816272161901,
0.03715050593018532,
-0.022632772102952003,
-0.006877310574054718,
0.010143800638616085,
-0.04597282037138939,
0.001523896586149931,
-0.044111572206020355,
-0.005137044005095959,
-0.00009073582623386756,
0.021497411653399467,
-0.01690012961626053,
-0.019152238965034485,
0.03990515321493149,
-0.02743479236960411,
-0.03908620402216911,
-0.003201346145942807,
-0.021516023203730583,
0.07847020775079727,
0.02966829016804695,
0.021944111213088036,
-0.02332143485546112,
-0.004862509667873383,
-0.0018496150150895119,
-0.01270301640033722,
0.0552046075463295,
0.018556639552116394,
0.011651410721242428,
-0.0035224114544689655,
-0.10996251553297043,
0.07042961567640305,
-0.04061242565512657,
-0.028328191488981247,
0.03642461821436882,
-0.0014901615213602781,
0.0009684304823167622,
0.04831799119710922,
-0.00948305707424879,
0.0254804827272892,
-0.027509242296218872,
-0.0006874983664602041,
-0.04448382183909416,
0.009510976262390614,
-0.020901812240481377,
-0.11197266727685928,
-0.057847581803798676,
0.0003286265709903091,
0.057773131877183914,
-0.005379005800932646,
-0.0696478933095932,
-0.006998291704803705,
-0.0016053261933848262,
0.05810815468430519,
0.016239386051893234,
0.012786772102117538,
0.007980099879205227,
0.052338287234306335,
-0.002227680990472436,
0.014927207492291927,
0.057773131877183914,
0.023023635149002075,
-0.013373064808547497,
-0.011176792904734612,
-0.031417861580848694,
0.0016472042771056294,
-0.03162259981036186,
0.027136992663145065,
-0.02503378316760063,
0.014973738230764866,
-0.017626015469431877,
-0.06153285130858421,
0.07906580716371536,
0.02484765835106373,
0.03942122682929039,
0.03515896946191788,
-0.01272162888199091,
-0.01634175516664982,
-0.011018586345016956,
-0.01395935844630003,
0.04038907587528229,
-0.005662846378982067,
0.005565130617469549,
-0.09983733296394348,
-0.012833302840590477,
0.005337127950042486,
-0.025499094277620316,
-0.006816819775849581,
-0.06339409947395325,
-0.013652252033352852,
0.007082047872245312,
-0.03407944738864899,
-0.03789500519633293,
0.03960735350847244,
-0.03545676916837692,
-0.03782055526971817,
-0.014927207492291927,
-0.08829759061336517,
0.012823997065424919,
0.03115728683769703,
-0.05133321136236191,
0.0486530177295208,
0.07310981303453445,
0.021590473130345345,
-0.02181382291018963,
0.005513946525752544,
-0.10125187784433365,
-0.011111648753285408,
-0.08435174822807312,
0.023954259231686592,
-0.014043114148080349,
-0.009743631817400455,
0.013512658886611462,
-0.07794905453920364,
-0.06544147431850433,
0.016993192955851555,
0.02648555487394333,
0.04824354127049446,
-0.020697075873613358,
-0.0338560976088047,
0.002701135817915201,
0.06242625042796135,
-0.01469455100595951,
0.023935645818710327,
-0.026504168286919594,
-0.01824953407049179,
0.04176640138030052,
0.011818923056125641,
0.02164631150662899,
-0.09336018562316895,
-0.06090002506971359,
0.0005336546455509961,
-0.04414879530668259,
0.01624869368970394,
0.03307437151670456,
-0.00811038725078106,
0.0696478933095932,
0.03594069555401802,
-0.015271537937223911,
0.0023777440655976534,
0.02332143485546112,
-0.028253741562366486,
0.03469365835189819,
-0.02077152580022812,
0.020417887717485428,
0.046754542738199234,
0.011558348312973976,
0.037001606076955795,
-0.028774891048669815,
-0.027453403919935226,
-0.019468652084469795,
0.007561319041997194,
-0.03893730416893959,
0.02624359354376793,
0.009273666888475418,
0.0753433108329773,
-0.06629764288663864,
-0.035326480865478516,
0.01824953407049179,
-0.017467809841036797,
-0.063580222427845,
-0.0397934764623642,
-0.020510951057076454,
0.05766145512461662,
-0.010906911455094814,
0.029221590608358383,
-0.0013249757466837764,
-0.05527905747294426,
0.060974474996328354,
0.00872459914535284,
-0.03491700813174248,
0.001207484514452517,
0.0032083257101476192,
0.014889982528984547,
-0.034600596874952316,
-0.04050075262784958,
0.06711659580469131,
-0.05985772982239723,
-0.02624359354376793,
0.0023056205827742815,
0.0224466472864151,
0.04589837044477463,
-0.013410289771854877,
0.017979653552174568,
0.028067616745829582,
-0.01617424376308918,
0.03942122682929039,
-0.042994823306798935,
0.027490628883242607,
0.04396267235279083,
0.015885749831795692,
0.00996698159724474,
0.0011661880416795611,
0.019003339111804962,
0.0006938964361324906,
0.014433976262807846,
-0.009994900785386562,
0.06372912228107452,
-0.00027947797207161784,
0.04452104493975639,
-0.0013587108114734292,
-0.0031338760163635015,
0.02049233764410019,
0.05029091611504555,
-0.010571887716650963,
-0.02503378316760063,
0.011195405386388302,
-0.014936513267457485,
0.01296359021216631,
0.02680196799337864,
-0.017123479396104813,
-0.02196272276341915,
0.0476851686835289,
0.017551565542817116,
-0.029724126681685448,
-0.013075265102088451,
0.031213125213980675,
0.00994836911559105,
-0.015960199758410454,
-0.0016925721429288387,
0.0208087507635355,
0.000694478047080338,
-0.016285918653011322,
0.01702111028134823,
-0.02603885531425476,
0.027862878516316414,
0.05747533217072487,
0.020380662754178047,
0.011697942391037941,
-0.08316054940223694,
-0.0509609654545784,
-0.014871370047330856,
0.03450753167271614,
0.01056258101016283,
-0.09894393384456635,
0.02240942232310772,
0.007961487397551537,
0.0336141362786293,
0.04269702360033989,
0.010450906120240688,
-0.024791819974780083,
-0.03210652247071266,
0.029091302305459976,
-0.008975867182016373,
-0.0008433779003098607,
0.028644602745771408,
0.019505877047777176,
0.019710613414645195,
-0.03294408693909645,
0.03415389731526375,
0.009622651152312756,
-0.003701556473970413,
0.05412508547306061,
-0.010208943858742714,
0.02607608027756214,
-0.0076823001727461815,
-0.021739372983574867,
0.01793312281370163,
-0.030226662755012512,
-0.02540603280067444,
-0.04165472462773323,
0.027844266965985298,
0.008156917989253998,
-0.007207681890577078,
-0.033130209892988205,
0.06700491905212402,
-0.06123505160212517,
-0.030170826241374016,
0.03266489878296852,
0.03901175409555435,
-0.011632798239588737,
0.027136992663145065,
0.009976288303732872,
-0.03815557807683945,
-0.036722417920827866,
-0.021422961726784706,
-0.02387980930507183,
0.03454475849866867,
-0.05821983143687248,
0.008254634216427803,
-0.017151398584246635,
0.06123505160212517,
-0.0075287469662725925,
-0.008338389918208122,
-0.10668671876192093,
0.025889955461025238,
0.016397593542933464,
-0.03908620402216911,
0.0005164962494745851,
0.029649676755070686,
0.01784936524927616,
0.02551770769059658,
-0.02938910201191902,
-0.0014436303172260523,
0.058443181216716766,
0.009292279370129108,
-0.013307921588420868,
-0.007989405654370785,
-0.03789500519633293,
0.026857804507017136,
0.025145458057522774,
-0.007058782037347555,
0.028384028002619743,
-0.02700670436024666,
-0.028495702892541885,
-0.006844738498330116,
0.04452104493975639,
-0.010199638083577156,
-0.03279518708586693,
0.018910277634859085,
-0.04184085130691528,
-0.0196547769010067,
0.003957477863878012,
0.010208943858742714,
0.02544325776398182,
0.04184085130691528,
-0.018444964662194252,
0.005160309374332428,
0.051705460995435715,
0.032646287232637405,
-0.01824953407049179,
-0.014182708226144314,
-0.001842635334469378,
0.01235868502408266,
-0.00004518615241977386,
-0.01515986304730177,
0.01881721429526806,
0.0444093719124794,
-0.023898420855402946,
0.03465643152594566,
-0.00037399446591734886,
-0.019338363781571388,
0.0421014241874218,
-0.08904208987951279,
0.03339078649878502,
-0.014750388450920582,
-0.031138675287365913,
0.05304555967450142,
-0.02484765835106373,
-0.021348511800169945,
-0.04366487264633179,
0.016025343909859657,
0.009576119482517242,
0.022465260699391365,
-0.023675071075558662,
0.05915045365691185,
-0.07921470701694489,
-0.03685270622372627,
-0.013373064808547497,
0.026057468727231026,
0.004755488131195307,
0.03679686784744263,
-0.04943474009633064,
-0.01646273583173752,
0.06238902360200882,
0.03601514548063278,
0.01729099079966545,
-0.04206420108675957,
0.0072449068538844585,
0.030263887718319893,
-0.0030128948856145144,
0.034730881452560425,
0.09187118709087372,
0.052896659821271896,
-0.030971162021160126,
0.013950051739811897,
-0.04526554420590401,
-0.0075147878378629684,
0.04176640138030052,
-0.056730832904577255,
0.017523648217320442,
-0.02004563808441162,
0.05133321136236191,
0.02551770769059658,
0.0018868398619815707,
0.02715560421347618,
0.04779684171080589,
-0.021274061873555183,
-0.010516050271689892,
-0.05687973275780678,
-0.03990515321493149,
0.005579090211540461,
0.07143469154834747,
-0.01232146006077528,
0.014731775969266891,
-0.011474592611193657,
-0.01729099079966545,
-0.006235179957002401,
0.014508426189422607,
-0.007054129149764776,
0.03674102947115898,
-0.007389153819531202,
-0.032646287232637405,
-0.021664923056960106,
-0.048392441123723984,
0.038639504462480545,
-0.0024033361114561558,
0.004366952460259199,
0.032329872250556946,
0.019952576607465744,
0.04422324523329735,
0.03770887851715088,
0.012507584877312183,
-0.09328573942184448,
0.056172456592321396,
0.051221538335084915,
-0.0499931164085865,
0.01690012961626053,
0.030729200690984726,
0.016406899318099022,
-0.08799979090690613,
-0.008198796771466732,
-0.037485528737306595,
0.010134493932127953,
0.04206420108675957,
0.046345070004463196,
0.011632798239588737,
-0.02903546579182148,
0.024233445525169373
]
|
32,264 | bqplot.marks | Bars | Bar mark.
In the case of the Bars mark, scales for 'x' and 'y' MUST be provided.
The scales of other data attributes are optional. In the case where another
data attribute than 'x' or 'y' is provided but the corresponding scale is
missing, the data attribute is ignored.
Attributes
----------
icon: string (class-level attribute)
font-awesome icon for that mark
name: string (class-level attribute)
user-friendly name of the mark
color_mode: {'auto', 'group', 'element', 'no_group'}
Specify how default colors are applied to bars.
The 'group' mode means colors are assigned per group. If the list
of colors is shorter than the number of groups, colors are reused.
The 'element' mode means colors are assigned per group element. If the list
of colors is shorter than the number of bars in a group, colors are reused.
The 'no_group' mode means colors are assigned per bar, discarding the fact
that there are groups or stacks. If the list of colors is shorter than the
total number of bars, colors are reused.
opacity_mode: {'auto', 'group', 'element', 'no_group'}
Same as the `color_mode` attribute, but for the opacity.
type: {'stacked', 'grouped'}
whether 2-dimensional bar charts should appear grouped or stacked.
colors: list of colors (default: ['steelblue'])
list of colors for the bars.
orientation: {'horizontal', 'vertical'}
Specifies whether the bar chart is drawn horizontally or vertically.
If a horizontal bar chart is drawn, the x data is drawn vertically.
padding: float (default: 0.05)
Attribute to control the spacing between the bars value is specified
as a percentage of the width of the bar
fill: Bool (default: True)
Whether to fill the bars or not
stroke: Color or None (default: None)
Stroke color for the bars
stroke_width: Float (default: 0.)
Stroke width of the bars
opacities: list of floats (default: [])
Opacities for the bars. Defaults to 1 when the list is too
short, or the element of the list is set to None.
base: float (default: 0.0)
reference value from which the bars are drawn. defaults to 0.0
align: {'center', 'left', 'right'}
alignment of bars with respect to the tick value
label_display: bool (default: False)
whether or not to display bar data labels
label_display_format: string (default: .2f)
format for displaying values.
label_font_style: dict
CSS style for the text of each cell
label_display_vertical_offset: float
vertical offset value for the label display
label_display_horizontal_offset: float
horizontal offset value for the label display
Data Attributes
x: numpy.ndarray (default: [])
abscissas of the data points (1d array)
y: numpy.ndarray (default: [])
ordinates of the values for the data points
color: numpy.ndarray or None (default: None)
color of the data points (1d array). Defaults to default_color when not
provided or when a value is NaN
Notes
-----
The fields which can be passed to the default tooltip are:
All the data attributes
index: index of the bar being hovered on
sub_index: if data is two dimensional, this is the minor index
| class Bars(Mark):
"""Bar mark.
In the case of the Bars mark, scales for 'x' and 'y' MUST be provided.
The scales of other data attributes are optional. In the case where another
data attribute than 'x' or 'y' is provided but the corresponding scale is
missing, the data attribute is ignored.
Attributes
----------
icon: string (class-level attribute)
font-awesome icon for that mark
name: string (class-level attribute)
user-friendly name of the mark
color_mode: {'auto', 'group', 'element', 'no_group'}
Specify how default colors are applied to bars.
The 'group' mode means colors are assigned per group. If the list
of colors is shorter than the number of groups, colors are reused.
The 'element' mode means colors are assigned per group element. If the list
of colors is shorter than the number of bars in a group, colors are reused.
The 'no_group' mode means colors are assigned per bar, discarding the fact
that there are groups or stacks. If the list of colors is shorter than the
total number of bars, colors are reused.
opacity_mode: {'auto', 'group', 'element', 'no_group'}
Same as the `color_mode` attribute, but for the opacity.
type: {'stacked', 'grouped'}
whether 2-dimensional bar charts should appear grouped or stacked.
colors: list of colors (default: ['steelblue'])
list of colors for the bars.
orientation: {'horizontal', 'vertical'}
Specifies whether the bar chart is drawn horizontally or vertically.
If a horizontal bar chart is drawn, the x data is drawn vertically.
padding: float (default: 0.05)
Attribute to control the spacing between the bars value is specified
as a percentage of the width of the bar
fill: Bool (default: True)
Whether to fill the bars or not
stroke: Color or None (default: None)
Stroke color for the bars
stroke_width: Float (default: 0.)
Stroke width of the bars
opacities: list of floats (default: [])
Opacities for the bars. Defaults to 1 when the list is too
short, or the element of the list is set to None.
base: float (default: 0.0)
reference value from which the bars are drawn. defaults to 0.0
align: {'center', 'left', 'right'}
alignment of bars with respect to the tick value
label_display: bool (default: False)
whether or not to display bar data labels
label_display_format: string (default: .2f)
format for displaying values.
label_font_style: dict
CSS style for the text of each cell
label_display_vertical_offset: float
vertical offset value for the label display
label_display_horizontal_offset: float
horizontal offset value for the label display
Data Attributes
x: numpy.ndarray (default: [])
abscissas of the data points (1d array)
y: numpy.ndarray (default: [])
ordinates of the values for the data points
color: numpy.ndarray or None (default: None)
color of the data points (1d array). Defaults to default_color when not
provided or when a value is NaN
Notes
-----
The fields which can be passed to the default tooltip are:
All the data attributes
index: index of the bar being hovered on
sub_index: if data is two dimensional, this is the minor index
"""
# Mark decoration
icon = 'fa-bar-chart'
name = 'Bar chart'
# Scaled attributes
x = Array([]).tag(sync=True, scaled=True, rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
y = Array([]).tag(sync=True, scaled=True, rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_dimension_bounds(1, 2), array_supported_kinds())
color = Array(None, allow_none=True)\
.tag(sync=True, scaled=True, rtype='Color',
atype='bqplot.ColorAxis', **array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
# Bar text labels attributes -- add default values.
# Add bool for displaying a label or not. Add d3 formatting in docstring
label_display = Bool(default_value=False).tag(sync=True)
label_display_format = Unicode(default_value=".2f",
allow_none=False).tag(sync=True)
label_font_style = Dict().tag(sync=True)
label_display_vertical_offset = Float(default_value=0.0,
allow_none=False).tag(sync=True)
label_display_horizontal_offset = Float(default_value=0.0,
allow_none=False).tag(sync=True)
# Other attributes
scales_metadata = Dict({
'x': {'orientation': 'horizontal', 'dimension': 'x'},
'y': {'orientation': 'vertical', 'dimension': 'y'},
'color': {'dimension': 'color'}
}).tag(sync=True)
color_mode = Enum(['auto', 'group', 'element', 'no_group'], default_value='auto')\
.tag(sync=True)
opacity_mode = Enum(['auto', 'group', 'element', 'no_group'], default_value='auto')\
.tag(sync=True)
type = Enum(['stacked', 'grouped'], default_value='stacked')\
.tag(sync=True, display_name='Type')
colors = List(trait=Color(default_value=None,
allow_none=True),
default_value=['steelblue'])\
.tag(sync=True, display_name='Colors')
padding = Float(0.05).tag(sync=True)
fill = Bool(True).tag(sync=True)
stroke = Color(None, allow_none=True).tag(sync=True)
stroke_width = Float(1.).tag(sync=True, display_name='Stroke width')
base = Float().tag(sync=True)
opacities = List(trait=Float(1.0, min=0, max=1, allow_none=True))\
.tag(sync=True, display_name='Opacities')
align = Enum(['center', 'left', 'right'], default_value='center')\
.tag(sync=True)
orientation = Enum(['vertical', 'horizontal'], default_value='vertical')\
.tag(sync=True)
@validate('orientation')
def _validate_orientation(self, proposal):
value = proposal['value']
x_orient = "horizontal" if value == "vertical" else "vertical"
self.scales_metadata = {'x': {'orientation': x_orient,
'dimension': 'x'},
'y': {'orientation': value, 'dimension': 'y'}}
return value
_view_name = Unicode('Bars').tag(sync=True)
_model_name = Unicode('BarsModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.04219086095690727,
-0.02820737473666668,
-0.0574965663254261,
-0.0032830138225108385,
0.018941814079880714,
-0.028307544067502022,
-0.05929959565401077,
0.011399145238101482,
-0.022517818957567215,
-0.006520952098071575,
0.02175654098391533,
0.03588026016950607,
0.04227099567651749,
-0.006676212884485722,
-0.01680823042988777,
-0.001046758028678596,
0.020955195650458336,
0.009200452826917171,
0.07276220619678497,
0.0360405296087265,
0.004890714306384325,
-0.04279186949133873,
-0.0169684998691082,
0.0072872391901910305,
0.034017134457826614,
-0.01909206621348858,
0.008168719708919525,
-0.028527913615107536,
-0.013312358409166336,
0.029549630358815193,
-0.02638431265950203,
-0.03886527568101883,
-0.04239119589328766,
0.013422543182969093,
0.024881789460778236,
-0.059139326214790344,
-0.020274050533771515,
0.016657978296279907,
-0.01828070357441902,
0.008103610016405582,
0.002406541956588626,
-0.017499390989542007,
0.06298578530550003,
-0.053810376673936844,
0.0586184523999691,
0.027185659855604172,
-0.015435924753546715,
0.014003518968820572,
-0.025062091648578644,
-0.03720248118042946,
0.0723615363240242,
-0.0319737009704113,
0.010818169452250004,
0.07252180576324463,
-0.026985323056578636,
0.0726420059800148,
0.024340881034731865,
0.07552684843540192,
0.02494189143180847,
0.02327909879386425,
0.030671514570713043,
0.06851506978273392,
-0.004059317521750927,
-0.06991742551326752,
-0.035579755902290344,
0.014484327286481857,
0.0349186472594738,
-0.036120664328336716,
-0.0244009830057621,
-0.006430800538510084,
0.01473474781960249,
0.025022026151418686,
0.01874147728085518,
0.015486009418964386,
-0.029990369454026222,
-0.04040786623954773,
-0.030050471425056458,
0.014764797873795033,
0.04000719264149666,
0.004565167240798473,
0.0095009570941329,
0.017779862508177757,
0.0499238483607769,
-0.04900230094790459,
0.013352425768971443,
-0.03101208619773388,
0.004848142620176077,
0.0675935223698616,
-0.012100323103368282,
0.0022863398771733046,
-0.03217403590679169,
0.017399221658706665,
0.0367417074739933,
0.0530090294778347,
-0.0586184523999691,
-0.045917119830846786,
0.005384042859077454,
-0.05709589272737503,
0.0009021401638165116,
0.01858120784163475,
-0.03656140714883804,
-0.0017667172942310572,
-0.015926750376820564,
0.007347340229898691,
-0.06951675564050674,
0.033997099846601486,
-0.05529286712408066,
0.023499468341469765,
-0.028868485242128372,
0.002954962896183133,
-0.013142072595655918,
-0.018120434135198593,
0.007487575523555279,
-0.012881634756922722,
-0.0014311536215245724,
-0.007207104470580816,
-0.054491519927978516,
-0.03229423984885216,
0.03798379376530647,
-0.028928587213158607,
-0.02974996529519558,
0.018481040373444557,
0.027426062151789665,
-0.0050760251469910145,
0.006646162364631891,
0.021916810423135757,
0.007237154990434647,
0.04134944826364517,
-0.04379355162382126,
0.0356198251247406,
0.004229603800922632,
-0.024040376767516136,
-0.0558137409389019,
0.000378448108676821,
0.07773055136203766,
-0.019552839919924736,
0.056054145097732544,
0.0325346440076828,
-0.050003983080387115,
0.06362686306238174,
0.07989418506622314,
-0.014083653688430786,
0.017789877951145172,
-0.036260902881622314,
-0.06190396845340729,
-0.0007337323040701449,
0.019412603229284286,
-0.03221410512924194,
-0.034297604113817215,
-0.04054810106754303,
-0.04175012186169624,
0.02187674306333065,
0.024461083114147186,
-0.0001939194480655715,
0.07268207520246506,
-0.030751647427678108,
-0.04443462938070297,
-0.015556126832962036,
0.057857174426317215,
0.06098242104053497,
-0.0361807681620121,
-0.019192233681678772,
0.03938614949584007,
-0.030070504173636436,
-0.014624562114477158,
0.054371319711208344,
-0.010407479479908943,
-0.009410806000232697,
-0.010157058946788311,
0.03147285804152489,
-0.013051921501755714,
-0.02778666839003563,
-0.053249433636665344,
0.0181605014950037,
-0.05260835587978363,
0.05986053869128227,
-0.017639625817537308,
0.030911916866898537,
0.022257382050156593,
-0.010487614199519157,
-0.03257470950484276,
-0.021956877782940865,
-0.023599635809659958,
-0.013091988861560822,
-0.019152166321873665,
-0.0168983805924654,
0.04315247759222984,
-0.0015413387445732951,
0.044955503195524216,
0.024601317942142487,
0.03658143803477287,
-0.014844932593405247,
0.004600226413458586,
0.0221572145819664,
0.013562778942286968,
-0.035259220749139786,
0.03662150725722313,
-0.041469648480415344,
0.043713416904211044,
-0.038925375789403915,
0.05088546499609947,
0.004129435401409864,
0.04415415972471237,
0.010187109932303429,
0.003215400269255042,
0.011459246277809143,
0.025863438844680786,
0.01108862366527319,
-0.06242484599351883,
-0.03638110309839249,
-0.05092553049325943,
-0.015025235712528229,
-0.05200734734535217,
-0.014614545740187168,
0.028668148443102837,
-0.04279186949133873,
0.03776342421770096,
-0.004685369320213795,
0.020955195650458336,
0.014324057847261429,
0.102652408182621,
0.013552762567996979,
-0.030491210520267487,
0.04755987972021103,
-0.009821495972573757,
-0.008038501255214214,
0.061383094638586044,
0.007963375188410282,
0.03950635343790054,
-0.028848452493548393,
-0.02042430266737938,
-0.05172687768936157,
0.022898457944393158,
-0.001782994600944221,
-0.053209368139505386,
-0.018060332164168358,
0.06294571608304977,
0.005614429712295532,
-0.03930601477622986,
-0.004800562746822834,
0.02042430266737938,
0.0019632973708212376,
-0.021135497838258743,
0.025302495807409286,
-0.015235588885843754,
-0.023900141939520836,
0.039646588265895844,
0.0356198251247406,
-0.05481205880641937,
-0.07781068235635757,
-0.01473474781960249,
0.0023802476935088634,
0.008604451082646847,
0.007031810004264116,
0.06354673206806183,
-0.046478062868118286,
-0.007387407589703798,
-0.05136626958847046,
0.05565347149968147,
-0.04395382106304169,
-0.0260838083922863,
-0.08494266122579575,
-0.007943341508507729,
0.06719285249710083,
0.043553147464990616,
0.017729777842760086,
0.02792690321803093,
0.008293929509818554,
-0.025302495807409286,
-0.002654458163306117,
0.0373026505112648,
0.024621352553367615,
-0.028808385133743286,
-0.011539380997419357,
-0.02860804833471775,
0.027966970577836037,
0.05389051139354706,
-0.049322839826345444,
0.00859944336116314,
-0.00504347076639533,
-0.04547638073563576,
-0.0734834149479866,
0.012681298889219761,
0.00016026917728595436,
0.0510457344353199,
-0.0429120734333992,
-0.014364125207066536,
-0.0726420059800148,
0.006751338951289654,
0.017299054190516472,
-0.02862808108329773,
-0.021636338904500008,
-0.050164252519607544,
-0.009390772320330143,
0.024801654741168022,
-0.023078761994838715,
0.0396866537630558,
0.00891497265547514,
-0.04191039130091667,
-0.04138951376080513,
0.031192388385534286,
-0.033335987478494644,
0.11956080794334412,
0.020654689520597458,
-0.013492661528289318,
0.02636427991092205,
0.11250896006822586,
-0.0197030920535326,
0.013672963716089725,
0.01031732838600874,
0.032494574785232544,
0.09672244638204575,
0.01858120784163475,
0.03521915152668953,
-0.055893875658512115,
-0.01593676581978798,
0.0040493011474609375,
-0.015275656245648861,
0.02482168935239315,
0.0476800799369812,
-0.024220678955316544,
-0.07556691765785217,
-0.06615110486745834,
-0.039486318826675415,
0.044554829597473145,
0.04363328218460083,
0.002240012167021632,
0.0037738382816314697,
0.027325894683599472,
0.01867135986685753,
0.002832256956025958,
-0.02900872193276882,
-0.013292324729263783,
0.012651247903704643,
0.012050238437950611,
-0.03666157275438309,
-0.0373026505112648,
0.0190019141882658,
0.01184990257024765,
-0.043713416904211044,
0.004577688407152891,
-0.011719683185219765,
-0.012881634756922722,
0.03221410512924194,
-0.004682864993810654,
-0.018120434135198593,
0.03423750400543213,
0.0011513086501508951,
0.0003994208527728915,
0.12036215513944626,
0.0269252210855484,
0.04780028387904167,
0.0018193055875599384,
0.016838280484080315,
0.01079813577234745,
-0.09519989043474197,
0.01940258778631687,
-0.017709743231534958,
-0.025763269513845444,
0.026424380019307137,
0.011829868890345097,
-0.033195752650499344,
-0.03453800827264786,
0.06294571608304977,
0.01487498264759779,
-0.03085181675851345,
-0.02874828316271305,
-0.002990021836012602,
0.030671514570713043,
-0.020414287224411964,
0.07172045856714249,
-0.018821612000465393,
-0.013001836836338043,
-0.004101889207959175,
-0.00831897184252739,
0.05164674296975136,
0.005679538939148188,
-0.0207548588514328,
0.03439777344465256,
-0.06859520822763443,
0.021976910531520844,
-0.013362443074584007,
-0.05036458745598793,
0.046077389270067215,
0.01898188143968582,
-0.012500995770096779,
0.003195366822183132,
-0.059259526431560516,
-0.020324135199189186,
-0.04784034937620163,
0.044675033539533615,
-0.06719285249710083,
0.012180457822978497,
0.01522557158023119,
-0.10032850503921509,
-0.034037165343761444,
-0.007818130776286125,
0.01802026480436325,
0.02764643356204033,
0.010928354226052761,
0.00884485524147749,
-0.07196085900068283,
0.04399389028549194,
-0.0221572145819664,
0.021255699917674065,
-0.013001836836338043,
0.04615752398967743,
0.03840450197458267,
-0.0190019141882658,
0.07368375360965729,
0.0295896977186203,
-0.015906715765595436,
-0.014664629474282265,
0.007011776324361563,
-0.010152050293982029,
-0.03776342421770096,
0.02341933362185955,
-0.04920263588428497,
0.002377743599936366,
-0.04976357892155647,
-0.035559725016355515,
0.05361003801226616,
0.051566608250141144,
0.03586022928357124,
0.02989020198583603,
-0.04162991791963577,
-0.02540266513824463,
0.019663024693727493,
0.012430878356099129,
0.00836905650794506,
0.0417901873588562,
-0.03283514827489853,
-0.04463496431708336,
-0.042591534554958344,
0.00278968526981771,
-0.026905188336968422,
-0.02103533037006855,
-0.03511898219585419,
0.023920174688100815,
0.020314117893576622,
-0.0004908243427053094,
-0.004174511414021254,
0.06350666284561157,
-0.01905199885368347,
-0.07476557046175003,
-0.00926556158810854,
-0.07672886550426483,
0.02720569260418415,
0.00784317310899496,
-0.054211050271987915,
-0.0059900605119764805,
0.06959688663482666,
0.017870012670755386,
0.019412603229284286,
-0.007442499976605177,
-0.04331274330615997,
0.013132055290043354,
-0.0785318985581398,
0.019713109359145164,
0.003638611175119877,
0.021135497838258743,
0.006225456018000841,
-0.057296231389045715,
-0.02269812300801277,
0.007182062603533268,
0.041870322078466415,
0.03431763872504234,
-0.02496192418038845,
-0.027586331591010094,
0.0070818942040205,
0.011639549396932125,
-0.019252335652709007,
-0.006365691311657429,
-0.0017241457244381309,
-0.029529595747590065,
0.018781544640660286,
0.03930601477622986,
-0.010768085718154907,
-0.08590427786111832,
-0.014173805713653564,
0.0631059855222702,
-0.03271494433283806,
-0.015996867790818214,
0.04110904410481453,
0.0041544777341187,
0.04070837050676346,
0.0479605495929718,
-0.03523918613791466,
0.027706533670425415,
0.02119559794664383,
-0.09023154526948929,
-0.01668802835047245,
-0.015175487846136093,
0.047760214656591415,
-0.048721831291913986,
0.03251460939645767,
0.07380395382642746,
-0.040748439729213715,
-0.0244009830057621,
-0.07632819563150406,
0.0382842980325222,
-0.005629454739391804,
-0.0034733335487544537,
-0.011349061504006386,
0.017258986830711365,
-0.061503294855356216,
-0.015035252086818218,
0.012230541557073593,
-0.0173190888017416,
-0.06991742551326752,
-0.06979722529649734,
-0.028728250414133072,
0.0608622208237648,
0.009190435521304607,
-0.028127240017056465,
-0.009951714426279068,
-0.03283514827489853,
0.004530108533799648,
0.017369171604514122,
-0.013793165795505047,
-0.0032379382755607367,
0.0026870130095630884,
0.0038815191946923733,
-0.056655153632164,
-0.015295689925551414,
0.05024438723921776,
0.0030250807758420706,
-0.02414054423570633,
0.014334074221551418,
-0.0016364986076951027,
-0.01773979514837265,
-0.03087184950709343,
0.020514454692602158,
0.013903351500630379,
-0.010006806813180447,
0.041589852422475815,
0.004001720808446407,
0.00024149935052264482,
0.0018844149308279157,
0.018991896882653236,
0.04014742746949196,
-0.012230541557073593,
0.03465820848941803,
-0.023479433730244637,
0.023779939860105515,
0.03251460939645767,
0.02161630615592003,
-0.026704851537942886,
0.07232146710157394,
0.014364125207066536,
-0.010948387905955315,
0.035139016807079315,
0.013672963716089725,
-0.02077489160001278,
0.04451476410031319,
0.003375669475644827,
-0.020464370027184486,
0.013963451609015465,
0.042311061173677444,
0.014724730513989925,
0.010677933692932129,
0.03818413242697716,
0.00909026712179184,
-0.044955503195524216,
0.0067613557912409306,
0.04247133061289787,
-0.0215962715446949,
0.020534487441182137,
0.00021990058303344995,
-0.040107361972332,
0.013152088969945908,
-0.0119200199842453,
0.012110339477658272,
-0.01009695790708065,
0.01874147728085518,
0.006335640791803598,
0.002579332096502185,
-0.0204042699187994,
-0.07456523180007935,
-0.05192721262574196,
-0.020203933119773865,
0.07452517002820969,
0.019482722505927086,
-0.056615088135004044,
0.006330632604658604,
0.0440339557826519,
-0.034017134457826614,
0.0465581975877285,
0.03886527568101883,
-0.009320653975009918,
-0.0245412178337574,
0.0098515460267663,
-0.019292403012514114,
-0.023319166153669357,
0.022517818957567215,
0.023499468341469765,
0.004327267874032259,
-0.07035817205905914,
-0.006415775511413813,
-0.0032855181489139795,
0.06498914957046509,
0.04042790085077286,
-0.01898188143968582,
0.023679770529270172,
0.024581285193562508,
0.017279021441936493,
0.05537300184369087,
0.00017795512394513935,
-0.019893411546945572,
-0.0378635935485363,
-0.02049442194402218,
0.0060251192189753056,
-0.02357960306107998,
-0.025282463058829308,
0.020444337278604507,
-0.08041506260633469,
-0.041990526020526886,
0.010948387905955315,
-0.0011700901668518782,
0.033035483211278915,
-0.00007860858750063926,
-0.0012276869965717196,
-0.02026403322815895,
0.03910567983984947,
-0.013242240995168686,
-0.034718312323093414,
0.006981725804507732,
-0.0445948988199234,
-0.0003953514969907701,
-0.0586184523999691,
0.06018107756972313,
-0.014995184727013111,
0.0490824356675148,
-0.08333997428417206,
0.0015125403879210353,
0.020694756880402565,
0.013823216781020164,
0.007187070790678263,
0.021496104076504707,
0.03181343153119087,
0.007106936536729336,
-0.05377030745148659,
0.012250575236976147,
0.07925310730934143,
0.0020634657703340054,
-0.036841876804828644,
-0.03868497163057327,
-0.0008307702955789864,
0.018481040373444557,
0.008929998613893986,
0.004712915513664484,
-0.025482799857854843,
-0.040027227252721786,
-0.018621275201439857,
0.012500995770096779,
0.06771373003721237,
0.019963528960943222,
-0.03511898219585419,
-0.038484636694192886,
-0.0030000386759638786,
-0.0580575093626976,
-0.0025943573564291,
-0.015025235712528229,
0.09936688840389252,
0.04471509903669357,
-0.0349186472594738,
-0.003305551828816533,
0.024200646206736565,
0.029489528387784958,
-0.005469185765832663,
0.03167319670319557,
0.018310753628611565,
-0.027526231482625008,
-0.04615752398967743,
-0.04227099567651749,
0.0004617129743564874,
0.044835302978754044,
0.047199271619319916,
0.02750619687139988,
-0.041309379041194916,
0.024040376767516136,
0.017980197444558144,
-0.028728250414133072,
0.053209368139505386,
0.05036458745598793,
0.03886527568101883,
0.008118635043501854,
-0.04239119589328766,
-0.01178980153053999,
-0.008303946815431118,
0.030270840972661972,
-0.028167307376861572,
0.03339609131217003,
-0.013773132115602493,
-0.016247287392616272,
-0.027446096763014793,
-0.05741643160581589,
-0.02201697789132595,
0.04435449466109276,
-0.030811749398708344,
0.03059137985110283,
-0.04379355162382126,
-0.01717885211110115,
0.05601407587528229,
0.02231748215854168,
0.0214560367166996,
-0.06074201688170433,
-0.02187674306333065,
0.001858120784163475,
-0.05068512633442879,
0.00979144498705864,
0.0810561329126358,
-0.0029724924825131893,
-0.018541140481829643,
-0.00789826549589634,
-0.0471191368997097,
-0.008404115214943886,
0.00143866625148803,
-0.05024438723921776,
0.00802848394960165,
-0.02287842519581318,
0.06414774060249329,
-0.022758223116397858,
0.019132133573293686,
0.009320653975009918,
0.03311561793088913,
0.03125248849391937,
-0.009556049481034279,
-0.04078850522637367,
-0.054491519927978516,
0.02217724733054638,
0.04699893668293953,
0.0122706089168787,
-0.025482799857854843,
-0.034698277711868286,
-0.019432637840509415,
0.009596116840839386,
-0.0047780247405171394,
0.03137269243597984,
0.02175654098391533,
0.0022988610435277224,
-0.05024438723921776,
-0.08598441630601883,
-0.021496104076504707,
0.005208748392760754,
0.005769690498709679,
0.012500995770096779,
0.06991742551326752,
-0.0007819383172318339,
0.02341933362185955,
0.048761896789073944,
-0.0007450012490153313,
-0.06382720172405243,
0.06182383373379707,
0.041189178824424744,
-0.03029087372124195,
0.06414774060249329,
-0.0025242394767701626,
0.033856865018606186,
-0.051807012408971786,
-0.00421207444742322,
-0.03501881659030914,
0.0032830138225108385,
-0.024881789460778236,
0.08149687945842743,
0.04780028387904167,
-0.03257470950484276,
0.05517266318202019
]
|
32,269 | bqplot.marks | __init__ | null | def __init__(self, **kwargs):
super(Mark, self).__init__(**kwargs)
self._hover_handlers = CallbackDispatcher()
self._click_handlers = CallbackDispatcher()
self._legend_click_handlers = CallbackDispatcher()
self._legend_hover_handlers = CallbackDispatcher()
self._element_click_handlers = CallbackDispatcher()
self._bg_click_handlers = CallbackDispatcher()
self._name_to_handler = {
'hover': self._hover_handlers,
'click': self._click_handlers,
'legend_click': self._legend_click_handlers,
'legend_hover': self._legend_hover_handlers,
'element_click': self._element_click_handlers,
'background_click': self._bg_click_handlers
}
self.on_msg(self._handle_custom_msgs)
| (self, **kwargs) | [
-0.028457041829824448,
-0.026045123115181923,
0.027989057824015617,
0.041542600840330124,
-0.043522533029317856,
0.0135715426877141,
-0.0323089137673378,
0.08574911206960678,
0.024137187749147415,
0.030400976538658142,
0.01754041016101837,
0.08308520168066025,
0.030166983604431152,
-0.013490545563399792,
-0.028493041172623634,
0.009404683485627174,
-0.0032038921490311623,
0.004013864789158106,
-0.03274089843034744,
-0.04147060215473175,
-0.008311220444738865,
0.005525813903659582,
0.018503377214074135,
-0.001290331594645977,
0.025703134015202522,
0.10259654372930527,
-0.06450983136892319,
-0.001957433996722102,
0.03511681780219078,
0.005107328295707703,
-0.04568246379494667,
-0.011672606691718102,
-0.01721641980111599,
0.010970630683004856,
0.009584677405655384,
-0.044710494577884674,
-0.03841070830821991,
0.010943631641566753,
-0.03558480367064476,
0.013238553889095783,
0.04971432685852051,
-0.0022454243153333664,
0.040138646960258484,
0.0006637276383116841,
0.02642310969531536,
0.04334254190325737,
0.018521375954151154,
0.03628677874803543,
0.017846399918198586,
-0.06281788647174835,
-0.07016164064407349,
0.008122226223349571,
0.009139192290604115,
0.024173187091946602,
-0.061629924923181534,
0.02960900403559208,
0.07037763297557831,
0.06738973408937454,
-0.007996230386197567,
0.03526081144809723,
-0.017459413036704063,
0.08085327595472336,
0.040714628994464874,
-0.008891700766980648,
-0.03419885039329529,
-0.04546646773815155,
0.041758593171834946,
-0.027215084061026573,
-0.031552936881780624,
0.04355853423476219,
0.08639708906412125,
-0.013319551944732666,
-0.025181151926517487,
0.028097053989768028,
0.04100262001156807,
-0.008383218199014664,
-0.04859836399555206,
-0.01426452025771141,
0.02654910646378994,
0.07883734256029129,
0.026477107778191566,
0.008531712926924229,
-0.0029541505500674248,
-0.00046235942863859236,
0.020987292751669884,
-0.059505995362997055,
0.020231319591403008,
0.03126494586467743,
0.014651507139205933,
-0.012707572430372238,
-0.06605777889490128,
-0.0002639442391227931,
0.004076862707734108,
-0.03468483313918114,
-0.06663375347852707,
-0.02865503542125225,
0.0010214656358584762,
-0.027233082801103592,
0.032470908015966415,
0.07703740894794464,
-0.01092563197016716,
-0.007451748941093683,
0.0009016571566462517,
-0.04017464816570282,
-0.02735907956957817,
-0.005260322708636522,
-0.006934266537427902,
-0.022841231897473335,
-0.08337319642305374,
0.026279116049408913,
0.060189973562955856,
-0.01609145849943161,
0.0008555336971767247,
0.06663375347852707,
-0.027341078966856003,
0.024695169180631638,
-0.03686276078224182,
-0.04525047540664673,
0.01345454715192318,
-0.038482703268527985,
-0.038122717291116714,
0.012383583001792431,
-0.013175556436181068,
0.003314138390123844,
-0.039310675114393234,
-0.015263485722243786,
0.019979327917099,
0.009089694358408451,
0.06940566003322601,
-0.03216491639614105,
0.03711475059390068,
0.0017605656757950783,
0.0006744147976860404,
0.007127759978175163,
0.0007340377778746188,
-0.003536880947649479,
0.023561207577586174,
-0.030220983549952507,
-0.020015325397253036,
-0.003129644552245736,
0.020465310662984848,
0.003383886069059372,
0.026711100712418556,
-0.002459167269989848,
-0.08200524002313614,
-0.011681606993079185,
-0.011861600913107395,
-0.04525047540664673,
0.017459413036704063,
-0.01996132731437683,
0.03184092789888382,
-0.0373307429254055,
0.0173244159668684,
0.03338887542486191,
0.027989057824015617,
0.0038001220673322678,
-0.020123323425650597,
-0.016550442203879356,
0.02100529335439205,
0.07970131933689117,
0.021563274785876274,
-0.01498449593782425,
0.04121861234307289,
-0.0028596536722034216,
0.00078522355761379,
0.066561758518219,
-0.004290605429559946,
-0.06908167153596878,
0.001111462595872581,
0.04733840748667717,
0.009791670367121696,
0.007757738698273897,
0.0026886595878750086,
0.024389179423451424,
-0.02114928886294365,
0.02100529335439205,
-0.007033263333141804,
0.043522533029317856,
-0.011303619481623173,
0.0035841292701661587,
0.03605278581380844,
0.0004227045283187181,
-0.005980298854410648,
0.013427548110485077,
-0.02008732408285141,
0.002956400392577052,
0.032596901059150696,
0.003210641909390688,
-0.005116327665746212,
0.024983158335089684,
0.00719525758177042,
0.02150927670300007,
-0.020141322165727615,
0.012590575963258743,
-0.0062322900630533695,
0.010682640597224236,
0.013076559640467167,
-0.019709335640072823,
0.007924233563244343,
-0.0010524020763114095,
0.02068130299448967,
0.055726125836372375,
-0.013679539784789085,
0.0030868961475789547,
0.0336228683590889,
0.03338887542486191,
0.027647068724036217,
0.06807370483875275,
-0.02629711478948593,
-0.029393009841442108,
-0.011780603788793087,
-0.008081727661192417,
-0.022751234471797943,
0.03684476017951965,
0.03302888944745064,
-0.0373307429254055,
-0.021797265857458115,
0.05698608234524727,
-0.009049195796251297,
0.00032089545857161283,
0.05569012463092804,
0.05990198254585266,
-0.07790137827396393,
0.03146294131875038,
-0.02280523255467415,
0.04168659821152687,
0.10648441314697266,
-0.011384616605937481,
0.05875002220273018,
-0.034342844039201736,
-0.05932600423693657,
0.003383886069059372,
-0.015335483476519585,
0.012671573087573051,
-0.03605278581380844,
-0.050578296184539795,
0.04906634986400604,
-0.04172259569168091,
-0.11426015198230743,
-0.023165220394730568,
0.06634576618671417,
0.011123625561594963,
0.0072312564589083195,
-0.014435513876378536,
0.03779872879385948,
0.014147523790597916,
0.014867499470710754,
0.022841231897473335,
-0.019925329834222794,
0.014516511000692844,
-0.0009044695761986077,
-0.007519247010350227,
0.003678626148030162,
-0.0016098207561299205,
-0.018350381404161453,
-0.031174950301647186,
0.0013150806771591306,
-0.025793131440877914,
0.01681143417954445,
0.010223655961453915,
-0.013544543646275997,
0.052450235933065414,
0.014975495636463165,
0.06332186609506607,
0.048130378127098083,
0.004702341742813587,
0.013139558024704456,
-0.0014253270346671343,
-0.05155026540160179,
-0.0009669049759395421,
0.08114127069711685,
-0.025685135275125504,
0.0259731262922287,
0.021581273525953293,
-0.06317787617444992,
-0.04636643826961517,
-0.039994653314352036,
-0.03725874423980713,
-0.06951365619897842,
-0.015119491145014763,
0.06753372400999069,
-0.021941261366009712,
0.026585105806589127,
0.042946554720401764,
0.003608878469094634,
-0.04593445360660553,
0.032236915081739426,
0.04136260598897934,
-0.028349045664072037,
-0.08963698148727417,
-0.010313652455806732,
0.04179459437727928,
-0.021689269691705704,
0.015236486680805683,
0.055726125836372375,
-0.03913068398833275,
-0.027575071901082993,
0.06188191846013069,
0.00783423613756895,
0.029321013018488884,
0.00522432429715991,
-0.059505995362997055,
0.053026214241981506,
-0.002199301030486822,
0.011114626191556454,
0.012122591957449913,
0.02208525687456131,
-0.0030351479072123766,
0.034000854939222336,
-0.02420918457210064,
0.06389784812927246,
0.031534940004348755,
-0.027809062972664833,
-0.010088660754263401,
-0.05734606832265854,
0.04402651637792587,
0.029681000858545303,
-0.028511039912700653,
0.020519308745861053,
0.0542861707508564,
0.008315719664096832,
-0.057022079825401306,
-0.05475415661931038,
-0.036484770476818085,
0.04489048942923546,
-0.017720403149724007,
-0.005431317258626223,
-0.002294922713190317,
0.005134327337145805,
0.0049993316642940044,
-0.019457345828413963,
-0.0439545214176178,
0.005269322544336319,
-0.09626075625419617,
-0.07113360613584518,
-0.045754458755254745,
-0.04507048428058624,
0.02021331898868084,
-0.02172526903450489,
-0.07059362530708313,
0.01244658138602972,
0.0017965645529329777,
-0.06216990575194359,
0.05687808617949486,
-0.023237217217683792,
0.02750307321548462,
0.022877229377627373,
-0.020969294011592865,
0.019817333668470383,
0.02302122488617897,
0.01628045178949833,
-0.04543047025799751,
0.010196656920015812,
0.03263290226459503,
0.07030563056468964,
-0.02338121272623539,
-0.023471210151910782,
-0.08308520168066025,
-0.03382086008787155,
-0.011123625561594963,
0.07703740894794464,
-0.025469142943620682,
0.018332382664084435,
-0.02078930102288723,
-0.024641171097755432,
0.010601643472909927,
0.037402741611003876,
-0.014723503962159157,
0.04427850991487503,
-0.011690606363117695,
0.029878994449973106,
-0.025181151926517487,
-0.05943400040268898,
0.06479781866073608,
0.007451748941093683,
-0.028385045006871223,
0.0027989058289676905,
0.04301855340600014,
0.008999696932733059,
-0.014075526036322117,
-0.0196373388171196,
-0.02278723381459713,
0.024353180080652237,
0.008752205409109592,
0.027629069983959198,
-0.0037551235873252153,
0.002958650467917323,
0.036700762808322906,
0.04805838316679001,
0.0015175739536061883,
0.05871402472257614,
-0.029447007924318314,
-0.00754624605178833,
-0.08286920934915543,
-0.040714628994464874,
-0.012968563474714756,
0.021869264543056488,
0.03862670063972473,
-0.013238553889095783,
0.004443600308150053,
-0.018206387758255005,
-0.007240256294608116,
-0.01239258237183094,
-0.029177017509937286,
0.06202591210603714,
0.02759307064116001,
0.006952265743166208,
0.033550869673490524,
0.015416480600833893,
0.058570027351379395,
0.0051973252557218075,
-0.02140127867460251,
-0.024623170495033264,
-0.05417817458510399,
0.021941261366009712,
-0.04780638962984085,
0.012257587164640427,
-0.035404808819293976,
-0.04568246379494667,
-0.055402133613824844,
-0.07502147555351257,
0.08603710681200027,
0.06404184550046921,
-0.016802433878183365,
0.05367419496178627,
0.0000809269622550346,
-0.049498334527015686,
0.003894618945196271,
0.046690426766872406,
0.012086593545973301,
-0.04183059185743332,
0.035638801753520966,
-0.06591378152370453,
0.02021331898868084,
0.018701370805501938,
0.022031258791685104,
-0.02431718073785305,
-0.04309054836630821,
-0.01844937913119793,
-0.05039830505847931,
-0.04384652525186539,
0.009980663657188416,
0.038482703268527985,
0.018251385539770126,
-0.011024628765881062,
-0.02629711478948593,
-0.017054425552487373,
0.03266889974474907,
0.023525208234786987,
-0.04582645744085312,
0.0035548803862184286,
0.09813269972801208,
0.05180225521326065,
-0.023345213383436203,
0.05713007599115372,
-0.04593445360660553,
-0.06292588263750076,
-0.022625237703323364,
0.00558431213721633,
-0.002447917591780424,
-0.020951295271515846,
-0.05554613098502159,
-0.10886033624410629,
-0.049282342195510864,
-0.016307450830936432,
0.033316876739263535,
0.005206324625760317,
0.02888902835547924,
-0.043306540697813034,
-0.011753604747354984,
0.03479282930493355,
-0.0036021287087351084,
-0.025937126949429512,
0.008027729578316212,
-0.029105020686984062,
-0.019115356728434563,
0.011654607951641083,
-0.07926933467388153,
-0.04744640365242958,
0.015542476437985897,
0.0406426303088665,
-0.038122717291116714,
0.023525208234786987,
-0.02278723381459713,
-0.020051324740052223,
-0.007141259498894215,
0.0012093342375010252,
-0.06767772138118744,
0.02419118583202362,
0.014507511630654335,
-0.03779872879385948,
0.037294745445251465,
0.017711402848362923,
0.012554577551782131,
0.009602677077054977,
0.048922352492809296,
0.009175190702080727,
-0.005903801415115595,
-0.0048913354985415936,
-0.043162547051906586,
-0.020645305514335632,
-0.03616078197956085,
-0.011114626191556454,
-0.004981332458555698,
0.019529342651367188,
-0.027197085320949554,
-0.03175093233585358,
0.005485315341502428,
-0.01210459228605032,
0.008729706518352032,
0.016550442203879356,
-0.005926300305873156,
0.022931227460503578,
0.01226658746600151,
-0.016784435138106346,
-0.0436665304005146,
-0.016352448612451553,
0.06339386850595474,
-0.032488904893398285,
0.007204257417470217,
0.0776853859424591,
-0.007555245887488127,
0.00910769309848547,
-0.07941332459449768,
-0.02140127867460251,
0.029932992532849312,
0.028223050758242607,
0.030598970130085945,
0.02629711478948593,
0.012824567966163158,
0.0029519007075577974,
-0.03076096437871456,
-0.020825298503041267,
0.01345454715192318,
-0.023993192240595818,
0.05288222059607506,
0.019061358645558357,
0.018485378473997116,
0.0021903011947870255,
0.03216491639614105,
0.019421346485614777,
-0.024389179423451424,
-0.055042147636413574,
-0.055978115648031235,
-0.0002110710192937404,
0.0010850259568542242,
-0.017531409859657288,
-0.019547341391444206,
0.03923868015408516,
-0.008855701424181461,
0.05946999788284302,
-0.060081977397203445,
-0.017648406326770782,
-0.020285317674279213,
0.014372516423463821,
0.03934667631983757,
0.05543813481926918,
-0.01802639290690422,
0.04143460467457771,
0.03715074807405472,
-0.05353019759058952,
0.07296954095363617,
-0.024281183257699013,
-0.014075526036322117,
-0.018521375954151154,
0.006673275493085384,
0.016442446038126945,
0.029303014278411865,
-0.032812897115945816,
-0.025433143600821495,
0.0009342810371890664,
0.03500882163643837,
0.02030331641435623,
0.0077352398075163364,
-0.02395719289779663,
0.04309054836630821,
0.03090495988726616,
-0.022625237703323364,
-0.04125460982322693,
-0.04921034350991249,
0.008500213734805584,
0.05083028972148895,
-0.04719441011548042,
-0.019889330491423607,
-0.02959100343286991,
0.014939497224986553,
-0.04607844725251198,
-0.007411250378936529,
-0.009674673900008202,
-0.027449075132608414,
-0.0010231530759483576,
-0.004508848302066326,
-0.04348653554916382,
0.0298249963670969,
0.021671270951628685,
0.006484281737357378,
0.03569279983639717,
-0.030580971390008926,
-0.0413266085088253,
-0.025325147435069084,
-0.027881061658263206,
0.04820237681269646,
-0.03934667631983757,
-0.007492247968912125,
0.02946500852704048,
-0.017396414652466774,
-0.00789723452180624,
0.01309455931186676,
-0.05745406448841095,
0.014660506509244442,
-0.00392161775380373,
0.008950199000537395,
0.033406876027584076,
0.009584677405655384,
0.003057647030800581,
-0.051730260252952576,
0.01821538619697094,
0.016226453706622124,
0.01126762107014656,
0.018143389374017715,
0.003282639430835843,
-0.039778660982847214,
-0.02136528119444847,
0.012824567966163158,
0.003545880550518632,
-0.06638176739215851,
0.021797265857458115,
-0.08193324506282806,
-0.0025851628743112087,
0.048094380646944046,
0.04028264433145523,
0.024623170495033264,
0.004605595022439957,
-0.12433981150388718,
0.08682907372713089,
0.017630405724048615,
-0.038230713456869125,
0.004418851342052221,
-0.019817333668470383,
-0.016550442203879356,
-0.0363047793507576,
-0.006880268454551697,
0.0332808792591095,
-0.06310587376356125,
-0.02478516474366188,
0.020753301680088043,
-0.01802639290690422,
0.005422317422926426,
0.02280523255467415,
0.01880936697125435,
0.03700675442814827,
0.016271451488137245,
-0.028457041829824448,
0.07016164064407349,
0.0003369261685293168,
0.05659009516239166,
-0.04618644341826439,
-0.01568647101521492,
0.025217151269316673,
-0.02971700020134449,
-0.05626610666513443,
0.014786502346396446,
0.00737525150179863,
0.034720830619335175,
0.01568647101521492,
-0.011186623014509678,
-0.009746671654284,
-0.0016199455130845308,
-0.01280656922608614,
0.028151052072644234,
0.008617210201919079,
0.002474916633218527,
-0.004290605429559946,
-0.007672241888940334,
0.0239751935005188,
-0.05241423472762108,
0.05554613098502159,
-0.026225117966532707,
0.07444549351930618,
0.0037888723891228437,
-0.06569778919219971,
-0.00451109791174531,
-0.02338121272623539,
0.006025297101587057,
-0.00992666557431221,
0.03511681780219078,
0.03511681780219078,
-0.0017020676750689745,
0.0012509578373283148,
-0.0017628156347200274,
0.039418671280145645,
0.00956667773425579,
0.00801423005759716,
0.016676438972353935,
-0.05230623856186867,
-0.021905262023210526,
-0.061953913420438766,
-0.16127456724643707,
0.020249318331480026,
-0.059038013219833374,
0.05615811049938202,
-0.01768440380692482,
-0.024353180080652237,
-0.03241690993309021,
-0.03101295605301857,
0.032236915081739426,
-0.061485931277275085,
-0.016820434480905533,
0.04978632554411888,
-0.005183825269341469,
-0.007109760772436857,
0.01121362205594778,
0.03220091760158539,
-0.009602677077054977,
0.007847735658288002,
-0.04899435117840767,
0.0706656202673912,
-0.001097400556318462,
-0.01655944250524044,
0.011888599954545498,
0.003813621588051319,
0.009202190674841404,
-0.019583340734243393,
0.010826635174453259,
0.01375153660774231,
-0.0158394668251276,
-0.016523443162441254,
-0.03956266865134239,
0.024137187749147415,
-0.05108227953314781,
-0.012428581714630127,
0.028961025178432465,
-0.057742055505514145,
0.017891397699713707,
-0.019169354811310768,
-0.07052162289619446,
0.04733840748667717,
-0.008311220444738865,
0.024713167920708656,
0.011132624931633472,
-0.0258291307836771,
-0.06479781866073608,
-0.006070295814424753,
0.04060663282871246,
-0.0009174066362902522,
0.025181151926517487,
-0.0012070843949913979,
0.043306540697813034,
0.03274089843034744,
0.019187353551387787,
-0.022823231294751167,
0.026855096220970154,
-0.03956266865134239,
0.010367650538682938,
-0.0013983278768137097,
-0.03477482870221138,
0.02127528376877308,
0.0011542111169546843,
0.016775434836745262,
-0.030832961201667786,
-0.016703438013792038,
-0.04085862636566162,
0.005534813739359379,
-0.034342844039201736,
0.08358918875455856,
0.07084561139345169,
0.02680109813809395,
0.06476181745529175
]
|
32,277 | bqplot.marks | _get_dimension_scales |
Return the list of scales corresponding to a given dimension.
The preserve_domain optional argument specifies whether one should
filter out the scales for which preserve_domain is set to True.
| def _get_dimension_scales(self, dimension, preserve_domain=False):
"""
Return the list of scales corresponding to a given dimension.
The preserve_domain optional argument specifies whether one should
filter out the scales for which preserve_domain is set to True.
"""
if preserve_domain:
return [
self.scales[k] for k in self.scales if (
k in self.scales_metadata and
self.scales_metadata[k].get('dimension') == dimension and
not self.preserve_domain.get(k)
)
]
else:
return [
self.scales[k] for k in self.scales if (
k in self.scales_metadata and
self.scales_metadata[k].get('dimension') == dimension
)
]
| (self, dimension, preserve_domain=False) | [
0.04179000109434128,
-0.007583696395158768,
-0.08571600914001465,
0.009551754221320152,
0.04902487248182297,
0.06315010040998459,
0.0026291010435670614,
-0.03081711195409298,
0.07834333181381226,
0.04158329218626022,
-0.003404265968129039,
0.028612198308110237,
-0.005680236034095287,
-0.053813669830560684,
0.017656533047556877,
-0.025080891326069832,
-0.0377935953438282,
0.038551535457372665,
0.06669863313436508,
0.003615282941609621,
0.034348417073488235,
-0.031075499951839447,
0.025063665583729744,
0.014642003923654556,
0.002564503811299801,
0.029370136559009552,
0.042858004570007324,
-0.019499704241752625,
-0.008212441578507423,
0.021618487313389778,
-0.05787897855043411,
0.024994760751724243,
0.01496929582208395,
0.07234872132539749,
-0.026906834915280342,
0.029921365901827812,
0.004521795082837343,
0.026889609172940254,
-0.06935141980648041,
0.04874926060438156,
-0.04096315801143646,
-0.013591224327683449,
0.07985921204090118,
-0.02382340095937252,
0.020378224551677704,
0.051023077219724655,
0.01453003566712141,
0.011196826584637165,
-0.039895154535770416,
0.026631221175193787,
0.051023077219724655,
0.0006325130234472454,
-0.005271121393889189,
0.008500974625349045,
-0.05567406490445137,
0.018724538385868073,
0.0311444029211998,
0.10831637680530548,
0.020154288038611412,
-0.006261609960347414,
-0.0057577528059482574,
-0.021790746599435806,
-0.07448473572731018,
-0.033142607659101486,
-0.017914922907948494,
-0.00581373693421483,
-0.012135636992752552,
-0.01722588576376438,
-0.04330587759613991,
0.012342347763478756,
-0.03135111555457115,
-0.02254868485033512,
-0.013858226127922535,
-0.011903087608516216,
-0.026579543948173523,
-0.02556321583688259,
0.06335680931806564,
0.012755769304931164,
0.01858673244714737,
-0.013703192584216595,
-0.007867923937737942,
0.016088977456092834,
0.01906905695796013,
-0.001508341752924025,
0.014797036536037922,
-0.02344443090260029,
0.018724538385868073,
0.030696529895067215,
-0.00005009637607145123,
-0.04241013154387474,
-0.03603655472397804,
0.007428663782775402,
0.050471849739551544,
0.036174360662698746,
-0.01198921725153923,
0.012213153764605522,
-0.04878371208906174,
-0.017303403466939926,
0.01409077551215887,
-0.019413573667407036,
-0.023168817162513733,
-0.0006012911326251924,
-0.01210979837924242,
0.016511011868715286,
0.013057221658527851,
0.02151513285934925,
-0.014581712894141674,
-0.04688886180520058,
-0.0757249966263771,
0.08075495809316635,
-0.02811264619231224,
0.10824747383594513,
0.01944802515208721,
0.010430274531245232,
-0.028543293476104736,
-0.029163425788283348,
-0.02914620004594326,
0.020137062296271324,
-0.05687987804412842,
-0.022186942398548126,
-0.0884721577167511,
0.05291792377829552,
0.0027561418246477842,
0.04120432212948799,
-0.012049507349729538,
0.028371036052703857,
0.024099014699459076,
0.03551977872848511,
-0.0375179797410965,
0.045062918215990067,
0.005770672112703323,
-0.011403537355363369,
-0.023788949474692345,
0.035381972789764404,
0.06449372321367264,
-0.07172859460115433,
0.01755317859351635,
0.019964803010225296,
0.025080891326069832,
0.08516478538513184,
-0.011782506480813026,
0.03026588261127472,
0.003554992377758026,
0.03290144354104996,
-0.01433193776756525,
0.006308981217443943,
0.07062613219022751,
-0.01993035152554512,
-0.02296210639178753,
-0.03334931656718254,
-0.034744612872600555,
0.07930798083543777,
0.05901588872075081,
-0.059119243174791336,
-0.03837927430868149,
-0.0025903426576405764,
-0.02723412774503231,
-0.011816957965493202,
0.006489852908998728,
-0.0027733677998185158,
-0.0692136138677597,
0.02160126157104969,
-0.04309916868805885,
-0.0376557894051075,
-0.01841447316110134,
-0.034503452479839325,
0.022376427426934242,
-0.03710455819964409,
-0.007097065448760986,
0.049748361110687256,
0.0068774353712797165,
0.015296587720513344,
-0.035381972789764404,
-0.0241334680467844,
-0.054916128516197205,
0.08151289820671082,
0.04320252314209938,
-0.004312931559979916,
0.006024753674864769,
0.0673876702785492,
0.025838829576969147,
-0.10142602026462555,
-0.035381972789764404,
-0.00756647065281868,
-0.017897697165608406,
0.020137062296271324,
-0.0033202895428985357,
0.006946338806301355,
-0.04247903823852539,
0.008475136011838913,
0.047371190041303635,
0.024736372753977776,
-0.016924433410167694,
-0.005387396086007357,
-0.017932148650288582,
-0.0168469175696373,
-0.034899648278951645,
-0.012049507349729538,
-0.06904135644435883,
0.020516030490398407,
0.04089425504207611,
-0.04051528498530388,
0.009146945551037788,
0.0025903426576405764,
-0.022755395621061325,
0.02303101122379303,
-0.027613095939159393,
0.009663722477853298,
-0.02540818229317665,
0.014469744637608528,
-0.04644098877906799,
-0.031402792781591415,
-0.0033913464285433292,
-0.02096390351653099,
0.025304827839136124,
0.013952968642115593,
-0.03862043842673302,
0.010619759559631348,
0.04695776849985123,
-0.03844817727804184,
0.008600023575127125,
-0.04661324992775917,
0.01565833017230034,
0.07248653471469879,
-0.03011084906756878,
-0.004913683980703354,
0.08826544135808945,
-0.03979180008172989,
0.014142452739179134,
0.018448924645781517,
-0.01425442099571228,
-0.0055165900848805904,
0.007071226369589567,
-0.03334931656718254,
0.10211505740880966,
0.005275427829474211,
0.061048541218042374,
0.045062918215990067,
0.10934992879629135,
0.039275020360946655,
-0.010921211913228035,
-0.005271121393889189,
-0.023478884249925613,
0.03477906435728073,
-0.044132720679044724,
0.008815347217023373,
-0.0022652042098343372,
0.05240114778280258,
0.006425255909562111,
-0.01777711510658264,
-0.03961953893303871,
-0.03500300273299217,
0.04051528498530388,
0.005585493985563517,
0.02771645225584507,
-0.04695776849985123,
-0.07999701797962189,
-0.025046439841389656,
0.023565012961626053,
-0.06776663661003113,
-0.002400857862085104,
0.009620658122003078,
-0.055329546332359314,
0.03026588261127472,
0.00040723072015680373,
-0.025477087125182152,
0.023651141673326492,
0.05195327475667,
0.042926911264657974,
0.029215103015303612,
-0.06294339150190353,
0.08433794230222702,
-0.03555423021316528,
-0.0019153032917529345,
-0.006067818496376276,
0.057224396616220474,
0.061186350882053375,
-0.03104104846715927,
0.0025709636975079775,
0.08516478538513184,
-0.01614926941692829,
-0.006270222831517458,
-0.016063138842582703,
0.013470643199980259,
0.03992960602045059,
-0.023409979417920113,
-0.0004984741099178791,
-0.04892151802778244,
-0.01183418370783329,
0.04010186344385147,
-0.03886159881949425,
0.05942931026220322,
-0.014047710224986076,
-0.04564860090613365,
-0.05012733116745949,
-0.007260711397975683,
-0.00019419495947659016,
-0.05377921834588051,
0.04113541916012764,
0.02969742938876152,
0.03334931656718254,
-0.0065759820863604546,
0.035313066095113754,
0.055708516389131546,
0.00006685124390060082,
0.007514792960137129,
0.04881816357374191,
-0.02620057389140129,
0.037759143859148026,
0.0547783188521862,
0.019086282700300217,
0.01874176412820816,
0.005731913726776838,
0.017096692696213722,
0.020550481975078583,
-0.010094369761645794,
0.00993072334676981,
0.011498278938233852,
-0.020050931721925735,
0.07031606882810593,
0.007622454781085253,
0.021411776542663574,
-0.03302202373743057,
0.07779210060834885,
0.017811566591262817,
0.0728999525308609,
-0.029818009585142136,
-0.0019023838685825467,
0.03405557945370674,
0.0014275953872129321,
-0.015262135304510593,
-0.011334633454680443,
-0.023685595020651817,
0.012738543562591076,
0.03600210323929787,
-0.0754493847489357,
0.07103955745697021,
0.03190234303474426,
0.03731127083301544,
0.0016375358682125807,
-0.01612343080341816,
-0.057327751070261,
-0.05160875618457794,
-0.012411251664161682,
0.025787152349948883,
0.021807972341775894,
0.025787152349948883,
-0.03676004335284233,
-0.01968918927013874,
0.0033353623002767563,
-0.01882789470255375,
-0.03400389850139618,
-0.009146945551037788,
0.09267526865005493,
0.03541642427444458,
-0.004694053903222084,
0.018242213875055313,
0.011334633454680443,
-0.04616537690162659,
0.07524267584085464,
0.08674956858158112,
-0.01032691914588213,
0.010731727816164494,
-0.005495057906955481,
0.02184242382645607,
-0.0042311083525419235,
0.01413383986800909,
-0.04489066079258919,
0.059532664716243744,
-0.012015055865049362,
0.0020638764835894108,
-0.008087554015219212,
-0.02111893706023693,
-0.004319391213357449,
-0.025752700865268707,
-0.032126277685165405,
-0.008488055318593979,
-0.02763032168149948,
0.014986521564424038,
0.028233228251338005,
-0.008513894863426685,
0.010671436786651611,
0.024409081786870956,
0.017122531309723854,
-0.03135111555457115,
0.014194130897521973,
0.01603730022907257,
-0.06218545138835907,
-0.009215849451720715,
-0.03713901340961456,
0.03477906435728073,
-0.029507944360375404,
0.03986070305109024,
0.05036849156022072,
-0.04192780703306198,
-0.015649717301130295,
-0.014745359309017658,
0.02707909420132637,
0.02542540803551674,
-0.01612343080341816,
-0.061737578362226486,
-0.03741462528705597,
-0.04551079124212265,
0.054916128516197205,
-0.016838304698467255,
-0.05405483394861221,
0.03129943460226059,
0.09736071527004242,
0.01521045807749033,
0.04692331701517105,
0.019826995208859444,
-0.008199522271752357,
-0.004599311854690313,
-0.045614149421453476,
0.004063155967742205,
0.001026555197313428,
-0.011326020583510399,
0.012359573505818844,
0.007824858650565147,
0.0404808335006237,
-0.009586205706000328,
-0.03913721442222595,
-0.00956897996366024,
0.005094556137919426,
0.007290856447070837,
-0.058430206030607224,
-0.012204540893435478,
0.052056629210710526,
-0.028732778504490852,
0.007454502396285534,
0.0034774758387356997,
0.006003221496939659,
-0.018483376130461693,
-0.10314860939979553,
0.07004045695066452,
-0.021618487313389778,
-0.003787541761994362,
0.07024716585874557,
-0.05488167330622673,
-0.005792204290628433,
0.027182448655366898,
-0.009301979094743729,
0.018328342586755753,
-0.05402038246393204,
0.028060968965291977,
0.004211729392409325,
-0.06669863313436508,
0.03965399041771889,
-0.04647544398903847,
-0.05922259762883186,
-0.026407284662127495,
-0.04223787412047386,
0.05922259762883186,
-0.03986070305109024,
0.0612897053360939,
-0.00023254947154782712,
-0.01643349602818489,
-0.04137657955288887,
0.0041815838776528835,
0.002547278068959713,
-0.019103508442640305,
-0.00573622016236186,
-0.03214350342750549,
-0.049748361110687256,
0.013978807255625725,
0.0557774193584919,
-0.019964803010225296,
-0.03209182620048523,
0.027303030714392662,
-0.01643349602818489,
-0.00627452926710248,
0.06232325732707977,
0.009224462322890759,
-0.07434692978858948,
-0.01898292638361454,
-0.01147244032472372,
0.0056457845494151115,
0.05791343003511429,
0.0030683609656989574,
0.008966074325144291,
0.018552279099822044,
-0.007850698195397854,
0.015443007461726665,
0.007811939809471369,
0.00031544905505143106,
-0.006231464445590973,
-0.0067224022932350636,
0.02868110127747059,
-0.0305759496986866,
0.03851708397269249,
0.003244926454499364,
0.02978355810046196,
0.022514233365654945,
-0.011679151095449924,
-0.011730829253792763,
-0.0007191807962954044,
0.015675557777285576,
-0.021067259833216667,
0.053159087896347046,
0.03159227594733238,
0.001098688575439155,
-0.038000304251909256,
-0.015107102692127228,
0.053331345319747925,
0.02063661254942417,
-0.0055553484708070755,
-0.020223191007971764,
0.07055722922086716,
0.01540855597704649,
-0.0376557894051075,
-0.05536400154232979,
0.024822503328323364,
-0.01841447316110134,
-0.015701396390795708,
-0.016924433410167694,
0.014986521564424038,
-0.07985921204090118,
0.0004583700792863965,
-0.011222665198147297,
0.040377479046583176,
0.0027518353890627623,
0.042858004570007324,
0.03551977872848511,
0.04461504518985748,
0.01115376129746437,
0.02032654546201229,
-0.06225435435771942,
-0.050402943044900894,
-0.00016472254355903715,
0.01484871469438076,
-0.0067353215999901295,
-0.014478357508778572,
0.01970641501247883,
0.03352157399058342,
-0.014555874280631542,
0.024047337472438812,
-0.03407280519604683,
-0.06380468606948853,
-0.026803480461239815,
0.03002472035586834,
-0.008686153218150139,
-0.023065462708473206,
0.04368484765291214,
0.001049164216965437,
-0.007260711397975683,
0.0007757032290101051,
0.03240189328789711,
-0.009732626378536224,
0.07241762429475784,
-0.019913125783205032,
0.032453570514917374,
-0.0014480510726571083,
0.03384886682033539,
-0.07613842189311981,
0.05918814614415169,
-0.0428924560546875,
-0.034675709903240204,
-0.01052501704543829,
-0.05501948297023773,
-0.020550481975078583,
0.029507944360375404,
-0.05281456932425499,
0.07923907786607742,
0.04368484765291214,
-0.08178851008415222,
-0.040205217897892,
-0.045545242726802826,
-0.010275240987539291,
-0.015606652945280075,
-0.002560197375714779,
0.02358223870396614,
-0.0066836439073085785,
0.015563588589429855,
0.04406381770968437,
0.022910429164767265,
0.0207399670034647,
0.042203422635793686,
-0.11837629228830338,
-0.029507944360375404,
-0.01678662747144699,
-0.04644098877906799,
-0.017036402598023415,
0.008341635577380657,
0.02620057389140129,
-0.045717503875494,
0.03572648763656616,
0.0036260492634028196,
0.0034430241212248802,
0.020429901778697968,
0.01049056462943554,
0.03813811391592026,
0.029042845591902733,
0.026734575629234314,
0.006356352008879185,
0.013780709356069565,
-0.0494038425385952,
-0.02439185604453087,
-0.0467166043817997,
-0.04206561669707298,
-0.050058428198099136,
-0.015735847875475883,
0.038482632488012314,
0.016157882288098335,
0.04957610368728638,
0.0234961099922657,
-0.09942781925201416,
0.0416177436709404,
-0.007837778888642788,
-0.004599311854690313,
-0.06704314798116684,
-0.0663885697722435,
-0.0007579390075989068,
-0.005434767343103886,
-0.026166122406721115,
0.07655183970928192,
-0.047784607857465744,
-0.031643953174352646,
0.03231576457619667,
0.020050931721925735,
-0.04375375062227249,
0.026183348149061203,
0.02129119634628296,
0.0030145300552248955,
0.004646683111786842,
-0.024012885987758636,
-0.05171211063861847,
0.040687546133995056,
-0.020516030490398407,
-0.011093471199274063,
-0.04385710880160332,
-0.008341635577380657,
-0.03472738713026047,
-0.006756854243576527,
-0.054674964398145676,
-0.0022544378880411386,
0.004840474110096693,
-0.006903273984789848,
-0.023926757276058197,
-0.02024041675031185,
-0.022996557876467705,
0.05567406490445137,
-0.00009359847172163427,
0.014168291352689266,
-0.013341449201107025,
-0.011704989708960056,
-0.03112717717885971,
0.0273891594260931,
0.02216971665620804,
0.01595117151737213,
-0.0023168816696852446,
-0.03471016138792038,
-0.003987792879343033,
0.015184619463980198,
-0.028405487537384033,
0.033624932169914246,
0.060635119676589966,
0.04127322509884834,
0.0002947241591755301,
-0.011412150226533413,
-0.051023077219724655,
0.02399566024541855,
0.029749106615781784,
-0.00690758042037487,
0.004250487312674522,
0.03257415071129799,
-0.04409826919436455,
-0.03662223368883133,
0.006106576882302761,
-0.024322951212525368,
0.011127922683954239,
0.04437388479709625,
-0.005632864776998758,
-0.023082688450813293,
0.0027023109141737223,
-0.034503452479839325,
0.01834557019174099,
-0.01413383986800909,
0.024822503328323364,
0.015632491558790207,
-0.004216035827994347,
-0.022186942398548126,
-0.02826767973601818,
-0.03631217032670975,
0.06349461525678635,
-0.0007584773120470345,
-0.04668215289711952,
0.006179786752909422,
-0.09095267951488495,
-0.04985171556472778,
0.027458064258098602,
0.02564934454858303,
-0.03896495699882507,
0.04668215289711952,
-0.059291500598192215,
0.0012919415021315217,
0.01449558325111866,
-0.048163577914237976,
0.03214350342750549,
0.03772469237446785,
0.019999254494905472,
-0.011730829253792763,
-0.02327217347919941,
-0.04537298530340195,
0.07338228076696396,
0.03345267102122307,
-0.03762133792042732,
-0.0298696868121624,
-0.02105003409087658,
-0.006451094523072243,
0.021308422088623047,
-0.0020165054593235254,
0.030593175441026688,
0.05391702428460121,
-0.021325647830963135,
-0.017329242080450058,
-0.00044356659054756165,
0.00008518739196006209,
0.02239365316927433,
0.027613095939159393,
0.0038176870439201593,
0.017604855820536613,
-0.03002472035586834,
0.028336582705378532,
0.043960463255643845,
-0.03576093912124634,
0.03913721442222595,
0.06060066819190979,
0.03676004335284233,
-0.00035070828744210303,
-0.0702127143740654,
-0.031075499951839447,
0.014736746437847614,
0.009198623709380627,
0.005266814958304167,
-0.005266814958304167,
0.0067697735503315926,
0.0273891594260931,
-0.009439785964787006,
-0.04854254797101021,
0.012316509149968624,
0.0035205406602472067,
-0.022669266909360886,
-0.019551381468772888,
-0.01913795992732048,
0.014461131766438484,
-0.005921398755162954,
-0.014168291352689266,
0.019913125783205032,
-0.010705888271331787,
-0.005899866111576557,
0.05784452706575394,
-0.005150540266185999,
-0.04179000109434128,
-0.02707909420132637,
-0.010232176631689072,
-0.05887807905673981,
0.011515505611896515,
-0.013393127359449863,
0.014616165310144424,
-0.0253392793238163,
-0.04644098877906799,
-0.036656685173511505,
-0.0376557894051075,
0.0404808335006237,
-0.010094369761645794,
-0.012290670536458492,
0.050885267555713654,
-0.037759143859148026
]
|
32,281 | bqplot.marks | _handle_custom_msgs | null | def _handle_custom_msgs(self, _, content, buffers=None):
try:
handler = self._name_to_handler[content['event']]
except KeyError:
return
handler(self, content)
| (self, _, content, buffers=None) | [
-0.010681196115911007,
-0.05532705783843994,
-0.045935116708278656,
0.011244712397456169,
-0.0049222297966480255,
0.004324560984969139,
0.003662856062874198,
0.08947955816984177,
0.04740367457270622,
0.02149900235235691,
-0.00264255004003644,
0.020440272986888885,
0.03254733607172966,
-0.05102384090423584,
-0.029610220342874527,
0.030532339587807655,
0.004456901922821999,
0.0073214429430663586,
0.00043224263936281204,
-0.04077808931469917,
0.008568009361624718,
-0.016820108518004417,
0.012183905579149723,
0.022199127823114395,
-0.005861423444002867,
0.07192517071962357,
-0.01183384284377098,
0.013584158383309841,
0.009357785806059837,
-0.024060439318418503,
-0.034135427325963974,
-0.06707552075386047,
0.04187097027897835,
0.020371967926621437,
-0.05068231746554375,
-0.010928801260888577,
-0.02020120620727539,
0.013763459399342537,
-0.01895464025437832,
0.009887149557471275,
0.011116639710962772,
0.03736284002661705,
0.013806150294840336,
-0.006070607807487249,
0.013942759484052658,
0.05054570734500885,
-0.020508578047156334,
0.10689733922481537,
0.009827382862567902,
0.00855520274490118,
-0.054302480071783066,
-0.0438859686255455,
-0.028893018141388893,
0.009443167597055435,
-0.0027492765802890062,
0.06635831296443939,
0.03999258205294609,
0.02293340675532818,
-0.003797331592068076,
0.0176568441092968,
-0.0219600610435009,
0.0285173412412405,
-0.011244712397456169,
-0.008649121969938278,
-0.009861535392701626,
-0.054336633533239365,
0.12520308792591095,
-0.029200391843914986,
-0.029558992013335228,
0.00583154009655118,
0.02030366286635399,
-0.03661148622632027,
-0.0022455272264778614,
0.009494395926594734,
0.010587275959551334,
-0.011996067129075527,
0.0011739922920241952,
0.015889452770352364,
0.006023647729307413,
0.07609178125858307,
0.06270399689674377,
-0.03176182880997658,
-0.009605391882359982,
0.003423788584768772,
0.020935485139489174,
-0.07137873023748398,
0.012397359125316143,
-0.00108060659840703,
-0.03176182880997658,
0.05976688116788864,
0.01888633519411087,
-0.06779272109270096,
-0.029593145474791527,
-0.009716387838125229,
-0.04733537137508392,
-0.01033113244920969,
-0.01886925846338272,
0.0024931328371167183,
0.038114193826913834,
0.08394685387611389,
-0.021908830851316452,
0.049486979842185974,
0.01232051569968462,
0.008183794096112251,
0.021447772160172462,
0.0031911246478557587,
-0.009084566496312618,
-0.007244599983096123,
-0.009554162621498108,
0.024350736290216446,
0.031830135732889175,
-0.013550005853176117,
-0.01512955967336893,
0.009494395926594734,
0.00616025784984231,
-0.015718689188361168,
0.0033490799833089113,
0.040709786117076874,
-0.06041577830910683,
0.012721807695925236,
-0.03818250074982643,
-0.05686391890048981,
0.038489870727062225,
-0.03623580560088158,
-0.0351087749004364,
0.020508578047156334,
0.014053755439817905,
-0.03609919548034668,
0.039275381714105606,
-0.015966296195983887,
-0.023394465446472168,
0.02505086176097393,
0.01808375120162964,
-0.0526631623506546,
0.01885218173265457,
0.04347613826394081,
-0.008811346255242825,
-0.01597483456134796,
0.030139584094285965,
-0.015308859758079052,
0.04805257171392441,
0.03350360691547394,
0.006211486645042896,
-0.0571371391415596,
-0.03862648084759712,
-0.012013142928481102,
0.09931547939777374,
0.016692036762833595,
-0.00019090715795755386,
-0.027868444100022316,
-0.015872376039624214,
0.02117455191910267,
-0.01721286214888096,
0.04265647754073143,
-0.008785732090473175,
0.020013367757201195,
0.0029307117220014334,
-0.008281982503831387,
-0.04125622659921646,
0.05232163518667221,
0.056010108441114426,
-0.005801656749099493,
-0.009468781761825085,
-0.019449850544333458,
0.021669764071702957,
0.02766352891921997,
0.031915515661239624,
-0.029815135523676872,
-0.007803847081959248,
-0.003060918301343918,
-0.007372671738266945,
0.08162448555231094,
0.0006142114289104939,
0.01799836941063404,
0.0747256800532341,
0.056010108441114426,
-0.05095553770661354,
-0.01804959774017334,
0.002185760298743844,
-0.006553011946380138,
-0.004866731818765402,
0.034084200859069824,
0.02242111973464489,
0.030429881066083908,
-0.03338407352566719,
0.019535232335329056,
0.02467518486082554,
-0.014122060500085354,
-0.038865551352500916,
-0.0017129615880548954,
-0.019518155604600906,
0.0082606365904212,
-0.003805869724601507,
-0.0010416513541713357,
0.03650902584195137,
0.030668949708342552,
-0.034886784851551056,
-0.002634011907503009,
-0.021823450922966003,
-0.023121245205402374,
0.01758853904902935,
-0.008427130058407784,
-0.03241072595119476,
0.06325043737888336,
-0.006988456007093191,
0.04101715609431267,
0.09371446818113327,
0.04760859161615372,
-0.06984186917543411,
-0.06280645728111267,
-0.06509467214345932,
-0.021277010440826416,
-0.012568121775984764,
0.004266928415745497,
0.049486979842185974,
-0.007722734939306974,
-0.09064074605703354,
-0.006971379742026329,
-0.03736284002661705,
-0.014472123235464096,
0.042417410761117935,
0.04559359326958656,
-0.03246195614337921,
0.030976321548223495,
0.023565227165818214,
0.029183315113186836,
0.04760859161615372,
-0.009759077802300453,
0.05771773308515549,
0.04142698645591736,
0.010006683878600597,
0.07342788577079773,
0.01623951643705368,
0.03475017473101616,
-0.009033337235450745,
0.011073949746787548,
0.017776379361748695,
-0.034528180956840515,
-0.03381098061800003,
0.012790112756192684,
0.034920934587717056,
0.0034728827886283398,
0.020406121388077736,
-0.011244712397456169,
0.026280352845788002,
-0.011978991329669952,
0.0220625177025795,
0.038045890629291534,
0.0008997050463221967,
0.0706273764371872,
0.009357785806059837,
0.00427760137245059,
0.004482516087591648,
-0.01098003052175045,
-0.08626922219991684,
-0.007479398511350155,
-0.028807638213038445,
0.0013063333462923765,
0.02812458761036396,
-0.025392387062311172,
-0.028039205819368362,
0.06516297906637192,
0.03381098061800003,
0.05102384090423584,
0.015274707227945328,
-0.020320739597082138,
0.015889452770352364,
0.02909793332219124,
-0.011150792241096497,
0.044978849589824677,
0.0397193618118763,
0.023104168474674225,
0.03258148953318596,
-0.018664343282580376,
-0.03029327094554901,
0.004469709005206823,
-0.017776379361748695,
-0.007206178270280361,
-0.01057020016014576,
0.015266169793903828,
0.03167644888162613,
0.026280352845788002,
0.014779496006667614,
0.01627366803586483,
0.01693110354244709,
-0.019022945314645767,
0.07534042745828629,
0.0099127646535635,
-0.0022967560216784477,
-0.07110551744699478,
-0.024060439318418503,
0.00964808277785778,
0.0038656366523355246,
0.0526631623506546,
-0.03244487941265106,
-0.002945653395727277,
-0.04805257171392441,
0.015547927469015121,
0.04976020008325577,
0.007206178270280361,
0.014122060500085354,
0.003451537573710084,
0.060449931770563126,
-0.06195264309644699,
-0.015872376039624214,
-0.0032039317302405834,
0.0175031591206789,
-0.008346018381416798,
-0.011389859952032566,
-0.00831613503396511,
0.010723886080086231,
0.008990646339952946,
-0.046379100531339645,
-0.029354076832532883,
0.008683274500072002,
0.0920751541852951,
0.09303142130374908,
0.04040241241455078,
0.049930959939956665,
0.06488975882530212,
-0.00235865730792284,
-0.03389636054635048,
-0.0616111159324646,
0.00964808277785778,
0.02373599074780941,
-0.017281167209148407,
-0.04511545971035957,
-0.0018058136338368058,
0.017059175297617912,
-0.05942535772919655,
0.02467518486082554,
-0.04012919217348099,
-0.02069641835987568,
-0.09111887961626053,
-0.016085829585790634,
-0.04699384421110153,
-0.04221249371767044,
0.024367811158299446,
-0.00864485278725624,
-0.044671475887298584,
-0.07117381691932678,
0.013234095647931099,
0.017443392425775528,
0.048223335295915604,
0.047198761254549026,
-0.016623731702566147,
0.03691885620355606,
0.0036009547766298056,
0.011774076148867607,
-0.05587349832057953,
0.015735765919089317,
-0.09023091942071915,
0.02812458761036396,
-0.012636426836252213,
0.027424460276961327,
-0.04713045433163643,
0.013319476507604122,
-0.040163345634937286,
0.004670355003327131,
0.02551192045211792,
0.06246493011713028,
-0.016990870237350464,
0.045900966972112656,
-0.04921375960111618,
-0.0483599454164505,
0.04313461109995842,
0.0075861248187720776,
0.03475017473101616,
0.07643330097198486,
-0.02995174564421177,
0.03457941114902496,
0.017417777329683304,
-0.05324375256896019,
0.05983518809080124,
-0.02952484041452408,
-0.014899030327796936,
-0.017486082389950752,
0.003267967840656638,
-0.06895390897989273,
0.03808004409074783,
0.03353776037693024,
0.04084639623761177,
-0.011167868971824646,
-0.03208627924323082,
0.019637690857052803,
0.003816542448475957,
-0.033230386674404144,
0.058332476764917374,
-0.06260154396295547,
-0.02639988623559475,
0.008294789120554924,
-0.005310714244842529,
-0.026160817593336105,
-0.021242856979370117,
-0.05372188985347748,
-0.0263828095048666,
-0.028739333152770996,
0.019688919186592102,
-0.0060919527895748615,
0.0031441650353372097,
-0.02336031384766102,
-0.015249093063175678,
-0.04562774673104286,
-0.006851846352219582,
0.03681639954447746,
0.04320291802287102,
-0.04576435685157776,
0.052936382591724396,
0.017016485333442688,
0.09173362702131271,
-0.002001123270019889,
0.05013587698340416,
-0.006612778641283512,
-0.046823084354400635,
-0.002578514162451029,
-0.032308269292116165,
-0.020935485139489174,
0.011705771088600159,
-0.06796348094940186,
-0.014318437315523624,
-0.06779272109270096,
0.03999258205294609,
0.06369441747665405,
-0.020833028480410576,
0.017912987619638443,
-0.037533603608608246,
-0.05324375256896019,
-0.030703101307153702,
0.014625810086727142,
-0.02631450444459915,
-0.04450071230530739,
-0.000496278575155884,
-0.07247161120176315,
-0.03999258205294609,
0.03640656918287277,
0.016145596280694008,
-0.049930959939956665,
-0.029251620173454285,
-0.047198761254549026,
-0.0042221033945679665,
-0.048564862459897995,
0.04477393254637718,
-0.03082263469696045,
-0.036304112523794174,
0.04709630459547043,
-0.01627366803586483,
-0.006121836602687836,
0.004262659233063459,
-0.013771997764706612,
-0.04450071230530739,
0.0030929362401366234,
0.06068899855017662,
0.03037865273654461,
-0.003280774923041463,
-0.019825529307127,
-0.060859762132167816,
0.013575620017945766,
0.0011718578170984983,
0.025289928540587425,
-0.059186290949583054,
-0.07807262241840363,
-0.027151240035891533,
-0.05406341329216957,
-0.07534042745828629,
0.01471972931176424,
0.047676894813776016,
-0.03036157600581646,
0.019501080736517906,
-0.0048752701841294765,
0.012465664185583591,
0.031095854938030243,
-0.008405785076320171,
0.03695300966501236,
-0.02679263986647129,
0.003588147461414337,
-0.03480140119791031,
0.03082263469696045,
-0.027526918798685074,
-0.002723662182688713,
0.05327790603041649,
0.079302117228508,
-0.031010473147034645,
0.03596258535981178,
-0.04634494706988335,
-0.00836736336350441,
0.009187024086713791,
0.023889677599072456,
-0.05068231746554375,
0.03338407352566719,
-0.009605391882359982,
-0.0005827270797453821,
0.018169132992625237,
0.03475017473101616,
-0.012457125820219517,
0.028722256422042847,
-0.05758112296462059,
0.010442128404974937,
-0.002097177319228649,
0.03797758370637894,
-0.03838741406798363,
-0.018220361322164536,
-0.0004866731760557741,
-0.02506793849170208,
-0.021379467099905014,
-0.003372559789568186,
-0.05884476378560066,
0.02380429580807686,
0.034135427325963974,
0.015932142734527588,
-0.02906378172338009,
-0.046788930892944336,
0.0616111159324646,
-0.005583934485912323,
-0.06560695916414261,
-0.03691885620355606,
-0.028346577659249306,
-0.017050636932253838,
0.031147083267569542,
-0.05553197115659714,
-0.00017062910774257034,
0.07206178456544876,
-0.028414882719516754,
0.005135682877153158,
0.013106023892760277,
0.00405987910926342,
-0.0024845947045832872,
-0.0704907700419426,
0.035416148602962494,
0.02764645218849182,
0.007419631350785494,
-0.018339894711971283,
0.01008352730423212,
0.010689733549952507,
0.016384663060307503,
-0.030071280896663666,
0.041085463017225266,
0.00428187008947134,
-0.03883139789104462,
-0.06372857093811035,
0.04603757709264755,
-0.02544361539185047,
-0.028893018141388893,
-0.04265647754073143,
-0.04620833694934845,
-0.0484282523393631,
0.004147394560277462,
-0.006698159966617823,
0.011244712397456169,
0.01762269251048565,
-0.028756408020853996,
0.017930064350366592,
-0.06202094629406929,
-0.006950034759938717,
0.053414516150951385,
0.01013475563377142,
-0.01895464025437832,
-0.011270326562225819,
-0.0350746214389801,
0.01883510686457157,
-0.02160145901143551,
-0.031898438930511475,
0.06058654189109802,
-0.0482574887573719,
0.062294166535139084,
-0.052116721868515015,
0.02855149284005165,
-0.04129037633538246,
0.049452826380729675,
-0.06051823869347572,
0.005788849666714668,
0.008269174955785275,
0.022233279421925545,
-0.0003180452040396631,
-0.07370110601186752,
0.010723886080086231,
0.014531890861690044,
0.015599156729876995,
-0.03558690845966339,
-0.01599190942943096,
0.0027620838955044746,
-0.02906378172338009,
-0.03299131989479065,
0.015095407143235207,
-0.019962139427661896,
0.0029179046396166086,
-0.02380429580807686,
-0.02069641835987568,
-0.024743489921092987,
0.0329400897026062,
0.03167644888162613,
-0.019637690857052803,
0.02371891401708126,
-0.013259709812700748,
-0.03743114322423935,
0.04511545971035957,
0.046379100531339645,
0.024845946580171585,
0.018339894711971283,
-0.03548445180058479,
-0.02771475724875927,
-0.024367811158299446,
0.028039205819368362,
-0.031847208738327026,
-0.0013821091270074248,
0.05338036268949509,
-0.018186207860708237,
-0.009887149557471275,
0.005255216732621193,
0.015718689188361168,
0.041153766214847565,
-0.033196233212947845,
0.009904226288199425,
0.035860128700733185,
0.06243077665567398,
0.04494469612836838,
0.00043384352466091514,
0.005532705690711737,
0.0036137618590146303,
0.07144703716039658,
-0.0007225389126688242,
0.034511104226112366,
-0.013362167403101921,
-0.03883139789104462,
-0.003835753072053194,
-0.001580620533786714,
-0.028466112911701202,
-0.004138856660574675,
-0.03558690845966339,
-0.0329400897026062,
0.042895544320344925,
-0.013515853323042393,
0.032803479582071304,
0.005818733014166355,
-0.04928206279873848,
0.05887891724705696,
0.019654765725135803,
-0.05136536806821823,
-0.040231648832559586,
-0.04576435685157776,
-0.013268248178064823,
0.012499816715717316,
-0.061406202614307404,
-0.030515262857079506,
-0.09187023341655731,
-0.034476954489946365,
0.10778530687093735,
0.019535232335329056,
-0.0077825020998716354,
0.03664563596248627,
0.009221176616847515,
0.04562774673104286,
-0.004913691431283951,
-0.05853739380836487,
0.08148787170648575,
0.042895544320344925,
0.06871484220027924,
0.012089986354112625,
0.005157028324902058,
0.0028303887229412794,
0.02952484041452408,
-0.052560705691576004,
-0.033127930015325546,
0.06929542869329453,
0.007082375697791576,
-0.04221249371767044,
-0.06280645728111267,
-0.0003818143159151077,
-0.030002975836396217,
0.025682684034109116,
0.00831613503396511,
0.034886784851551056,
-0.0048155030235648155,
-0.0013618310913443565,
-0.007291559595614672,
0.046788930892944336,
-0.034032970666885376,
0.05631747841835022,
0.023838447406888008,
0.031386151909828186,
-0.0037653136532753706,
-0.006689621601253748,
0.027339080348610878,
-0.02102086693048477,
0.03261564299464226,
0.05682976543903351,
-0.039855971932411194,
0.048120878636837006,
0.015804070979356766,
-0.017810530960559845,
-0.05245824530720711,
0.04586681351065636,
-0.005857154261320829,
-0.012653502635657787,
0.007125066127628088,
-0.07144703716039658,
0.09501226991415024,
-0.019108325242996216,
-0.05904968082904816,
0.0007593595655634999,
0.01295233704149723,
0.014608733355998993,
-0.027475690469145775,
0.0021921638399362564,
-0.07076399028301239,
-0.006202948745340109,
-0.05358527973294258,
-0.056966375559568405,
-0.004465439822524786,
-0.006864653434604406,
0.060449931770563126,
-0.045149609446525574,
-0.04446655884385109,
0.022745568305253983,
0.010493356734514236,
-0.026980478316545486,
-0.02942238189280033,
-0.03739699348807335,
0.06318213045597076,
0.038045890629291534,
0.01187653373926878,
-0.051228757947683334,
-0.004397134762257338,
0.03217165917158127,
-0.02378721907734871,
0.025665607303380966,
-0.06560695916414261,
0.013771997764706612,
-0.0350063182413578,
0.04006088897585869,
0.04511545971035957,
-0.01890341192483902,
-0.05539536103606224,
-0.05375604331493378,
0.05139951780438423,
0.0054515935480594635,
-0.05618086829781532,
0.03223996236920357,
-0.04009503871202469,
0.021686840802431107,
0.01980845257639885,
-0.03705546632409096,
-0.015701614320278168,
0.011910686269402504,
0.00806425977498293,
0.012209520675241947,
-0.01360977254807949,
-0.000748686958104372,
0.06837331503629684,
-0.016401739791035652,
0.07786770910024643,
-0.010442128404974937,
0.01803252287209034,
-0.03247903287410736,
-0.023018788546323776,
-0.016401739791035652,
0.001497373916208744,
-0.01984260417521,
-0.053414516150951385,
0.005507091525942087,
0.019091250374913216,
0.00473866006359458,
0.020474426448345184,
-0.01885218173265457,
0.0015037774574011564,
0.0439884252846241,
-0.004358713515102863,
0.01212413888424635,
0.038933854550123215
]
|
32,306 | bqplot.marks | on_background_click | null | def on_background_click(self, callback, remove=False):
self._bg_click_handlers.register_callback(callback, remove=remove)
| (self, callback, remove=False) | [
-0.00032985155121423304,
0.011085577309131622,
-0.0422552116215229,
0.04047604650259018,
-0.017423858866095543,
0.02974972128868103,
0.01468667946755886,
0.11338766664266586,
0.01207780558615923,
-0.056043755263090134,
0.03681506589055061,
0.03647292032837868,
-0.013703005388379097,
-0.10264423489570618,
-0.045231893658638,
0.02340288646519184,
0.021281572058796883,
0.022068511694669724,
-0.0009981082985177636,
-0.027628406882286072,
-0.015370974317193031,
0.053511861711740494,
-0.036062341183423996,
-0.0031370646320283413,
0.005153595935553312,
0.05542789027094841,
-0.04300793632864952,
-0.0007120944210328162,
0.052177488803863525,
0.03132360056042671,
0.01669679582118988,
-0.02879170887172222,
-0.0258492399007082,
0.021059175953269005,
-0.05960208922624588,
0.017996955662965775,
0.008369782008230686,
0.034642431885004044,
0.00890438724309206,
-0.01722712442278862,
-0.016876423731446266,
-0.025986099615693092,
0.017569271847605705,
-0.020409096032381058,
0.0633314922451973,
0.050124604254961014,
0.0312722772359848,
-0.03022872842848301,
0.04016811028122902,
-0.05754920467734337,
-0.00538882240653038,
-0.04571090266108513,
0.008433935232460499,
0.042665787041187286,
-0.0551883839070797,
0.037020355463027954,
0.003714438294991851,
-0.006038902793079615,
-0.011761318892240524,
0.034009456634521484,
0.029185177758336067,
0.022154048085212708,
0.029082534834742546,
0.0012958835577592254,
0.04998774453997612,
-0.006928486283868551,
-0.03626763075590134,
-0.004165645223110914,
0.010016366839408875,
-0.01738109067082405,
0.013814203441143036,
-0.00234584859572351,
0.019262902438640594,
-0.01654282957315445,
-0.008036188781261444,
0.016927745193243027,
0.0035839946940541267,
-0.04601883515715599,
-0.006654768250882626,
0.05084311217069626,
0.014079367741942406,
-0.03667820617556572,
0.09648558497428894,
0.07445129007101059,
0.046634700149297714,
-0.06993494182825089,
0.011761318892240524,
-0.010811859741806984,
0.04967981204390526,
0.05327235907316208,
-0.020409096032381058,
-0.08040465414524078,
-0.008600731380283833,
-0.033633094280958176,
0.01706460490822792,
-0.024754369631409645,
0.02980104461312294,
-0.007959205657243729,
0.04201570898294449,
-0.04030496999621391,
0.049371879547834396,
-0.05296442657709122,
0.06555545330047607,
-0.036541350185871124,
0.06890849769115448,
-0.04358958825469017,
0.027183616533875465,
-0.10175465792417526,
-0.04270000383257866,
0.026927005499601364,
0.05549632012844086,
-0.0312722772359848,
0.04044182971119881,
0.03517276048660278,
0.00509799737483263,
-0.020802564918994904,
-0.01638031005859375,
-0.016927745193243027,
-0.037499360740184784,
-0.007321955636143684,
0.005149319302290678,
-0.014541267417371273,
0.006244190968573093,
-0.037122998386621475,
0.014096475206315517,
-0.011496154591441154,
0.012898959219455719,
0.05724127218127251,
0.05860986188054085,
0.010101904161274433,
0.025558415800333023,
-0.022376444190740585,
-0.037909939885139465,
-0.06825841963291168,
-0.024703046306967735,
-0.02519915997982025,
0.046942632645368576,
-0.052177488803863525,
0.045950405299663544,
-0.029287822544574738,
-0.03681506589055061,
0.002326602814719081,
-0.023214705288410187,
0.015122917480766773,
0.016790887340903282,
-0.011761318892240524,
-0.009580128826200962,
-0.020888103172183037,
0.003690915647894144,
0.010007813572883606,
0.021726364269852638,
0.0156361386179924,
-0.038012582808732986,
-0.0400654673576355,
-0.004661759361624718,
0.017791667953133583,
0.004028786439448595,
0.031682856380939484,
-0.009323518723249435,
0.00995649117976427,
0.054606735706329346,
0.005187810864299536,
-0.0527249239385128,
-0.026773039251565933,
0.027919232845306396,
0.015131471678614616,
0.0684979185461998,
0.0394153892993927,
-0.06045745685696602,
0.05019303411245346,
-0.005512850824743509,
0.0049269236624240875,
0.056522760540246964,
0.03390681371092796,
0.0057908459566533566,
0.01750084199011326,
0.028671957552433014,
-0.038286302238702774,
0.03524119034409523,
0.04995352774858475,
0.060696959495544434,
-0.025558415800333023,
0.03221318498253822,
-0.025507092475891113,
0.05231434851884842,
0.011881070211529732,
0.013343751430511475,
0.03081037849187851,
0.005594111047685146,
-0.009126783348619938,
-0.016867870464920998,
-0.0040031252428889275,
0.03845737501978874,
0.002658058190718293,
0.041297197341918945,
-0.0035048730205744505,
-0.015268330462276936,
0.04814014956355095,
-0.04649784043431282,
-0.025507092475891113,
0.01922868750989437,
-0.027713945135474205,
-0.007356170564889908,
-0.038286302238702774,
0.041297197341918945,
0.025883454829454422,
0.022119833156466484,
-0.010846074670553207,
-0.009255088865756989,
-0.06220240890979767,
-0.015465064905583858,
0.0010200270917266607,
-0.002064645988866687,
-0.03517276048660278,
-0.003983879461884499,
-0.04636098071932793,
-0.07055080682039261,
0.02499387226998806,
0.02150396816432476,
0.012419953010976315,
-0.07178253680467606,
0.04793485999107361,
-0.03869687765836716,
-0.030451124534010887,
-0.0052476865239441395,
0.03650713339447975,
0.0585414320230484,
0.0370887853205204,
0.06774519383907318,
-0.05375136807560921,
0.0032375704031437635,
0.006996915675699711,
0.0024955379776656628,
-0.03063930571079254,
-0.0036524240858852863,
-0.032418470829725266,
0.03705456852912903,
-0.001536455936729908,
0.007736809551715851,
0.02276991307735443,
0.07335641235113144,
0.022633055225014687,
0.03520697355270386,
0.039073240011930466,
0.03637027367949486,
0.047421637922525406,
-0.01265945564955473,
0.028312701731920242,
-0.024600403383374214,
-0.01626911200582981,
-0.006355389021337032,
-0.05050096660852432,
-0.0018786033615469933,
-0.003919726703315973,
-0.006278405897319317,
0.017774561420083046,
0.01727844774723053,
-0.008639223873615265,
0.02218826301395893,
0.04389752075076103,
0.03958646208047867,
0.03736250102519989,
0.10291795432567596,
0.04817436262965202,
0.02251330390572548,
0.008767528459429741,
-0.0023693712428212166,
0.014335978776216507,
-0.03028004989027977,
0.007381831295788288,
0.07274054735898972,
-0.0653843805193901,
0.02757708542048931,
-0.02309495396912098,
-0.04146827384829521,
-0.042905293405056,
-0.02906542643904686,
0.02916807122528553,
-0.038388945162296295,
-0.06045745685696602,
0.06647925078868866,
-0.006081670988351107,
-0.002182259224355221,
0.01117966789752245,
-0.036164987832307816,
0.016833655536174774,
0.03630184754729271,
0.10476554930210114,
-0.00875042099505663,
-0.042905293405056,
0.006081670988351107,
-0.015362421050667763,
0.007112390361726284,
0.03378706052899361,
0.014738001860678196,
0.031084096059203148,
-0.010726323351264,
0.013112801127135754,
0.015242669731378555,
0.06562388688325882,
-0.008297075517475605,
0.0006655837059952319,
-0.07404071092605591,
0.019365547224879265,
-0.03630184754729271,
-0.0021159681491553783,
0.052177488803863525,
0.012796315364539623,
-0.06374207139015198,
0.009725541807711124,
0.0009585475199855864,
-0.06545280665159225,
-0.04926923289895058,
-0.006710367277264595,
-0.03554912284016609,
0.022804128006100655,
0.024292469024658203,
-0.030143192037940025,
0.02165793441236019,
0.009366286918520927,
-0.027337582781910896,
-0.014421515166759491,
-0.10045449435710907,
0.005414483603090048,
0.038388945162296295,
-0.05306706950068474,
-0.031135419383645058,
0.016833655536174774,
-0.022923879325389862,
-0.013925401493906975,
0.0075272442772984505,
-0.016209235414862633,
0.03968910500407219,
-0.031101204454898834,
-0.011615905910730362,
0.011290865950286388,
-0.0004322284657973796,
0.016303326934576035,
0.004674589727073908,
-0.03323962539434433,
-0.05385401099920273,
0.043418511748313904,
-0.016790887340903282,
0.03181971237063408,
-0.032367151230573654,
-0.0037550684064626694,
-0.025336019694805145,
0.014378746971487999,
0.06405000388622284,
-0.082457534968853,
0.06795048713684082,
-0.04379487410187721,
-0.02921939268708229,
0.05115104466676712,
0.024429328739643097,
-0.029681291431188583,
0.00995649117976427,
-0.05163005366921425,
0.05583846569061279,
-0.03667820617556572,
0.07958350330591202,
-0.04571090266108513,
0.03931274265050888,
-0.048858657479286194,
0.0019791091326624155,
0.004606160335242748,
-0.037328287959098816,
-0.00269441120326519,
0.02752576395869255,
-0.015601924620568752,
0.04379487410187721,
-0.025438664481043816,
0.06271562725305557,
0.036643993109464645,
0.012898959219455719,
-0.06582917273044586,
-0.03530961647629738,
0.051595836877822876,
-0.05293021351099014,
0.022701483219861984,
-0.023745033890008926,
-0.012821976095438004,
-0.03835473209619522,
-0.03835473209619522,
0.055462103337049484,
-0.021230250597000122,
-0.025934778153896332,
0.034847717732191086,
0.029133856296539307,
-0.008938602171838284,
0.01780877448618412,
-0.002940329723060131,
-0.020597277209162712,
-0.05744655802845955,
0.019194472581148148,
-0.025079408660531044,
-0.014438622631132603,
0.02087099477648735,
0.05409351363778114,
0.09573286026716232,
-0.023556852713227272,
0.03000633232295513,
-0.06880585104227066,
-0.029356252402067184,
0.012479828670620918,
0.05436723306775093,
-0.048003289848566055,
0.004364518448710442,
0.00874186772853136,
-0.05193798616528511,
-0.0015696014743298292,
-0.03394102677702904,
-0.01928000897169113,
-0.0015535632846876979,
-0.006385326851159334,
0.007783854845911264,
-0.06921643018722534,
-0.006637660786509514,
-0.0834839791059494,
-0.02620849572122097,
0.023471316322684288,
0.03999703750014305,
0.017261339351534843,
0.020956531167030334,
-0.007364724297076464,
0.025643952190876007,
0.017723238095641136,
0.0342489592730999,
-0.0012958835577592254,
-0.0014273964334279299,
-0.015721675008535385,
-0.011384956538677216,
0.010640786029398441,
0.049645595252513885,
-0.029681291431188583,
0.10065978020429611,
-0.013463502749800682,
0.0370887853205204,
-0.005880659446120262,
-0.01099148765206337,
-0.04591618850827217,
0.03323962539434433,
-0.07000336796045303,
-0.01575588993728161,
0.01141061820089817,
-0.029783936217427254,
-0.06661611050367355,
0.018150923773646355,
0.080130934715271,
-0.0370887853205204,
-0.03293169289827347,
0.020049842074513435,
0.05464094877243042,
0.060525886714458466,
0.013309536501765251,
-0.05145897716283798,
-0.03491614758968353,
-0.015003166161477566,
0.01902339980006218,
-0.005529958289116621,
0.034693751484155655,
0.007642718963325024,
-0.090463787317276,
-0.08204696327447891,
0.06904535740613937,
-0.021213142201304436,
0.04064711928367615,
0.01871546544134617,
-0.03397524356842041,
-0.0001814985298551619,
0.04396595060825348,
0.01622634381055832,
-0.0034642431419342756,
-0.00405658595263958,
0.06788205355405807,
0.012240325100719929,
0.03856001794338226,
-0.0026858574710786343,
-0.040031254291534424,
0.018356211483478546,
0.03678085282444954,
-0.025301804766058922,
-0.04116034135222435,
-0.01998141221702099,
-0.029202286154031754,
-0.030057653784751892,
-0.00470452755689621,
-0.012248879298567772,
0.05631747096776962,
0.00834839791059494,
-0.020220914855599403,
-0.0510484017431736,
-0.015020273625850677,
0.045847758650779724,
0.06935328990221024,
-0.048584938049316406,
-0.040612902492284775,
-0.009571575559675694,
0.040510259568691254,
-0.019741907715797424,
-0.02472015470266342,
0.008258583955466747,
-0.03091302327811718,
-0.01981033757328987,
-0.01440440770238638,
-0.04926923289895058,
0.029150962829589844,
0.015182794071733952,
-0.04902973026037216,
0.023864785209298134,
-0.025763703510165215,
0.03982596471905708,
0.02150396816432476,
0.03448846563696861,
0.03599391132593155,
-0.00545725179836154,
0.060423240065574646,
-0.038183655589818954,
0.056522760540246964,
-0.035857055336236954,
0.012488381937146187,
0.0006340420222841203,
-0.02463461644947529,
0.01697051338851452,
0.015182794071733952,
-0.02357395924627781,
-0.02087099477648735,
0.0053717149421572685,
-0.009776863269507885,
-0.02800476923584938,
0.04454759880900383,
0.019297117367386818,
0.0034642431419342756,
-0.05063782259821892,
-0.007488752715289593,
0.01278776116669178,
0.026858575642108917,
-0.029561540111899376,
0.034420035779476166,
-0.039757534861564636,
0.024583294987678528,
-0.00001359902489639353,
-0.02473726123571396,
-0.021948760375380516,
-0.02504519373178482,
0.01397672388702631,
0.03472796827554703,
-0.023368671536445618,
0.054880451411008835,
0.017363984137773514,
0.005384545773267746,
0.027149401605129242,
0.0185443926602602,
-0.015661800280213356,
0.030605090782046318,
0.042905293405056,
0.04632676765322685,
-0.010837520472705364,
0.012608134187757969,
0.013891186565160751,
-0.029082534834742546,
-0.02572948858141899,
-0.01750084199011326,
-0.028774602338671684,
-0.042357854545116425,
0.03520697355270386,
0.004734465386718512,
0.05238277465105057,
0.005910597275942564,
-0.05262228101491928,
-0.04649784043431282,
-0.045197680592536926,
0.033000122755765915,
-0.04687420278787613,
-0.006838672328740358,
-0.0018657728796824813,
0.021589504554867744,
-0.035378046333789825,
-0.00021531233505811542,
-0.049850884824991226,
-0.027149401605129242,
-0.06398157775402069,
0.012385738082230091,
0.02114471234381199,
-0.02886013872921467,
0.01706460490822792,
0.06257876753807068,
0.01679944060742855,
-0.06709511578083038,
-0.039278529584407806,
0.018561499193310738,
0.0527249239385128,
-0.0222909078001976,
-0.0315973162651062,
0.025643952190876007,
-0.02324892021715641,
0.0014968950999900699,
0.016089484095573425,
-0.09491170942783356,
0.032572437077760696,
-0.010640786029398441,
-0.008793190121650696,
0.0028911461122334003,
0.020152484998106956,
-0.020357774570584297,
0.0004030924756079912,
-0.053922440856695175,
-0.07965192943811417,
-0.030947238206863403,
-0.050706252455711365,
-0.044513385742902756,
0.03739671781659126,
-0.007989143021404743,
0.013754327781498432,
0.03561754897236824,
-0.001790928072296083,
-0.013489163480699062,
-0.010580910369753838,
-0.02911674976348877,
0.02911674976348877,
-0.013925401493906975,
-0.0029274991247802973,
0.01871546544134617,
-0.011034255847334862,
-0.024378007277846336,
-0.007946374826133251,
-0.0220342967659235,
0.03787572309374809,
-0.02769683673977852,
0.07814648002386093,
-0.02102496102452278,
0.016927745193243027,
-0.01806538552045822,
0.015661800280213356,
0.09840161353349686,
-0.03756779059767723,
-0.03862844780087471,
-0.0071466052904725075,
-0.019416868686676025,
-0.03445424884557724,
-0.03524119034409523,
-0.0370887853205204,
-0.0077753011137247086,
-0.011872516945004463,
0.034009456634521484,
0.02383057028055191,
-0.0025105068925768137,
-0.020648598670959473,
-0.03599391132593155,
-0.04054447263479233,
0.004101492930203676,
0.029185177758336067,
-0.041194554418325424,
0.02673882432281971,
-0.04242628440260887,
0.03065641224384308,
-0.009066907688975334,
0.01839042641222477,
-0.0028847306966781616,
0.028124520555138588,
0.007005469407886267,
0.011932392604649067,
-0.02463461644947529,
0.03245268762111664,
-0.011205329559743404,
0.004144261125475168,
0.027440225705504417,
-0.0020486079156398773,
-0.01075198408216238,
-0.046053048223257065,
-0.02557552233338356,
-0.04447916895151138,
-0.07363013178110123,
-0.025592630729079247,
0.046839985996484756,
-0.0028483776841312647,
-0.020597277209162712,
0.00874186772853136,
0.0661713182926178,
0.0550515279173851,
-0.023163383826613426,
0.015559155493974686,
-0.008143109269440174,
0.04331586882472038,
-0.007839453406631947,
-0.022684376686811447,
-0.015413743443787098,
0.012650902383029461,
0.007685487158596516,
-0.05416194349527359,
-0.021452646702528,
0.026396676898002625,
0.0007500514038838446,
-0.0019117488991469145,
-0.04899551719427109,
0.043418511748313904,
-0.028261380270123482,
-0.027559978887438774,
0.03609655797481537,
0.013129908591508865,
0.020939424633979797,
-0.07862548530101776,
-0.018783895298838615,
-0.02352263778448105,
0.021692149341106415,
0.036062341183423996,
0.0019245794974267483,
-0.06097067892551422,
0.04482131823897362,
0.018270675092935562,
-0.03948381543159485,
-0.0545383058488369,
-0.04400016367435455,
0.056728050112724304,
-0.04875601455569267,
-0.019211579114198685,
-0.048961300402879715,
-0.04157091677188873,
-0.0038534358609467745,
0.01869835890829563,
-0.01933133229613304,
0.031785499304533005,
0.023317350074648857,
-0.0016925607342272997,
-0.03534383326768875,
-0.06945593655109406,
0.02155528962612152,
-0.04259735718369484,
0.02821005880832672,
0.014626803807914257,
0.007240695878863335,
-0.005093720275908709,
-0.0332738421857357,
0.08149952441453934,
-0.012385738082230091,
-0.0024335237685590982,
-0.008673437871038914,
0.0026644733734428883,
-0.023967429995536804,
-0.040339186787605286,
-0.08293654769659042,
-0.0653843805193901,
0.017723238095641136,
-0.027234937995672226,
0.05077468231320381,
0.042357854545116425,
-0.008228646591305733,
0.0016925607342272997,
0.01519134733825922,
0.00417419895529747,
-0.03402656689286232,
0.09443269670009613,
-0.020682813599705696,
0.051287904381752014,
-0.014780770055949688,
0.03736250102519989,
0.0005693547427654266,
0.02525048330426216,
0.0033316609915345907,
-0.03281194344162941,
-0.003207632340490818,
0.029082534834742546,
-0.055291030555963516,
-0.04331586882472038,
0.08416827768087387,
0.039244312793016434,
0.012214664369821548,
0.049748241901397705
]
|
32,307 | bqplot.marks | on_click | null | def on_click(self, callback, remove=False):
self._click_handlers.register_callback(callback, remove=remove)
| (self, callback, remove=False) | [
-0.0009624591912142932,
0.0075949751771986485,
0.0041988305747509,
0.03699333220720291,
-0.015268473885953426,
0.018566465005278587,
0.028879228979349136,
0.10776925086975098,
0.01166511420160532,
0.0006865360192023218,
0.025249693542718887,
0.009597326628863811,
0.018653713166713715,
-0.07098531723022461,
-0.033660441637039185,
0.0465906597673893,
0.036783937364816666,
0.01074900571256876,
-0.022038951516151428,
-0.006914437748491764,
-0.01351478137075901,
0.05022019147872925,
-0.037551723420619965,
-0.024289961904287338,
-0.0028421173337846994,
0.054198719561100006,
-0.05437321960926056,
0.020398681983351707,
0.054233621805906296,
0.006883900612592697,
-0.018880559131503105,
-0.018269820138812065,
-0.034742321819067,
-0.012415450997650623,
-0.0584215447306633,
0.034498028457164764,
0.007403028663247824,
0.03762152045965195,
0.04264703020453453,
0.0039479914121329784,
-0.005322153680026531,
-0.01592283695936203,
0.03242151439189911,
-0.016926193609833717,
0.03866850212216377,
0.07182290405035019,
-0.003561916993930936,
-0.007987593300640583,
0.01714431494474411,
-0.0336080938577652,
-0.009684574790298939,
0.026471171528100967,
0.0005992876249365509,
0.03657453879714012,
-0.05112757533788681,
0.022353045642375946,
0.03866850212216377,
0.017118141055107117,
0.0221436507999897,
0.027884596958756447,
0.03214231878519058,
0.04222823679447174,
0.01412552036345005,
0.006801014766097069,
0.042018841952085495,
-0.00003278632357250899,
-0.008319137617945671,
0.01433491613715887,
0.04146045073866844,
-0.010731556452810764,
0.03640004247426987,
0.0008392207673750818,
0.024150364100933075,
-0.0037756755482405424,
0.028896678239107132,
0.019334251061081886,
0.010208065621554852,
-0.07705780863761902,
0.01950874738395214,
0.029699362814426422,
0.02523224428296089,
-0.04704435169696808,
0.08864440023899078,
0.07280008494853973,
-0.0020841467194259167,
-0.06459873169660568,
0.03268326073884964,
-0.04917321354150772,
0.033852387219667435,
0.07321887463331223,
-0.053465835750103,
-0.0786631777882576,
0.008528533391654491,
-0.012232229113578796,
-0.01851411536335945,
-0.037516821175813675,
0.01607988402247429,
-0.029123524203896523,
0.048545025289058685,
-0.018880559131503105,
0.06089939922094345,
-0.03660943731665611,
0.07377726584672928,
-0.0057714832946658134,
0.04299602285027504,
-0.0259651318192482,
0.018374517560005188,
-0.04030877351760864,
-0.032020170241594315,
0.039506085216999054,
0.044112805277109146,
0.00878155417740345,
0.04997589811682701,
0.04983630031347275,
-0.014701359905302525,
0.010731556452810764,
-0.01802552491426468,
-0.027134260162711143,
-0.044880591332912445,
-0.01607115939259529,
-0.0002571101940702647,
-0.02317318134009838,
-0.021323515102267265,
-0.05838664621114731,
0.0009128366364166141,
-0.0160362608730793,
0.0010633402271196246,
0.038389306515455246,
0.06815847009420395,
-0.0059241680428385735,
0.05391952767968178,
-0.02641882374882698,
-0.01129867136478424,
-0.043275218456983566,
-0.026698017492890358,
-0.004794300999492407,
0.03229936584830284,
-0.051685966551303864,
0.0031431245151907206,
-0.0014046996366232634,
-0.04536918178200722,
-0.01473625935614109,
-0.03332889825105667,
0.05032489076256752,
-0.0007176182698458433,
-0.023539625108242035,
-0.05922422930598259,
-0.01672552339732647,
0.028844328597187996,
0.009955044835805893,
0.011804712004959583,
-0.034114133566617966,
0.0023404390085488558,
-0.03496916964650154,
-0.01525102462619543,
0.030536947771906853,
0.025528889149427414,
0.03233426436781883,
0.0026807079557329416,
0.011638939380645752,
0.06931015104055405,
0.008545983582735062,
-0.022004052996635437,
0.004192286636680365,
0.009265782311558723,
0.04299602285027504,
0.059887319803237915,
0.06459873169660568,
-0.06903095543384552,
0.07859338074922562,
-0.0029359094332903624,
0.02504029870033264,
0.04599737003445625,
0.04006447643041611,
0.002887922804802656,
0.0033721516374498606,
0.03940138965845108,
-0.04379870742559433,
0.038773201406002045,
-0.00598524184897542,
0.03486447036266327,
-0.042402733117341995,
0.046102069318294525,
-0.028320837765932083,
0.005941617768257856,
-0.0041530248709023,
0.018269820138812065,
0.007778197061270475,
-0.005692959763109684,
-0.0234872754663229,
-0.004480206407606602,
-0.03058929741382599,
0.019369149580597878,
0.01992754079401493,
0.029420169070363045,
-0.013549679890275002,
-0.028844328597187996,
0.05008059740066528,
-0.05025509372353554,
-0.04955710470676422,
0.0046983277425169945,
0.0007830546237528324,
-0.00824933871626854,
-0.029716813936829567,
0.03465507552027702,
0.03605104982852936,
0.020573178306221962,
-0.0000673448812449351,
0.005889268592000008,
-0.05105777829885483,
0.03214231878519058,
0.014579211361706257,
0.016289280727505684,
-0.004798663314431906,
-0.016751697286963463,
-0.008877526968717575,
-0.06082960218191147,
-0.010417462326586246,
0.015975186601281166,
0.01924700289964676,
-0.026680568233132362,
0.04557857662439346,
-0.012563773430883884,
0.01902015693485737,
0.007250343915075064,
0.035911452025175095,
0.06962424516677856,
-0.0059067183174192905,
0.06976383924484253,
-0.04257722944021225,
0.002874835627153516,
0.040029577910900116,
-0.003937085159122944,
-0.020014788955450058,
-0.05220945551991463,
-0.07894237339496613,
0.02493559941649437,
0.005326516460627317,
-0.04435709863901138,
0.010504710488021374,
0.045334283262491226,
0.033887289464473724,
0.0012160249752923846,
0.06421484053134918,
0.027744999155402184,
0.06037591025233269,
-0.04296112433075905,
0.040797363966703415,
-0.03313695266842842,
-0.025302043184638023,
0.017510758712887764,
-0.04906851425766945,
-0.0006401853170245886,
-0.00320637971162796,
0.008201352320611477,
0.000820680521428585,
-0.008615781553089619,
-0.012738269753754139,
0.026209427043795586,
0.043624211102724075,
0.04739334434270859,
0.023574523627758026,
0.07545243948698044,
0.02249264344573021,
0.03640004247426987,
-0.026593320071697235,
-0.000780873408075422,
0.021585259586572647,
-0.009021487087011337,
0.012938941828906536,
0.10113837569952011,
-0.05433831736445427,
-0.0009351940243504941,
-0.021393314003944397,
-0.03277050703763962,
-0.03926179185509682,
-0.027814798057079315,
0.001513760187663138,
-0.05405912548303604,
-0.04819602891802788,
0.05067388340830803,
-0.021829556673765182,
-0.018200021237134933,
0.039575885981321335,
-0.058630939573049545,
0.039994679391384125,
0.03573695570230484,
0.10085918009281158,
0.00005616617272607982,
-0.03100809082388878,
0.01806042343378067,
-0.021201366558670998,
-0.00537450285628438,
0.043659113347530365,
-0.00037407761556096375,
0.027134260162711143,
-0.012729545123875141,
0.023347677662968636,
0.033852387219667435,
0.04254233092069626,
-0.029908759519457817,
-0.04550877958536148,
-0.029228221625089645,
-0.006862088572233915,
-0.02104431949555874,
-0.02535439282655716,
0.07929136604070663,
-0.004597992170602083,
-0.04557857662439346,
0.006866450887173414,
-0.00012317023356445134,
-0.024307411164045334,
-0.0668322965502739,
0.01714431494474411,
0.018915457651019096,
0.03978528082370758,
0.0053439661860466,
-0.028530234470963478,
0.032700709998607635,
0.011394644156098366,
-0.026453722268342972,
-0.03727252781391144,
-0.10441891103982925,
-0.01648995280265808,
0.007782559376209974,
-0.07182290405035019,
-0.03776111826300621,
-0.004338427912443876,
-0.022841637954115868,
-0.014151694253087044,
0.017467133700847626,
-0.01657720096409321,
0.047288645058870316,
-0.013628204353153706,
-0.040029577910900116,
-0.003217285731807351,
-0.024830901995301247,
0.009335581213235855,
0.0005060408730059862,
-0.003097319044172764,
-0.038284607231616974,
0.034428227692842484,
-0.016097335144877434,
0.01905505545437336,
-0.06955444067716599,
0.03050204925239086,
-0.03409668430685997,
0.03303225338459015,
0.05081348121166229,
-0.024761103093624115,
0.06609940528869629,
-0.07314907759428024,
-0.010888603515923023,
0.030728895217180252,
0.003468124894425273,
-0.021620159968733788,
0.019979888573288918,
-0.011717463843524456,
0.03524836525321007,
-0.04756784066557884,
0.05391952767968178,
-0.03640004247426987,
0.044008105993270874,
-0.06801886856555939,
0.0035248363856226206,
-0.008960412815213203,
-0.018688611686229706,
-0.011385919526219368,
0.03734232485294342,
-0.02352217584848404,
0.03650474175810814,
-0.05088328197598457,
0.06857725977897644,
0.05119737610220909,
0.01691746897995472,
-0.03329399973154068,
-0.0009433735976926982,
0.04955710470676422,
-0.08969137817621231,
-0.030379900708794594,
-0.030519498512148857,
0.00011376376642147079,
-0.029489967972040176,
-0.032892655581235886,
0.06917054951190948,
-0.025825534015893936,
-0.012895316816866398,
0.054198719561100006,
0.00481175072491169,
-0.0035401047207415104,
0.012380551546812057,
-0.019002707675099373,
-0.029001375660300255,
-0.02432486042380333,
-0.010085918009281158,
-0.030728895217180252,
0.000667995773255825,
0.01160404086112976,
0.023051034659147263,
0.07133430987596512,
-0.02130606584250927,
0.03240406513214111,
-0.046869855374097824,
-0.013689277693629265,
0.016393978148698807,
0.06424973905086517,
-0.057479262351989746,
0.03887789696455002,
-0.01443088985979557,
-0.09415850043296814,
0.003516111522912979,
0.010836253874003887,
-0.02744835428893566,
-0.05678127333521843,
-0.003180205123499036,
0.01580069027841091,
-0.07754640281200409,
0.032700709998607635,
-0.0732886791229248,
-0.04718394950032234,
-0.002938090590760112,
0.0343758799135685,
0.0014068807940930128,
0.04020407423377037,
0.008799003437161446,
0.01771143078804016,
0.02928057126700878,
0.047358445823192596,
0.0019009250681847334,
0.029751712456345558,
-0.009824172593653202,
0.01158659067004919,
-0.0037407760974019766,
0.004013427533209324,
-0.022004052996635437,
0.07580143213272095,
-0.04833562672138214,
0.0017907739384099841,
-0.03859870135784149,
-0.0020841467194259167,
-0.026069829240441322,
0.043205421417951584,
-0.06585510820150375,
-0.044391997158527374,
0.02095707133412361,
-0.012206054292619228,
-0.06501752883195877,
0.028739631175994873,
0.07538264244794846,
-0.07112491875886917,
0.0022575529292225838,
0.018130222335457802,
0.045334283262491226,
0.02886177971959114,
0.03341614827513695,
-0.08424708247184753,
-0.052977241575717926,
-0.05147657170891762,
0.02046848088502884,
0.0033939636778086424,
0.0035815478768199682,
0.011246321722865105,
-0.08326989412307739,
-0.09443769603967667,
0.04498528689146042,
-0.004085407592356205,
0.010260414332151413,
0.038808099925518036,
-0.0507785826921463,
-0.007494639605283737,
0.05681617558002472,
-0.021253716200590134,
-0.014073170721530914,
0.00930068176239729,
0.0442873015999794,
0.007695311214774847,
0.02875708043575287,
-0.031409431248903275,
-0.06131819263100624,
-0.005291617009788752,
0.03500406816601753,
0.004360239952802658,
-0.033817488700151443,
-0.018566465005278587,
-0.023382578045129776,
-0.015757065266370773,
0.012869142927229404,
-0.033660441637039185,
0.03699333220720291,
0.01341880764812231,
-0.017318813130259514,
-0.026174526661634445,
0.002301177242770791,
0.015678541734814644,
0.05887523666024208,
-0.02011948637664318,
-0.012083906680345535,
-0.020171836018562317,
0.019840292632579803,
-0.02217854931950569,
-0.012930216267704964,
0.012790619395673275,
0.02256244234740734,
-0.02734365686774254,
-0.0042359111830592155,
-0.02821614034473896,
0.031217485666275024,
0.010277864523231983,
-0.07189270108938217,
-0.0035357424058020115,
-0.007800009101629257,
0.03137453272938728,
0.01637652888894081,
0.041949041187763214,
0.06159738823771477,
0.007987593300640583,
0.04554367810487747,
-0.030153054744005203,
0.002999164629727602,
-0.00977182388305664,
0.056571878492832184,
-0.029489967972040176,
-0.04819602891802788,
-0.0366443395614624,
-0.014369815587997437,
-0.04348461329936981,
-0.06494772434234619,
0.018165122717618942,
0.007852357812225819,
-0.04655575752258301,
0.04739334434270859,
0.021637609228491783,
-0.03275305777788162,
-0.051720865070819855,
-0.00008547618926968426,
0.019142303615808487,
0.012921491637825966,
0.008196989074349403,
0.04994099959731102,
-0.026663118973374367,
-0.009353031404316425,
0.008890614844858646,
-0.05402422323822975,
-0.004833562765270472,
-0.022248348221182823,
0.012930216267704964,
0.0053090667352080345,
-0.030554398894309998,
0.0679839700460434,
0.003199836006388068,
-0.026855064556002617,
0.0450550876557827,
0.042856425046920776,
-0.027849696576595306,
0.04344971477985382,
0.01668189838528633,
0.0427517294883728,
-0.01512015238404274,
0.02268459089100361,
0.02847788669168949,
-0.046451061964035034,
0.000796687148977071,
-0.005339603405445814,
-0.01129867136478424,
0.011673838831484318,
0.040727563202381134,
0.04208863899111748,
0.008105378597974777,
0.0389476977288723,
-0.06212087720632553,
-0.009963770397007465,
-0.017423510551452637,
0.006002691574394703,
-0.04470609128475189,
-0.012022833339869976,
0.011080550029873848,
0.03275305777788162,
-0.045264482498168945,
-0.0006134654977358878,
-0.04599737003445625,
-0.04173964634537697,
-0.04495038837194443,
0.020102037116885185,
0.03824970871210098,
-0.0439034067094326,
0.01555639412254095,
0.04990609735250473,
0.02011948637664318,
-0.059468526393175125,
-0.021934254094958305,
0.009204708971083164,
-0.019404049962759018,
-0.05552489683032036,
-0.02565103769302368,
0.044426899403333664,
-0.025528889149427414,
-0.020677875727415085,
0.015155050903558731,
-0.09827662259340286,
0.01799062453210354,
-0.002857385901734233,
0.001874750480055809,
-0.0034637623466551304,
0.01973559334874153,
-0.0006101936451159418,
-0.008271150290966034,
-0.08696922659873962,
-0.04819602891802788,
-0.05482691153883934,
0.011333570815622807,
-0.0477423369884491,
0.03622554615139961,
0.008127191103994846,
-0.003186748595908284,
0.038773201406002045,
0.0027723186649382114,
0.028495335951447487,
-0.007852357812225819,
-0.009588601998984814,
0.034306079149246216,
-0.010181890800595284,
0.0039807092398405075,
-0.003585910191759467,
0.003173661418259144,
-0.05304704234004021,
-0.02593023143708706,
-0.009675850160419941,
0.05189536139369011,
-0.003982890397310257,
0.08843500167131424,
-0.03008325770497322,
-0.010565783828496933,
-0.012284577824175358,
-0.008807728067040443,
0.11084039509296417,
-0.020991971716284752,
-0.023853719234466553,
0.01245035044848919,
0.009632226079702377,
-0.022126199677586555,
0.0004964980762451887,
-0.037063129246234894,
-0.005483563523739576,
-0.00519128143787384,
0.04784703627228737,
0.06899605691432953,
-0.0013207229785621166,
0.0023426201660186052,
0.023051034659147263,
-0.044112805277109146,
-0.011246321722865105,
0.023155732080340385,
-0.03814500942826271,
0.027238957583904266,
0.007481552194803953,
-0.0005300341872498393,
-0.009946320205926895,
0.025406740605831146,
0.000925378582905978,
0.012912767007946968,
-0.008109740912914276,
-0.007119471672922373,
0.010356388054788113,
0.035457760095596313,
0.00710202194750309,
-0.009632226079702377,
0.029612114652991295,
-0.009387930855154991,
-0.051755767315626144,
-0.041146356612443924,
-0.02329532988369465,
-0.029455067589879036,
-0.02069532684981823,
0.0013556224294006824,
0.04502018541097641,
-0.020485930144786835,
-0.023312779143452644,
0.025214795023202896,
0.015818139538168907,
0.05632758140563965,
-0.05831684544682503,
0.03563225641846657,
-0.031147686764597893,
0.013087263330817223,
-0.020991971716284752,
-0.0370282307267189,
-0.005993966944515705,
0.01433491613715887,
0.03100809082388878,
-0.06435443460941315,
-0.019491298124194145,
-0.017973175272345543,
-0.01319196168333292,
0.0018845659215003252,
-0.05587388947606087,
0.02340002730488777,
-0.021201366558670998,
-0.09129675477743149,
0.050953079015016556,
0.030833592638373375,
0.07901217043399811,
-0.07698801159858704,
-0.004707052372395992,
-0.05161616951227188,
-0.014439614489674568,
0.011429543606936932,
-0.01851411536335945,
-0.07384706288576126,
0.06763497740030289,
0.015940288081765175,
-0.03165372833609581,
-0.04575307294726372,
-0.0439034067094326,
0.01129867136478424,
-0.026855064556002617,
-0.001586830709129572,
-0.04058796539902687,
-0.008057392202317715,
-0.010190616361796856,
0.02622687630355358,
-0.01730136200785637,
-0.017467133700847626,
0.027744999155402184,
0.003950172569602728,
-0.03353829309344292,
-0.03650474175810814,
0.012493974529206753,
-0.056606777012348175,
0.033468496054410934,
-0.007695311214774847,
0.0003866195911541581,
-0.022579891607165337,
-0.05468731373548508,
0.07314907759428024,
-0.029804062098264694,
-0.03133963420987129,
-0.03866850212216377,
0.02031143382191658,
-0.0017340624472126365,
-0.05144166946411133,
-0.05276784673333168,
-0.04006447643041611,
0.028949027881026268,
-0.02718660980463028,
0.025406740605831146,
0.0295946653932333,
-0.013959747739136219,
0.01698726788163185,
0.012485249899327755,
-0.0021517642308026552,
-0.04470609128475189,
0.0748242512345314,
-0.02538929134607315,
0.057898055762052536,
0.0014679547166451812,
0.02943761833012104,
-0.003902185708284378,
0.06075980141758919,
-0.0013839781749993563,
-0.03517856448888779,
-0.009719474241137505,
0.04666045680642128,
-0.06334235519170761,
-0.06142289191484451,
0.08885379880666733,
0.05426852032542229,
0.022387946024537086,
0.06442423909902573
]
|
32,308 | bqplot.marks | on_element_click | null | def on_element_click(self, callback, remove=False):
self._element_click_handlers.register_callback(callback, remove=remove)
| (self, callback, remove=False) | [
0.011236442252993584,
0.007161830551922321,
-0.008011247031390667,
0.044738803058862686,
-0.0181956198066473,
0.017350515350699425,
0.018247360363602638,
0.08016420900821686,
-0.0033394566271454096,
0.00660992506891489,
0.017143551260232925,
-0.026784641668200493,
0.023645682260394096,
-0.08754593878984451,
-0.05650128051638603,
0.051672108471393585,
0.02090340293943882,
0.033666208386421204,
-0.03604630008339882,
-0.019661616533994675,
-0.013176732696592808,
0.01476345956325531,
-0.04232421889901161,
-0.03464929014444351,
0.0012655010214075446,
0.04446284845471382,
-0.04197927936911583,
0.010667289607226849,
0.03197599947452545,
-0.0006397571414709091,
-0.012012558057904243,
-0.021714014932513237,
-0.056259822100400925,
-0.01952364109456539,
-0.045532166957855225,
0.03314879536628723,
0.03797796741127968,
0.042082760483026505,
0.03956469148397446,
0.0291302390396595,
-0.026318971067667007,
-0.0029923601541668177,
0.0544661283493042,
-0.009623844176530838,
0.041530855000019073,
0.07133372873067856,
-0.003740450134500861,
0.0033890418708324432,
0.023490458726882935,
0.002526690252125263,
-0.001866991282440722,
0.028819791972637177,
0.01952364109456539,
0.04335904121398926,
-0.056432291865348816,
0.030423766002058983,
0.03335576131939888,
-0.007700799964368343,
0.020023804157972336,
0.02781946398317814,
0.015384352765977383,
0.02738828770816326,
0.03504597023129463,
-0.0003751229669433087,
0.027112334966659546,
0.013004262931644917,
0.00176027521956712,
0.017729949206113815,
0.05229300260543823,
-0.004089702852070332,
0.02147255651652813,
-0.019903074949979782,
0.029630402103066444,
-0.003923699725419283,
0.029820119962096214,
0.010813889093697071,
0.029940849170088768,
-0.07581795752048492,
0.02321450598537922,
0.034011147916316986,
0.008761492557823658,
-0.016574397683143616,
0.07768063247203827,
0.08250980079174042,
0.01800590194761753,
-0.059881698340177536,
0.0197650995105505,
-0.05387973040342331,
0.028440356254577637,
0.05729464441537857,
-0.059536755084991455,
-0.060295626521110535,
-0.0027013164944946766,
0.0065668076276779175,
-0.011141583323478699,
-0.03087218850851059,
0.012055675499141216,
-0.018626796081662178,
0.04980942979454994,
-0.010149878449738026,
0.05536297336220741,
-0.03102741204202175,
0.07374831289052963,
-0.018109384924173355,
0.04729136452078819,
0.007588694337755442,
0.020248016342520714,
-0.02609476074576378,
-0.0133060859516263,
0.01978234574198723,
0.05563892796635628,
0.03244166821241379,
0.04201377183198929,
0.03659820184111595,
-0.01610010489821434,
0.0099860318005085,
-0.005760509055107832,
-0.010555184446275234,
-0.023887140676379204,
-0.0209206510335207,
0.03739156574010849,
-0.03904728218913078,
-0.02840586192905903,
-0.048981573432683945,
0.0010499131167307496,
-0.03456305339932442,
-0.0184025838971138,
0.054949045181274414,
0.04870561882853508,
-0.0008251627441495657,
0.026387959718704224,
-0.026974359527230263,
-0.019558135420084,
-0.03704662621021271,
-0.027681486681103706,
-0.029216473922133446,
0.012633451260626316,
-0.0752660483121872,
-0.010658666491508484,
0.0009475088445469737,
-0.03715010732412338,
-0.021955473348498344,
-0.024508032947778702,
0.04656698927283287,
0.0030333218164741993,
-0.027077840641140938,
-0.05995068699121475,
-0.031320612877607346,
0.013116368092596531,
0.0021752819884568453,
-0.02147255651652813,
-0.005325021222233772,
-0.01857505366206169,
-0.04066850244998932,
0.005523362196981907,
0.01878201775252819,
0.039737164974212646,
0.03890930488705635,
0.0007739606080576777,
-0.0005206448258832097,
0.0689881294965744,
0.011727982200682163,
-0.018178371712565422,
0.03032028302550316,
0.00646763714030385,
0.04594609513878822,
0.04622204601764679,
0.08257879316806793,
-0.08113004267215729,
0.06450390070676804,
-0.0033890418708324432,
0.02319725975394249,
0.039771657437086105,
0.034804511815309525,
0.0012396305100992322,
0.013857990503311157,
0.027284806594252586,
-0.013375073671340942,
0.029820119962096214,
0.017712702974677086,
0.032648634165525436,
-0.020058298483490944,
0.04366948828101158,
-0.014349531382322311,
-0.013970096595585346,
0.006596989929676056,
0.006441766861826181,
0.01246960461139679,
-0.016789985820651054,
-0.03445957228541374,
-0.01534985937178135,
-0.03437333554029465,
0.027129583060741425,
0.025956783443689346,
0.0011501614935696125,
-0.011529641225934029,
-0.017712702974677086,
0.038426388055086136,
-0.06022663787007332,
-0.026767395436763763,
-0.012271263636648655,
-0.012745557352900505,
-0.000684491591528058,
-0.017152173444628716,
0.016203587874770164,
0.02395612932741642,
0.014453013427555561,
-0.0000856288243085146,
-0.01898898370563984,
-0.031527575105428696,
0.01917869970202446,
0.002664666622877121,
0.010313725098967552,
0.008515722118318081,
0.009071939624845982,
0.005156862549483776,
-0.0719546228647232,
-0.007019542157649994,
0.03252790495753288,
0.015255000442266464,
-0.03570135682821274,
0.029216473922133446,
-0.018299100920557976,
0.006911748554557562,
0.0035442651715129614,
0.029406189918518066,
0.05087874457240105,
-0.005993343889713287,
0.06170988455414772,
-0.02224867232143879,
0.003721047192811966,
0.04339353367686272,
-0.008692504838109016,
-0.031527575105428696,
-0.05232749879360199,
-0.0769907534122467,
0.02204170823097229,
0.016574397683143616,
-0.012478227727115154,
0.009546232409775257,
0.03332126885652542,
0.016738245263695717,
-0.006665978115051985,
0.07202360779047012,
0.02781946398317814,
0.05477657541632652,
-0.03932323306798935,
0.04022008180618286,
-0.05253446102142334,
-0.055466458201408386,
0.0009766132570803165,
-0.042462196201086044,
-0.014668601565063,
0.0006537703447975218,
0.017014198005199432,
-0.019109712913632393,
0.01121919509023428,
-0.018316349014639854,
0.019558135420084,
0.01897173561155796,
0.05560443177819252,
0.0029945161659270525,
0.10272333025932312,
0.005126680247485638,
0.027095088735222816,
-0.036356743425130844,
0.0040056235156953335,
0.029095744714140892,
0.010831136256456375,
0.0184025838971138,
0.06481435149908066,
-0.05881237983703613,
-0.028992261737585068,
-0.010503442957997322,
-0.023490458726882935,
-0.0018756147474050522,
-0.021920979022979736,
0.02645694836974144,
-0.05901934579014778,
0.0034795887768268585,
0.020644698292016983,
-0.016039740294218063,
-0.04636002331972122,
0.06622860580682755,
-0.07650783658027649,
0.04097894951701164,
0.031355105340480804,
0.11320952326059341,
0.0070238541811704636,
-0.010149878449738026,
-0.004691192880272865,
-0.008683880791068077,
-0.011469276621937752,
0.04663597792387009,
-0.007377418223768473,
0.033821430057287216,
-0.008231146261096,
-0.0059243557043373585,
0.053603775799274445,
0.025991277769207954,
-0.00660992506891489,
-0.007153206970542669,
-0.05467309430241585,
-0.02509443275630474,
-0.04684294015169144,
-0.012512722052633762,
0.09009850025177002,
-0.00016263412544503808,
-0.039978623390197754,
0.019627124071121216,
0.00460064597427845,
-0.007674929685890675,
-0.0689881294965744,
0.023128271102905273,
0.085821233689785,
0.04273814707994461,
0.01592763513326645,
-0.05312085896730423,
0.029406189918518066,
0.02048947475850582,
-0.016419176012277603,
-0.029078496620059013,
-0.09051242470741272,
-0.05287940055131912,
-0.007674929685890675,
-0.0816129595041275,
-0.03275211527943611,
-0.01897173561155796,
-0.010003278963267803,
-0.026146501302719116,
0.022697094827890396,
-0.032493408769369125,
0.04011659696698189,
-0.009899796918034554,
-0.02031700499355793,
0.000680179859045893,
-0.012323005124926567,
0.010762148536741734,
0.002308946568518877,
0.034804511815309525,
-0.010425831191241741,
0.05284490808844566,
-0.04197927936911583,
0.030613483861088753,
-0.07098878920078278,
0.02105862647294998,
-0.0359773114323616,
0.041116926819086075,
0.033459242433309555,
0.013590661808848381,
0.06971250474452972,
-0.06433143466711044,
-0.006622860673815012,
0.061433929949998856,
-0.0022744524758309126,
-0.014737589284777641,
0.021938225254416466,
0.03683966025710106,
0.0363912396132946,
-0.02725031226873398,
0.05505253002047539,
-0.038219425827264786,
0.03618427366018295,
-0.07209260016679764,
-0.008317381143569946,
-0.016729621216654778,
-0.005635467823594809,
0.014935930259525776,
0.032320939004421234,
-0.017936913296580315,
0.04397993162274361,
-0.028526591137051582,
0.08140599727630615,
0.013081874698400497,
0.02357669360935688,
-0.036287758499383926,
-0.006118384655565023,
0.024818480014801025,
-0.07623188197612762,
-0.03006157837808132,
-0.022697094827890396,
0.029009509831666946,
-0.028457604348659515,
-0.04529070854187012,
0.043048594146966934,
0.0038331530522555113,
-0.006618548650294542,
0.059502262622117996,
0.016005245968699455,
0.004807610530406237,
-0.021920979022979736,
-0.023697422817349434,
-0.04656698927283287,
-0.03413187712430954,
-0.02012728713452816,
-0.02361118793487549,
0.002528846263885498,
0.025594595819711685,
0.015565446577966213,
0.047463834285736084,
-0.0368051677942276,
0.030044330283999443,
-0.03007882460951805,
0.009416880086064339,
0.003729670774191618,
0.0359773114323616,
-0.07878444343805313,
0.05284490808844566,
-0.0028263574931770563,
-0.08140599727630615,
-0.016574397683143616,
0.04273814707994461,
-0.023317988961935043,
-0.05177559331059456,
-0.012512722052633762,
0.02493920922279358,
-0.06243425980210304,
0.009002950973808765,
-0.07630087435245514,
-0.054155681282281876,
-0.04539418965578079,
0.020213522017002106,
-0.008662322536110878,
0.040530525147914886,
-0.014677224680781364,
0.0024900403805077076,
0.027681486681103706,
0.05619083344936371,
-0.03142409399151802,
0.013875237666070461,
-0.018506066873669624,
0.01560856495052576,
-0.025249656289815903,
-0.0016643386334180832,
0.0023585318122059107,
0.05122368782758713,
-0.041875794529914856,
-0.0014487507287412882,
-0.015539576299488544,
-0.02585330232977867,
-0.02224867232143879,
0.05112020671367645,
-0.03683966025710106,
-0.04197927936911583,
-0.006019214633852243,
0.0016255328664556146,
-0.07367932051420212,
0.04587710648775101,
0.03735707327723503,
-0.055500950664281845,
0.026387959718704224,
-0.014453013427555561,
0.06598714739084244,
0.02262810617685318,
0.011081218719482422,
-0.08071611076593399,
-0.045739129185676575,
-0.03780549392104149,
0.04104793816804886,
0.004100481979548931,
0.00844673439860344,
0.030182307586073875,
-0.06591816246509552,
-0.11038100719451904,
0.027888452634215355,
0.04632553085684776,
0.010900124907493591,
0.018557807430624962,
-0.025042692199349403,
0.016927963122725487,
0.08175093680620193,
-0.016022494062781334,
-0.02452528104186058,
-0.0056958324275910854,
0.04487678036093712,
0.00513530382886529,
0.03276936337351799,
0.019040724262595177,
-0.05170660465955734,
0.00012133557174820453,
0.03149308264255524,
-0.011245065368711948,
-0.03138959780335426,
-0.01574654132127762,
-0.013685520738363266,
-0.01898898370563984,
0.018833760172128677,
-0.025008197873830795,
0.02759525179862976,
0.007993999868631363,
-0.036322250962257385,
-0.053569283336400986,
-0.008399304933845997,
0.05118919163942337,
0.08375158905982971,
-0.05036133527755737,
-0.011279559694230556,
-0.034218113869428635,
0.02224867232143879,
-0.03663269802927971,
-0.01024473737925291,
-0.0017764443764463067,
0.030906682834029198,
-0.023524953052401543,
-0.0009221772779710591,
-0.022886812686920166,
0.02780221588909626,
0.004751557484269142,
-0.0702299177646637,
-0.027077840641140938,
-0.011865958571434021,
0.04853314906358719,
0.0037965031806379557,
0.021938225254416466,
0.06881566345691681,
-0.007317053619772196,
0.025525609031319618,
-0.009261656552553177,
0.008326005190610886,
0.02029975689947605,
0.05470758676528931,
-0.0013258656254038215,
-0.03501147776842117,
-0.01591038703918457,
0.008856351487338543,
-0.025732573121786118,
-0.08761492371559143,
0.004669634159654379,
0.006191684864461422,
-0.041875794529914856,
0.03237267956137657,
0.016220834106206894,
-0.021558791399002075,
-0.03894380107522011,
0.0029858925845474005,
0.008662322536110878,
0.03611528500914574,
-0.018247360363602638,
0.048395175486803055,
-0.01936841756105423,
-0.019678864628076553,
0.0016266107559204102,
-0.03009607270359993,
-0.0181956198066473,
-0.037322577089071274,
0.027526265010237694,
-0.02067919261753559,
-0.028888780623674393,
0.028888780623674393,
-0.0207136869430542,
-0.007368794642388821,
0.052603449672460556,
0.03794347122311592,
0.0061787492595613,
0.05581139773130417,
-0.015004917979240417,
-0.000018223914594273083,
-0.002878098515793681,
0.011003606952726841,
0.028078168630599976,
-0.03963368013501167,
-0.0005519050173461437,
0.005428503733128309,
0.011279559694230556,
0.04908505454659462,
0.03413187712430954,
0.015099776908755302,
-0.02395612932741642,
0.03570135682821274,
-0.06388300657272339,
-0.012167781591415405,
-0.00007040292985038832,
-0.018678536638617516,
-0.07347235828638077,
-0.028509344905614853,
0.02283507212996483,
0.03032028302550316,
-0.06488333642482758,
0.003932323306798935,
-0.060847532004117966,
-0.03966817632317543,
-0.047049906104803085,
0.0001604782446520403,
0.027284806594252586,
-0.01610010489821434,
0.017583349719643593,
0.05422466993331909,
0.029751131311058998,
-0.0685742050409317,
-0.018523313105106354,
0.006752213463187218,
-0.015772411599755287,
-0.05208604037761688,
-0.01722978614270687,
0.033855926245450974,
-0.014694471843540668,
-0.029285460710525513,
0.022541871294379234,
-0.09541058540344238,
-0.0021806717850267887,
-0.0030613483395427465,
-0.015574070625007153,
0.017729949206113815,
0.015142894349992275,
0.007726670708507299,
-0.02302478812634945,
-0.07754266262054443,
-0.04273814707994461,
-0.018126631155610085,
0.017678208649158478,
-0.045532166957855225,
0.03276936337351799,
0.031148141250014305,
0.007054036483168602,
0.048395175486803055,
-0.003977596759796143,
0.03201049193739891,
0.0044454229064285755,
0.021317332983016968,
0.05884687602519989,
0.0019101088400930166,
0.022007213905453682,
-0.01113295927643776,
0.00930477399379015,
-0.04429037868976593,
-0.030423766002058983,
0.0021192291751503944,
0.058191489428281784,
0.011141583323478699,
0.09685933589935303,
-0.009347891435027122,
0.016755491495132446,
-0.009830808266997337,
-0.02143806219100952,
0.09527260810136795,
-0.01665201038122177,
-0.015772411599755287,
0.015599940903484821,
-0.009244409389793873,
-0.028854286298155785,
0.011658994480967522,
-0.03295908123254776,
0.002802642760798335,
-0.009968784637749195,
0.05712217092514038,
0.07747367024421692,
0.018109384924173355,
-0.0009442750597372651,
0.017031444236636162,
-0.020248016342520714,
-0.011822841130197048,
0.03375244140625,
-0.05084425210952759,
0.0009491257951594889,
0.0037512294948101044,
-0.010857007466256618,
-0.014202930964529514,
0.03047550655901432,
-0.017367761582136154,
0.026318971067667007,
0.010037773288786411,
-0.0001945680851349607,
0.009606597013771534,
0.03773650899529457,
-0.01390973199158907,
-0.01651403307914734,
0.03966817632317543,
0.02164502628147602,
-0.07499010115861893,
-0.03545989841222763,
-0.02454252727329731,
-0.036356743425130844,
-0.022748835384845734,
-0.009761820547282696,
0.014039084315299988,
-0.01217640470713377,
-0.024490786716341972,
0.008739933371543884,
-0.018143879249691963,
0.062020327895879745,
-0.016772739589214325,
0.025163421407341957,
-0.04177231341600418,
0.013349203392863274,
-0.021972719579935074,
-0.05208604037761688,
0.001218071673065424,
0.020592957735061646,
0.03542540594935417,
-0.10596577078104019,
-0.018074890598654747,
-0.05312085896730423,
-0.011624500155448914,
-0.0002208428632002324,
-0.048602137714624405,
0.023697422817349434,
-0.03773650899529457,
-0.08037117123603821,
0.08209587633609772,
0.029871860519051552,
0.05708767846226692,
-0.05350029468536377,
-0.00460064597427845,
-0.038219425827264786,
0.026353465393185616,
0.002032994059845805,
-0.03877133131027222,
-0.07264450192451477,
0.0840965285897255,
0.006446078419685364,
-0.035942815244197845,
-0.06160639971494675,
-0.042255230247974396,
-0.03625326231122017,
-0.016324317082762718,
0.0003034399705938995,
-0.03244166821241379,
-0.004535969812422991,
0.012460981495678425,
0.018713030964136124,
-0.006239113863557577,
-0.019851334393024445,
0.025008197873830795,
-0.0019392132526263595,
-0.05008538439869881,
-0.049567971378564835,
0.008752869442105293,
-0.026508688926696777,
0.019834088161587715,
0.0015392976347357035,
0.007144583389163017,
-0.011745229363441467,
-0.04867112636566162,
0.10023975372314453,
-0.022162437438964844,
-0.05236199125647545,
-0.021179355680942535,
0.023352481424808502,
-0.0074119120836257935,
-0.02568083256483078,
-0.021420814096927643,
-0.05943327397108078,
0.023680176585912704,
-0.02361118793487549,
0.050913240760564804,
0.04429037868976593,
-0.020282510668039322,
0.0184025838971138,
0.006773772183805704,
-0.016039740294218063,
-0.03811594098806381,
0.040702998638153076,
-0.027905698865652084,
0.046877436339855194,
0.0209206510335207,
0.021317332983016968,
-0.013487179763615131,
0.07505908608436584,
-0.025042692199349403,
-0.04163433611392975,
-0.011443406343460083,
0.02357669360935688,
-0.0744381919503212,
-0.07837051898241043,
0.08181992173194885,
0.06215830519795418,
0.012918027117848396,
0.06471086293458939
]
|
32,309 | bqplot.marks | on_hover | null | def on_hover(self, callback, remove=False):
self._hover_handlers.register_callback(callback, remove=remove)
| (self, callback, remove=False) | [
-0.028817741200327873,
0.006852161139249802,
-0.0013102878583595157,
0.03983275219798088,
-0.023817166686058044,
0.033285606652498245,
-0.009777754545211792,
0.0554359145462513,
0.010061291977763176,
0.00543447257950902,
0.013669953681528568,
0.0022683015558868647,
0.012767788022756577,
-0.07141713052988052,
-0.02880055643618107,
0.016187425702810287,
-0.01469240803271532,
0.013154430314898491,
0.0151306027546525,
-0.03289037197828293,
0.015379771590232849,
0.05354566499590874,
-0.007552413269877434,
-0.05856342241168022,
-0.007148586679250002,
0.048802852630615234,
-0.03261542692780495,
-0.0013253239449113607,
0.02464200370013714,
0.032546691596508026,
-0.026480702683329582,
-0.015122010372579098,
-0.015414140187203884,
-0.007195842918008566,
-0.027099329978227615,
0.050933681428432465,
-0.016745908185839653,
0.036224089562892914,
0.007715662010014057,
-0.020878685638308525,
-0.031292252242565155,
0.015173562802374363,
0.012973997741937637,
0.01659984327852726,
0.08901365101337433,
0.06935504078865051,
-0.021239550784230232,
-0.009760570712387562,
0.04220415651798248,
-0.057188693434000015,
-0.01907435432076454,
-0.002225341275334358,
0.01940085180103779,
0.03208272159099579,
-0.04794364795088768,
0.004957613535225391,
0.018954064697027206,
-0.010258909314870834,
0.02782106213271618,
-0.007135698571801186,
0.016883380711078644,
0.03945469856262207,
0.009167718701064587,
-0.018988434225320816,
0.049112167209386826,
-0.02778669446706772,
-0.00804645661264658,
-0.03601787984371185,
0.007320427801460028,
0.004833029117435217,
0.028920844197273254,
0.007848839275538921,
0.030776727944612503,
-0.0157148614525795,
0.004506531171500683,
0.01502749789506197,
-0.002708644140511751,
-0.08839502185583115,
0.021377023309469223,
0.01802612468600273,
-0.02362814173102379,
-0.04220415651798248,
0.06193150579929352,
0.083858422935009,
0.029625393450260162,
-0.07499142736196518,
0.06224082037806511,
-0.042719680815935135,
-0.0010718584526330233,
0.03914538770914078,
-0.06213771551847458,
-0.029092686250805855,
0.0011459648376330733,
-0.004949021618813276,
-0.0022554134484380484,
-0.02055218629539013,
0.009777754545211792,
0.012149160727858543,
0.13802272081375122,
-0.02302669733762741,
0.05354566499590874,
-0.009227863512933254,
0.029728498309850693,
0.00973479449748993,
0.042375996708869934,
-0.00929659977555275,
0.03435102105140686,
-0.0036816939245909452,
-0.07464773952960968,
0.036705244332551956,
0.028285034000873566,
-0.05278956517577171,
0.0578073225915432,
0.005842594895511866,
0.03435102105140686,
0.017974572256207466,
0.012870892882347107,
0.020603738725185394,
-0.01000973954796791,
-0.05388934537768364,
-0.02572460100054741,
-0.012235080823302269,
0.0018848812906071544,
-0.06667432188987732,
-0.036155350506305695,
-0.03323405608534813,
0.0338011309504509,
0.028577163815498352,
0.045056719332933426,
0.036189720034599304,
-0.00796483177691698,
0.022476807236671448,
-0.015706269070506096,
-0.021016158163547516,
-0.016977893188595772,
-0.06495590507984161,
-0.0185931995511055,
-0.013730098493397236,
0.048940323293209076,
-0.05670753866434097,
-0.016720132902264595,
-0.008188225328922272,
-0.023679694160819054,
0.022442437708377838,
-0.025638680905103683,
-0.02792416699230671,
-0.04581281915307045,
-0.003271423513069749,
0.061175405979156494,
0.01189999096095562,
0.00985508318990469,
-0.010396381840109825,
-0.010387790389358997,
-0.0026291676331311464,
-0.0016625619027763605,
0.03680834919214249,
-0.007561005186289549,
0.010946273803710938,
-0.00730324350297451,
0.02572460100054741,
0.03979838266968727,
0.0051122703589499,
-0.007294651586562395,
-0.046740759164094925,
-0.0561232790350914,
-0.04375072568655014,
0.07994044572114944,
0.024332689121365547,
-0.0034540046472102404,
0.048596642911434174,
-0.019864823669195175,
-0.023009514436125755,
0.028113191947340965,
0.02366250939667225,
0.022425254806876183,
0.033079396933317184,
0.0228204894810915,
0.0011040786048397422,
-0.01335204765200615,
0.013901939615607262,
0.017562152817845345,
-0.04155116155743599,
0.0008629641379229724,
-0.020363161340355873,
-0.015457100234925747,
-0.011032193899154663,
0.017020853236317635,
0.018438542261719704,
-0.06925193220376968,
0.03897354379296303,
-0.02735709212720394,
-0.057188693434000015,
-0.0412418469786644,
0.03012373298406601,
0.09080079942941666,
0.009631689637899399,
0.02323290705680847,
0.06859894096851349,
-0.027941351756453514,
0.02813037671148777,
-0.009236454963684082,
0.029453551396727562,
-0.0544392392039299,
-0.010026924312114716,
0.01298259012401104,
-0.013154430314898491,
-0.005258335266262293,
0.00194609968457371,
-0.02464200370013714,
-0.07547257840633392,
0.008248369209468365,
0.018954064697027206,
-0.0016561179654672742,
0.03728950396180153,
-0.0003611346473917365,
0.011513348668813705,
-0.09925537556409836,
0.02271738462150097,
0.053133245557546616,
-0.006813496816903353,
-0.04636270925402641,
-0.0314469076693058,
-0.06007562205195427,
-0.008695156313478947,
0.032237377017736435,
0.06767099350690842,
0.020775580778717995,
0.006779128685593605,
0.09011343866586685,
-0.030656440183520317,
0.003307939739897847,
0.03340589627623558,
-0.005799634847790003,
-0.04103563725948334,
0.005709418095648289,
-0.018782224506139755,
0.05351129546761513,
0.003666657954454422,
-0.008832628838717937,
0.015706269070506096,
0.010860352776944637,
-0.02254554256796837,
0.02809600904583931,
-0.0005243836203590035,
0.032065536826848984,
0.04330394044518471,
-0.016548290848731995,
0.03612098470330238,
-0.04515982046723366,
0.02001947909593582,
0.024229584261775017,
-0.052892670035362244,
0.05062436684966087,
0.030415862798690796,
0.03228892758488655,
0.00577385863289237,
-0.020775580778717995,
-0.03507275506854057,
0.012836525216698647,
-0.01727861538529396,
-0.016281938180327415,
0.019108721986413002,
-0.001981541747227311,
0.05406118929386139,
0.05423302948474884,
-0.04330394044518471,
0.024332689121365547,
0.04763433337211609,
-0.02728835493326187,
0.009700425900518894,
0.07279185950756073,
-0.05199909582734108,
-0.036602139472961426,
-0.015663309022784233,
-0.006834976840764284,
-0.0052368552424013615,
-0.02893802896142006,
-0.03986711800098419,
-0.01981327123939991,
-0.015336811542510986,
0.0419292114675045,
0.006353822071105242,
-0.017295800149440765,
-0.016118688508868217,
-0.014993129298090935,
0.026618175208568573,
0.021308287978172302,
0.061484720557928085,
-0.022133124992251396,
-0.05481728911399841,
0.012286633253097534,
0.015388363972306252,
-0.05382061004638672,
0.04354451596736908,
0.04722191393375397,
0.027443012222647667,
-0.006993929855525494,
0.036086615175008774,
0.045640978962183,
0.049318376928567886,
-0.02558712847530842,
-0.06224082037806511,
-0.04399130493402481,
0.003930863458663225,
-0.03438539057970047,
-0.011917175725102425,
0.042857151478528976,
0.025707418099045753,
-0.06048804149031639,
0.0338183157145977,
-0.0017678146250545979,
0.009614505805075169,
-0.08165885508060455,
0.03770192340016365,
-0.010344830341637135,
0.029694128781557083,
0.02833658643066883,
0.003215575125068426,
0.014829880557954311,
0.04378509521484375,
-0.048768483102321625,
-0.033491816371679306,
-0.08433957397937775,
-0.059663206338882446,
0.02572460100054741,
-0.0754038468003273,
-0.05450797453522682,
-0.028749004006385803,
0.026652542874217033,
-0.042650941759347916,
0.0005063940188847482,
-0.09794938564300537,
0.0439569354057312,
-0.04928400740027428,
-0.02505442127585411,
-0.023353194817900658,
0.006972449831664562,
0.03507275506854057,
-0.007792990654706955,
0.014262805692851543,
-0.04742812365293503,
0.07664109766483307,
-0.03529614582657814,
0.004721332341432571,
0.006014436017721891,
0.014666631817817688,
-0.06282507628202438,
0.028766188770532608,
-0.014898616820573807,
-0.00014123183791525662,
0.057257428765296936,
-0.007213027216494083,
-0.015809373930096626,
0.07217323035001755,
0.06375302374362946,
-0.04182610660791397,
-0.010121436789631844,
0.015311035327613354,
0.029591025784611702,
-0.028078824281692505,
0.01198591198772192,
-0.055367179214954376,
0.026188572868704796,
-0.02802727185189724,
0.04096690192818642,
0.025363735854625702,
0.0024336986243724823,
0.005597721319645643,
0.012114792130887508,
-0.013523888774216175,
-0.020981788635253906,
-0.06100356578826904,
0.02431550621986389,
0.00941688846796751,
-0.00442061061039567,
-0.048940323293209076,
-0.0009569397079758346,
0.03959217295050621,
-0.036499034613370895,
-0.020638108253479004,
0.0010058070765808225,
0.018301069736480713,
0.016926340758800507,
-0.024470161646604538,
0.08798260986804962,
0.010619775392115116,
-0.029298895969986916,
0.04574408009648323,
0.028508426621556282,
0.002375702140852809,
0.003660213900730014,
-0.0023885902483016253,
-0.031790591776371,
-0.042925890535116196,
-0.03680834919214249,
0.01876503974199295,
-0.03986711800098419,
-0.003995303995907307,
-0.004025375936180353,
0.030811095610260963,
0.00999255571514368,
0.009030246175825596,
-0.04017643257975578,
-0.016651395708322525,
0.015053274109959602,
0.010654143989086151,
-0.04983389750123024,
0.061519086360931396,
-0.012183529324829578,
0.008759596385061741,
-0.011642229743301868,
-0.02610265277326107,
-0.028766188770532608,
-0.059353891760110855,
0.0017935907235369086,
-0.017802730202674866,
0.0033895643427968025,
0.00885840505361557,
-0.06045367196202278,
-0.04976516216993332,
0.001693708123639226,
-0.036636509001255035,
-0.005348552018404007,
0.04416314512491226,
-0.015328220091760159,
-0.048837218433618546,
-0.026394782587885857,
0.027528932318091393,
-0.02288922481238842,
-0.015869518741965294,
0.07299806922674179,
-0.01287948526442051,
0.06327186524868011,
0.003705322276800871,
0.03928285837173462,
0.036499034613370895,
-0.0010460822377353907,
0.02998625859618187,
-0.021342655643820763,
-0.021806625649333,
0.05667317286133766,
0.042788416147232056,
-0.0018494391115382314,
-0.02373124659061432,
0.02048345096409321,
0.023576589301228523,
-0.04155116155743599,
0.016977893188595772,
0.05595143884420395,
-0.03103449009358883,
-0.016153056174516678,
0.013008365407586098,
0.05000573769211769,
0.07286059856414795,
0.061278510838747025,
-0.0889449194073677,
-0.05426739528775215,
-0.04172300174832344,
-0.010215949267148972,
0.02816474437713623,
-0.023885902017354965,
-0.00515523087233305,
-0.025604313239455223,
-0.01254439540207386,
-0.001338212052360177,
0.02288922481238842,
0.024057744070887566,
0.007144290953874588,
-0.0051423427648842335,
0.0015970475506037474,
0.0639248639345169,
0.019658613950014114,
-0.04515982046723366,
0.006405374500900507,
0.010722880251705647,
-0.0355023555457592,
0.023593774065375328,
0.023576589301228523,
-0.015775006264448166,
0.03369802609086037,
0.036533404141664505,
-0.023920271545648575,
0.0020449082367122173,
-0.03722076490521431,
-0.011453204788267612,
0.0044120182283222675,
0.016084320843219757,
-0.014597895555198193,
0.0029535177163779736,
0.0043411338701844215,
-0.02935044839978218,
-0.059078946709632874,
-0.021617600694298744,
0.031120410189032555,
-0.01683182828128338,
-0.08165885508060455,
0.018438542261719704,
-0.02082713320851326,
0.07822203636169434,
-0.0581510029733181,
-0.028542794287204742,
0.0020867944695055485,
0.02471073903143406,
-0.0034991130232810974,
0.04605339467525482,
0.02156604826450348,
0.03948906809091568,
0.030312757939100266,
-0.06495590507984161,
-0.006633063778281212,
-0.017665257677435875,
0.009683242067694664,
0.021050525829195976,
0.04543476924300194,
0.0035012608859688044,
-0.0399014875292778,
0.07107345014810562,
0.05217093601822853,
0.04223852604627609,
-0.03529614582657814,
0.06564327329397202,
-0.016720132902264595,
-0.022768937051296234,
-0.046637654304504395,
0.012535803020000458,
-0.006486998870968819,
-0.03371521085500717,
0.020139768719673157,
-0.013549664989113808,
-0.03557109460234642,
0.02089586853981018,
0.009391112253069878,
-0.07237944006919861,
-0.0882575511932373,
-0.022133124992251396,
0.03421355038881302,
0.00182151491753757,
0.010112844407558441,
-0.025913627818226814,
-0.016178833320736885,
0.03249513730406761,
-0.03997022286057472,
-0.008162449114024639,
-0.018610382452607155,
-0.012209304608404636,
0.01144461240619421,
-0.03476344048976898,
0.011178258806467056,
0.01102360151708126,
-0.022201860323548317,
0.018850961700081825,
-0.004145664628595114,
-0.009356743656098843,
-0.05564212426543236,
0.04928400740027428,
0.05629511922597885,
0.007672701962292194,
-0.0028847812209278345,
0.007359092123806477,
0.046878233551979065,
-0.04007332772016525,
-0.012750604189932346,
-0.00004641721534426324,
-0.0006154056754894555,
0.021136445924639702,
0.018988434225320816,
-0.022304965183138847,
0.01244129054248333,
0.017802730202674866,
-0.018077675253152847,
0.00995818804949522,
0.055298443883657455,
0.027064962312579155,
-0.04519418999552727,
-0.02201283536851406,
0.019091539084911346,
0.08275864273309708,
-0.0483560636639595,
0.004575267434120178,
-0.07712225615978241,
-0.02830221690237522,
0.020706843584775925,
0.03445412591099739,
0.05461107939481735,
-0.024367058649659157,
-0.005034942179918289,
-0.0010514522437006235,
0.062859445810318,
-0.04137932136654854,
0.006959561724215746,
-0.0011674449779093266,
-0.02691030502319336,
-0.09540613740682602,
0.011857030913233757,
0.03428228572010994,
-0.032976292073726654,
0.03567419573664665,
0.011607861146330833,
-0.06502464413642883,
0.08069654554128647,
-0.02299232967197895,
0.02379998192191124,
0.006585807539522648,
-0.026394782587885857,
0.042650941759347916,
-0.026583807542920113,
-0.014864249154925346,
-0.023885902017354965,
-0.015809373930096626,
-0.02606828324496746,
-0.04515982046723366,
0.048459168523550034,
-0.029780050739645958,
-0.018404174596071243,
0.07341048866510391,
-0.012965405359864235,
0.01943521946668625,
-0.044713035225868225,
-0.0028998174238950014,
0.008149560540914536,
0.008067936636507511,
0.0019407295621931553,
-0.023181354627013206,
-0.0075395251624286175,
-0.016814645379781723,
-0.059525731950998306,
0.016582658514380455,
0.017536377534270287,
-0.0009521067258901894,
0.0463283397257328,
-0.033354341983795166,
-0.010336237959563732,
-0.007496564649045467,
-0.06035057082772255,
0.061312880367040634,
0.014666631817817688,
0.015740638598799706,
-0.0016153056640177965,
-0.025002868846058846,
-0.03479781001806259,
-0.07114218920469284,
-0.016995077952742577,
0.025277815759181976,
-0.06416544318199158,
0.031464092433452606,
0.06945814192295074,
-0.008248369209468365,
0.03507275506854057,
0.000981641816906631,
-0.042547836899757385,
0.027906982228159904,
-0.006310861557722092,
-0.007638333830982447,
0.04110437259078026,
-0.001830106950365007,
-0.04137932136654854,
0.010439342819154263,
-0.023576589301228523,
0.002141568809747696,
-0.00302655017003417,
-0.03204835206270218,
-0.036636509001255035,
0.006315157748758793,
0.07375416904687881,
0.06708673387765884,
-0.013850387185811996,
-0.0010697103571146727,
0.005559057462960482,
-0.03574293479323387,
0.0033616400323808193,
-0.0019160275114700198,
-0.04134495183825493,
-0.05846031755208969,
-0.02799290418624878,
0.05629511922597885,
-0.05447360500693321,
-0.00469985231757164,
-0.003971675876528025,
0.010688511654734612,
0.042547836899757385,
-0.001967579824849963,
0.03581167012453079,
-0.01971016637980938,
-0.003155430778861046,
-0.017630890011787415,
0.04794364795088768,
0.034058891236782074,
0.002399330260232091,
0.05615764856338501,
-0.009038837626576424,
-0.00780158257111907,
-0.01568908616900444,
-0.03124069981276989,
0.012776380404829979,
-0.09526866674423218,
-0.011367283761501312,
-0.038251813501119614,
-0.12131976336240768,
0.055057864636182785,
-0.036636509001255035,
0.03780502453446388,
0.007260283455252647,
0.009184902533888817,
-0.013833202421665192,
0.07052356004714966,
0.029711313545703888,
-0.03306221216917038,
-0.08323979377746582,
0.03997022286057472,
-0.01754496805369854,
-0.07725972682237625,
-0.05622638389468193,
0.006517070811241865,
0.052755195647478104,
0.00041913101449608803,
-0.05168978124856949,
-0.01460648700594902,
-0.010585407726466656,
0.0034046003129333258,
0.03435102105140686,
0.02991752326488495,
0.0008012087782844901,
-0.02015695348381996,
0.03746134415268898,
-0.03271853178739548,
-0.011693782173097134,
-0.007552413269877434,
-0.07890939712524414,
0.012131976895034313,
0.02900676615536213,
-0.00044786068610846996,
0.02883492410182953,
-0.013833202421665192,
0.033594921231269836,
-0.010894721373915672,
-0.016445185989141464,
-0.0023177058901637793,
0.024727923795580864,
0.05007447674870491,
-0.03698018938302994,
-0.0177511777728796,
-0.06743042171001434,
0.046568918973207474,
-0.04134495183825493,
0.09217552840709686,
-0.021016158163547516,
-0.02051781862974167,
0.05265209078788757,
-0.020500633865594864,
0.07059229165315628,
-0.003544221166521311,
0.05148357152938843,
-0.0010519892675802112,
0.0294191837310791,
-0.022373702377080917,
0.009648873470723629,
-0.010035515762865543,
0.023782799020409584,
-0.04526292532682419,
-0.025604313239455223,
0.026480702683329582,
0.051036786288022995,
-0.017733994871377945,
-0.08296484500169754,
0.11052814871072769,
0.02086150087416172,
-0.007556708995252848,
0.014658039435744286
]
|
32,310 | bqplot.marks | on_legend_click | null | def on_legend_click(self, callback, remove=False):
self._legend_click_handlers.register_callback(callback, remove=remove)
| (self, callback, remove=False) | [
-0.0024263192899525166,
0.026446040719747543,
0.004957583267241716,
0.05588090419769287,
-0.08429151028394699,
0.022332213819026947,
0.008538293652236462,
0.1190827488899231,
0.00029069656739011407,
-0.02004861831665039,
0.029115833342075348,
-0.0006800410919822752,
0.06011227145791054,
-0.10403788834810257,
-0.0010095671750605106,
0.02275199070572853,
0.004052960779517889,
0.036369603127241135,
0.008916093967854977,
-0.014599894173443317,
-0.03200390934944153,
-0.04194426164031029,
-0.061623476445674896,
-0.026261338964104652,
0.0032490850426256657,
0.0643436387181282,
-0.03563079237937927,
0.017118563875555992,
0.04923161491751671,
0.011737004853785038,
-0.015447846613824368,
-0.04714951291680336,
-0.07925417274236679,
0.03559721261262894,
-0.04231366515159607,
0.002879680134356022,
-0.005007956642657518,
0.018940404057502747,
0.05561224743723869,
0.02589193359017372,
-0.002548055024817586,
0.002810416743159294,
0.06323542445898056,
-0.010536438785493374,
0.07737356424331665,
0.04348904639482498,
-0.024464687332510948,
0.025975890457630157,
0.0012519891606643796,
-0.06316825747489929,
-0.008366184309124947,
-0.04053380712866783,
0.004174696747213602,
0.044966667890548706,
-0.032709136605262756,
0.011619467288255692,
0.05655255168676376,
0.024313567206263542,
0.011888124980032444,
-0.010847074910998344,
0.04039947688579559,
0.049500271677970886,
-0.017395619302988052,
0.00481066107749939,
0.013516865670681,
0.0022248257882893085,
-0.007249573711305857,
-0.01803368143737316,
0.00955415703356266,
-0.024918047711253166,
0.02715126983821392,
0.030257629230618477,
0.02451506070792675,
-0.02339005470275879,
-0.017210915684700012,
-0.01153551135212183,
0.00760638527572155,
-0.08650793880224228,
0.012887198477983475,
-0.0019477719906717539,
-0.014851761050522327,
-0.007312540430575609,
0.028645681217312813,
0.03054307959973812,
-0.008345195092260838,
-0.05420179292559624,
0.043153222650289536,
0.013248207978904247,
0.009797628968954086,
-0.002197540132328868,
-0.027873288840055466,
-0.08576913177967072,
-0.015682922676205635,
0.013735150918364525,
-0.03244047611951828,
-0.047418173402547836,
0.004928198643028736,
0.0017525749281048775,
0.047921907156705856,
-0.033733393996953964,
0.06279885768890381,
-0.08173925429582596,
0.07784371078014374,
0.022147510200738907,
0.029199788346886635,
-0.04039947688579559,
-0.0019435741705819964,
-0.05205252766609192,
-0.05188461393117905,
0.031013231724500656,
0.006384829990565777,
0.012047640979290009,
0.04926519840955734,
0.0028251088224351406,
-0.02295348420739174,
0.041776351630687714,
-0.01128364447504282,
-0.06904515624046326,
-0.03274271637201309,
-0.01729487255215645,
-0.01244223304092884,
0.002657197415828705,
0.009319080971181393,
-0.01942734606564045,
-0.011938498355448246,
0.027621421962976456,
0.0017504760762676597,
0.07958999276161194,
0.04788832366466522,
-0.02948523685336113,
0.05876898020505905,
-0.0029972181655466557,
-0.006502368021756411,
-0.012240739539265633,
0.00870620459318161,
0.0024892862420529127,
0.006296676583588123,
-0.016581248492002487,
-0.01828554831445217,
0.0031567339319735765,
0.015053254552185535,
-0.010175429284572601,
-0.041709184646606445,
0.05628389120101929,
0.0013632305199280381,
-0.0448659211397171,
-0.06256377696990967,
-0.019595257937908173,
-0.038686782121658325,
0.008378777652978897,
-0.02041802369058132,
-0.0008211915846914053,
-0.012996340170502663,
-0.06041451171040535,
0.0321214459836483,
0.02935090847313404,
-0.0003652072336990386,
0.03239010274410248,
0.01734524592757225,
0.018436668440699577,
0.03430429473519325,
-0.005520086269825697,
0.010670768097043037,
-0.030022554099559784,
-0.013626008294522762,
0.01709337718784809,
0.0803287997841835,
0.05091072991490364,
-0.0735451802611351,
0.062194373458623886,
-0.01317264698445797,
0.014003808610141277,
0.04086962714791298,
0.0691794902086258,
-0.03230614960193634,
0.02439752221107483,
0.031013231724500656,
-0.010242593474686146,
0.03989574313163757,
0.02061951719224453,
0.021022504195570946,
0.009764046408236027,
-0.03452257812023163,
0.0008925538859330118,
0.01993107981979847,
-0.04745175316929817,
-0.03445541486144066,
-0.0024934839457273483,
-0.020770637318491936,
0.011778983287513256,
0.01583404280245304,
-0.013970226049423218,
0.014465564861893654,
-0.00281251547858119,
0.030710991472005844,
-0.043992780148983,
-0.012450628913939,
0.046175628900527954,
-0.05776151269674301,
-0.013626008294522762,
0.026429250836372375,
0.00044391569099389017,
-0.04194426164031029,
-0.007379705086350441,
0.01571650430560112,
0.0422465018928051,
0.0253378264605999,
-0.01499448623508215,
-0.014944112859666348,
-0.025472154840826988,
0.015263143926858902,
0.014482355676591396,
0.006905355490744114,
0.01803368143737316,
-0.01949451118707657,
0.004302728921175003,
-0.05047415941953659,
0.02641245909035206,
0.0008831088780425489,
-0.017017817124724388,
-0.0838213562965393,
0.012769659981131554,
0.032272566109895706,
0.04822414740920067,
0.009638112969696522,
0.0003318873350508511,
0.07603026926517487,
0.02815873734652996,
0.08133626729249954,
-0.05853390693664551,
-0.007018695585429668,
0.005264021456241608,
-0.0017830089200288057,
-0.05436970293521881,
-0.013987017795443535,
-0.02985464222729206,
0.06572051346302032,
0.011140919290482998,
0.036369603127241135,
0.060380931943655014,
0.026748282834887505,
0.04721667990088463,
0.0031987116672098637,
0.047753993421792984,
-0.004751891829073429,
0.05645180493593216,
-0.013600821606814861,
0.02627813071012497,
-0.03166808560490608,
-0.018873238936066628,
-0.03640318661928177,
-0.04043306037783623,
0.018520625308156013,
0.015598966740071774,
0.04197784513235092,
-0.02050197869539261,
0.0152127705514431,
-0.006985113024711609,
0.019511301070451736,
-0.024112073704600334,
0.036873336881399155,
0.04090321063995361,
0.025488946586847305,
0.020854592323303223,
0.024464687332510948,
-0.008042954839766026,
0.05228760093450546,
0.010528042912483215,
-0.009495388716459274,
0.01828554831445217,
0.06709738820791245,
-0.0076945386826992035,
-0.001423048903234303,
-0.019628839567303658,
-0.009747255593538284,
0.025220287963747978,
-0.012677309103310108,
-0.032205402851104736,
0.011451555415987968,
-0.017832187935709953,
0.04909728467464447,
-0.05091072991490364,
-0.04785474017262459,
0.05161595717072487,
-0.07603026926517487,
0.06541827321052551,
0.003396007465198636,
0.062194373458623886,
-0.0011281545739620924,
0.017101773992180824,
0.014834970235824585,
0.004327915608882904,
0.004298530984669924,
0.016488896682858467,
-0.00902523659169674,
-0.005444526206701994,
0.05168312042951584,
0.020518770441412926,
0.002860790118575096,
0.06108615919947624,
-0.021727731451392174,
-0.03613452613353729,
-0.002352858195081353,
0.008714600466191769,
-0.050440575927495956,
-0.054839856922626495,
0.11800811439752579,
-0.019376972690224648,
-0.01065397635102272,
0.011921707540750504,
-0.0008594963583163917,
0.02318856120109558,
-0.030391959473490715,
-0.011678236536681652,
-0.016715576872229576,
0.01524635311216116,
0.021207205951213837,
-0.020602725446224213,
0.002063211053609848,
0.017395619302988052,
-0.03505989536643028,
-0.06615708023309708,
-0.10470953583717346,
-0.09382887929677963,
0.03922409564256668,
-0.042582325637340546,
0.005595646798610687,
-0.03054307959973812,
0.006905355490744114,
-0.023037441074848175,
0.02275199070572853,
-0.03704125061631203,
0.05161595717072487,
-0.01583404280245304,
0.020031826570630074,
0.001472372910939157,
-0.03452257812023163,
-0.007425880525261164,
-0.039627086371183395,
-0.04150769114494324,
-0.06054884195327759,
-0.009092400781810284,
-0.05467194318771362,
0.03526138886809349,
-0.057291362434625626,
0.055981650948524475,
-0.012333090417087078,
0.03205428272485733,
0.026882611215114594,
0.02558969333767891,
0.05222043767571449,
-0.019259434193372726,
-0.043086059391498566,
0.051145803183317184,
0.014012204483151436,
-0.00211358442902565,
0.014776200987398624,
-0.021072877570986748,
0.003505149856209755,
-0.00930229015648365,
0.07381384074687958,
-0.04872788116335869,
0.0025585496332496405,
-0.03358227387070656,
0.03626885637640953,
-0.016891883686184883,
-0.028209110721945763,
-0.009638112969696522,
0.0438920333981514,
-0.05030624940991402,
0.04657861590385437,
-0.011913311667740345,
0.06538468599319458,
0.05349656566977501,
-0.022987067699432373,
-0.020569143816828728,
0.032272566109895706,
0.028830382972955704,
-0.07106009125709534,
-0.048358477652072906,
-0.032591596245765686,
-0.012492606416344643,
-0.08126910775899887,
-0.0075434185564517975,
0.018268758431077003,
-0.018151219934225082,
0.0030832726042717695,
0.005746766924858093,
0.01823517493903637,
-0.009411432780325413,
0.060380931943655014,
-0.054403286427259445,
0.03996290639042854,
-0.006934739649295807,
-0.03475765511393547,
-0.018084054812788963,
-0.011543907225131989,
0.025975890457630157,
0.0009717870852909982,
0.043656956404447556,
-0.03055986948311329,
-0.018906820565462112,
-0.033666230738162994,
-0.04348904639482498,
0.03049270622432232,
0.015162397176027298,
-0.05215327441692352,
0.06478020548820496,
-0.003062283620238304,
-0.05638464167714119,
0.05604881793260574,
-0.03200390934944153,
-0.030257629230618477,
-0.03791438788175583,
-0.0287296362221241,
0.014566311612725258,
-0.06679514795541763,
0.011132524348795414,
-0.029720313847064972,
-0.013844292610883713,
0.0012037146370857954,
-0.012056036852300167,
0.008357788436114788,
0.03653751686215401,
0.010645581409335136,
0.02169414982199669,
-0.03150017559528351,
0.06192571669816971,
-0.003343535354360938,
0.009125983342528343,
0.0011449457379058003,
-0.015489824116230011,
0.0007172963814809918,
0.006896959617733955,
-0.02861209772527218,
0.05564583092927933,
-0.048694297671318054,
0.041776351630687714,
-0.0006280934903770685,
-0.008899303153157234,
0.028141945600509644,
-0.005410944111645222,
-0.03181920573115349,
-0.0744183212518692,
-0.013667985796928406,
0.01357563491910696,
-0.014860156923532486,
0.01716054230928421,
0.07603026926517487,
-0.051448047161102295,
-0.0023339681793004274,
0.028007617220282555,
0.03915693238377571,
0.05420179292559624,
0.017362035810947418,
-0.04382487013936043,
-0.03747781738638878,
-0.09275424480438232,
0.05813091993331909,
0.05819808319211006,
0.018201593309640884,
0.0031777226831763983,
-0.05705628544092178,
-0.0531943254172802,
0.01892361231148243,
0.00706906896084547,
0.04338829964399338,
-0.02501879446208477,
-0.03185278922319412,
-0.006884366273880005,
0.07038845121860504,
-0.014356422238051891,
0.003477864433079958,
0.0011355007300153375,
0.011401182040572166,
0.023557966575026512,
0.019880706444382668,
-0.0058517116121947765,
-0.06679514795541763,
0.011988872662186623,
0.05366447567939758,
0.00003182773070875555,
-0.0017231905367225409,
-0.008462733589112759,
0.025237079709768295,
0.015112023800611496,
-0.033968470990657806,
-0.027621421962976456,
-0.005708986893296242,
0.043086059391498566,
-0.043018896132707596,
-0.05661971494555473,
0.009159565903246403,
0.0024242205545306206,
0.07347802072763443,
-0.0003019781142938882,
0.08355270326137543,
-0.010813492350280285,
0.023272516205906868,
-0.020451605319976807,
-0.021408699452877045,
0.010175429284572601,
-0.027419928461313248,
-0.011468347162008286,
-0.0016938060289248824,
-0.056921955198049545,
0.034237127751111984,
0.024733345955610275,
-0.08550047129392624,
0.000957094831392169,
-0.029451655223965645,
0.043522629886865616,
0.04150769114494324,
0.05661971494555473,
0.005511690862476826,
-0.01020901184529066,
-0.010931030847132206,
-0.0054571195505559444,
0.014742618426680565,
-0.009495388716459274,
0.02678186446428299,
-0.0035828088875859976,
-0.0033813153859227896,
-0.07280637323856354,
-0.02802440896630287,
-0.032977793365716934,
-0.01622023805975914,
0.011174501851201057,
-0.0031756239477545023,
-0.055914487689733505,
0.021391909569501877,
0.020636308938264847,
0.0018596184672787786,
0.013021526858210564,
-0.013936644420027733,
0.0062043252401053905,
0.01619505137205124,
0.023977745324373245,
-0.04795549064874649,
-0.020199738442897797,
0.012769659981131554,
-0.0021765511482954025,
0.012895593419671059,
-0.0388546921312809,
0.020585933700203896,
0.015489824116230011,
0.02219788357615471,
-0.03200390934944153,
0.061018992215394974,
-0.012433837167918682,
-0.024313567206263542,
0.08281388878822327,
0.03559721261262894,
-0.03670542687177658,
-0.01954488456249237,
0.02293669432401657,
0.048425640910863876,
-0.0003589105617720634,
0.01798330806195736,
-0.004915605299174786,
-0.04939952492713928,
0.010830284096300602,
0.028964711353182793,
-0.022147510200738907,
0.0029132624622434378,
0.02652999758720398,
0.0032994584180414677,
0.03892185539007187,
-0.001406257739290595,
-0.06061600521206856,
-0.024212820455431938,
0.0036562702152878046,
0.030207255855202675,
-0.018067263066768646,
-0.03235652297735214,
0.03274271637201309,
0.050507742911577225,
-0.0675339549779892,
-0.028242694213986397,
-0.05628389120101929,
-0.04909728467464447,
0.012845220044255257,
0.007132035680115223,
0.043724123388528824,
-0.025220287963747978,
0.039324842393398285,
0.03660468012094498,
0.02691619284451008,
-0.06998546421527863,
-0.013718359172344208,
0.003121052635833621,
-0.0016465808730572462,
-0.04607488214969635,
-0.047485336661338806,
0.01122487522661686,
0.026731491088867188,
-0.020065410062670708,
-0.025253871455788612,
-0.06316825747489929,
0.07367951422929764,
-0.041272617876529694,
-0.027201643213629723,
0.021610194817185402,
-0.020149365067481995,
-0.016866696998476982,
-0.0007760653970763087,
-0.013978621922433376,
-0.029401281848549843,
-0.0676347017288208,
-0.061186905950307846,
-0.053395818918943405,
0.009386246092617512,
0.02075384557247162,
-0.0287296362221241,
0.04150769114494324,
-0.04614204540848732,
0.03136584535241127,
-0.016077514737844467,
0.024918047711253166,
0.026479624211788177,
-0.003433787729591131,
0.0031777226831763983,
-0.016295798122882843,
0.021710941568017006,
-0.044295020401477814,
-0.0448659211397171,
0.023675503209233284,
0.03351511061191559,
-0.012358277104794979,
0.05977645143866539,
-0.045671895146369934,
0.025740813463926315,
-0.0372091606259346,
-0.06417572498321533,
0.11035135388374329,
-0.0007193952915258706,
0.02616059221327305,
-0.012803242541849613,
0.0199142899364233,
-0.021341536194086075,
-0.03878752887248993,
-0.013676381669938564,
0.023020649328827858,
0.0061287651769816875,
0.02753746509552002,
0.050642069429159164,
-0.01571650430560112,
-0.003129448276013136,
0.04463084414601326,
-0.052455514669418335,
-0.01386108435690403,
0.0031567339319735765,
-0.08509748429059982,
-0.0101502425968647,
0.06004510819911957,
-0.011443160474300385,
-0.019528092816472054,
-0.018436668440699577,
-0.007043882273137569,
0.00622111652046442,
0.03005613572895527,
0.014885343611240387,
0.0019036951707676053,
0.03509347885847092,
0.03393488749861717,
-0.025421781465411186,
0.02852814272046089,
-0.007677747868001461,
0.0017840584041550756,
-0.03804871812462807,
-0.021106459200382233,
-0.0720003992319107,
-0.03996290639042854,
0.029535610228776932,
0.023793041706085205,
0.025740813463926315,
-0.014784596860408783,
0.07226905226707458,
0.0448659211397171,
0.008924489840865135,
-0.02985464222729206,
0.05443686619400978,
-0.05010475590825081,
0.07126158475875854,
0.016329381614923477,
-0.007455265149474144,
0.004424464888870716,
-0.0006784669240005314,
0.023625129833817482,
-0.003587006824091077,
-0.007560209836810827,
-0.01272768247872591,
0.007043882273137569,
0.0008768122061155736,
-0.03865319862961769,
0.014482355676591396,
-0.04526890814304352,
-0.09429902583360672,
0.05876898020505905,
0.044597260653972626,
0.0634704977273941,
-0.022147510200738907,
-0.032977793365716934,
-0.0012803241843357682,
0.007207595743238926,
0.010813492350280285,
-0.07388100773096085,
-0.07099293172359467,
0.028830382972955704,
-0.009352663531899452,
-0.03791438788175583,
-0.03131547197699547,
-0.012501002289354801,
0.018873238936066628,
-0.028309857472777367,
-0.03908976912498474,
-0.039761412888765335,
-0.059440627694129944,
0.019897498190402985,
0.032087862491607666,
0.011485137976706028,
-0.012677309103310108,
0.020031826570630074,
0.06078391894698143,
-0.030257629230618477,
0.0008437546784989536,
0.027487091720104218,
-0.06951531022787094,
0.011065359227359295,
-0.014314444735646248,
-0.0033414363861083984,
-0.021425491198897362,
-0.05054132267832756,
0.06064958870410919,
-0.01961204782128334,
0.01238346379250288,
-0.038686782121658325,
0.03751140087842941,
0.017445992678403854,
-0.03482481837272644,
-0.033280033618211746,
-0.036873336881399155,
0.01619505137205124,
-0.011543907225131989,
0.03482481837272644,
0.0253881998360157,
-0.055981650948524475,
0.045806221663951874,
0.03349832072854042,
0.002029628725722432,
-0.007472056429833174,
0.05917196720838547,
-0.03694050386548042,
0.0414741113781929,
-0.018201593309640884,
-0.012887198477983475,
0.005860107019543648,
0.05084356293082237,
0.03232293948531151,
0.01716054230928421,
0.0037507202941924334,
0.030459122732281685,
-0.030694199725985527,
-0.07280637323856354,
0.10793343186378479,
0.02048518694937229,
-0.025354618206620216,
-0.0002226137585239485
]
|
32,311 | bqplot.marks | on_legend_hover | null | def on_legend_hover(self, callback, remove=False):
self._legend_hover_handlers.register_callback(callback, remove=remove)
| (self, callback, remove=False) | [
-0.003545542014762759,
0.026585211977362633,
-0.000019260616682004184,
0.056965891271829605,
-0.07380827516317368,
0.025433016940951347,
-0.011250847950577736,
0.08661797642707825,
0.009107425808906555,
-0.012233602814376354,
0.026364939287304878,
-0.010818774811923504,
0.04988327622413635,
-0.1049853265285492,
-0.0004577540676109493,
0.010734054259955883,
-0.0201973058283329,
0.03334588557481766,
0.029347091913223267,
-0.026076890528202057,
-0.018282627686858177,
-0.030109573155641556,
-0.0448339506983757,
-0.044732287526130676,
0.005879584699869156,
0.05561036616563797,
-0.02936403639614582,
0.012411515228450298,
0.033735599368810654,
0.02778823859989643,
-0.005066270474344492,
-0.03975073620676994,
-0.06089691072702408,
0.03292228654026985,
-0.019231494516134262,
0.01215735450387001,
-0.025534680113196373,
0.017435425892472267,
0.011691393330693245,
0.004225422162562609,
-0.0066293589770793915,
0.016495030373334885,
0.04293621703982353,
-0.004183061886578798,
0.10593418776988983,
0.05672867223620415,
-0.042258456349372864,
0.027449358254671097,
0.02387416362762451,
-0.07075834274291992,
-0.023077793419361115,
-0.03775133937597275,
0.009090482257306576,
0.034345585852861404,
-0.03890353441238403,
0.013445102609694004,
0.041174035519361496,
0.002194254193454981,
0.013046917505562305,
-0.033735599368810654,
0.024704422801733017,
0.04188568890094757,
-0.01284358836710453,
-0.01074252650141716,
0.023738611489534378,
-0.008171266876161098,
-0.009598803706467152,
-0.047307781875133514,
-0.0008069602772593498,
-0.013741622678935528,
0.021620605140924454,
0.025144968181848526,
0.025907449424266815,
-0.013250245712697506,
-0.02677159570157528,
0.0008847970166243613,
0.006053261458873749,
-0.1013931855559349,
0.008344943635165691,
0.0024420609697699547,
-0.04195346310734749,
-0.016444198787212372,
0.024704422801733017,
0.04164846986532211,
0.008709240704774857,
-0.055915359407663345,
0.0569320023059845,
0.0003690625599119812,
-0.002006810624152422,
0.007573989685624838,
-0.04171624779701233,
-0.05706755444407463,
-0.01821485161781311,
0.018892614170908928,
-0.026788540184497833,
-0.045172832906246185,
0.005354319233447313,
0.013453573919832706,
0.10261315852403641,
-0.032685067504644394,
0.0682506263256073,
-0.058050308376550674,
0.06547180563211441,
0.02677159570157528,
0.048121098428964615,
-0.02217976003885269,
0.004288962110877037,
-0.03153287246823311,
-0.06296408176422119,
0.026026058942079544,
0.004176707938313484,
-0.03409142419695854,
0.042834553867578506,
-0.01688474416732788,
0.006794563494622707,
0.042224567383527756,
0.009505610913038254,
-0.0187740046530962,
-0.0016149795847013593,
-0.04788387939333916,
-0.0147413220256567,
-0.0036556783597916365,
0.007175804581493139,
-0.03565027564764023,
-0.028008511289954185,
0.005888056941330433,
0.025433016940951347,
0.0694705992937088,
0.025551624596118927,
-0.004668085370212793,
0.022501695901155472,
0.03241396322846413,
-0.0029440284706652164,
-0.012767340056598186,
0.0070699043571949005,
-0.02822878398001194,
-0.021874766796827316,
-0.0006417558179236948,
0.019756760448217392,
-0.034193091094493866,
0.014504104852676392,
-0.007230872754007578,
-0.03178703412413597,
0.035718053579330444,
-0.012962196953594685,
-0.04693501442670822,
-0.06337074190378189,
-0.01595282182097435,
-0.0020544659346342087,
0.0010695930104702711,
-0.00997157208621502,
0.003825118998065591,
-0.0036577964201569557,
-0.03520973399281502,
0.026991868391633034,
0.03829354792833328,
-0.008277167566120625,
0.016012124717235565,
0.012572484090924263,
0.015436028130352497,
0.03409142419695854,
-0.006794563494622707,
0.02531440742313862,
-0.054864827543497086,
-0.048121098428964615,
-0.02355222776532173,
0.09454778581857681,
0.031482040882110596,
-0.03598915785551071,
0.05642367899417877,
-0.01994314417243004,
-0.0045028808526694775,
0.031803976744413376,
0.06228632107377052,
-0.013495934195816517,
0.03920852765440941,
0.02072257176041603,
0.008929513394832611,
0.015198810957372189,
0.026483546942472458,
0.0016425136709585786,
0.011098351329565048,
-0.04690112546086311,
0.010429061949253082,
0.0006661128718405962,
-0.04154680669307709,
-0.030838167294859886,
0.006930115632712841,
-0.05903306230902672,
0.03565027564764023,
-0.0051509905606508255,
-0.03859854117035866,
-0.012919836677610874,
0.004318614490330219,
0.06337074190378189,
-0.03165148198604584,
0.02726297453045845,
0.058253638446331024,
-0.04405452683568001,
0.025416072458028793,
0.013750094920396805,
0.00507897837087512,
-0.06567513197660446,
-0.006142217665910721,
0.014334664680063725,
0.007349480874836445,
0.009403946809470654,
-0.007908634841442108,
-0.034430306404829025,
-0.04313954710960388,
0.0041152858175337315,
0.015961293131113052,
-0.0033888097386807203,
0.044732287526130676,
-0.0062777698040008545,
0.005600007716566324,
-0.06848784536123276,
0.0327189564704895,
0.01909594237804413,
-0.013623015023767948,
-0.09793660044670105,
-0.03385420888662338,
-0.008607576601207256,
0.029940133914351463,
0.03322727978229523,
0.032329242676496506,
0.04618947580456734,
0.02883877046406269,
0.09041344374418259,
-0.043885085731744766,
-0.014588825404644012,
0.009505610913038254,
-0.002723755780607462,
-0.0634385198354721,
0.03093983232975006,
0.0006163397338241339,
0.07184276729822159,
-0.0051594628021121025,
0.04618947580456734,
0.07001280784606934,
0.016503503546118736,
0.0052484190091490746,
0.01570713333785534,
0.022586416453123093,
0.0024780670646578074,
0.05293320491909981,
-0.005303487181663513,
0.029584309086203575,
-0.03044845536351204,
0.008853265084326267,
-0.020773403346538544,
-0.030804280191659927,
0.04313954710960388,
0.03703968971967697,
0.04639280587434769,
-0.012369154952466488,
0.012309851124882698,
-0.019655095413327217,
0.02201031893491745,
-0.04486783966422081,
-0.0011511362390592694,
0.028482945635914803,
-0.007726485840976238,
0.032329242676496506,
0.024450261145830154,
-0.01696099154651165,
0.054627612233161926,
0.02439942955970764,
-0.009886852465569973,
0.02148505300283432,
0.0723171979188919,
-0.01719820871949196,
-0.02936403639614582,
-0.012962196953594685,
-0.007120736408978701,
0.029499588534235954,
-0.023162513971328735,
-0.04598614573478699,
0.021468108519911766,
-0.00003921620373148471,
0.03764967620372772,
-0.033820319920778275,
-0.04405452683568001,
0.014851458370685577,
-0.04466450959444046,
0.06384517252445221,
-0.0019051464041694999,
0.0391746386885643,
-0.005134046543389559,
0.011233904398977757,
0.00995462853461504,
0.00953102670609951,
-0.027025757357478142,
0.02063785120844841,
0.018841780722141266,
-0.006654774770140648,
0.041174035519361496,
0.03605693578720093,
0.012047218158841133,
0.05178100988268852,
-0.014817570336163044,
-0.04910385236144066,
-0.013843287713825703,
0.01053919829428196,
-0.05913472920656204,
-0.03985240310430527,
0.09373447299003601,
-0.0011246611829847097,
-0.02653438039124012,
0.034582801163196564,
-0.008717712946236134,
0.03490474075078964,
-0.050866033881902695,
0.007133444305509329,
-0.018706228584051132,
0.018638452515006065,
0.037378571927547455,
-0.00838306825608015,
0.00041221693390980363,
0.031244825571775436,
-0.0553392618894577,
-0.06062580645084381,
-0.08702462911605835,
-0.10552753508090973,
0.04324121028184891,
-0.05516982078552246,
-0.012987612746655941,
-0.04066571593284607,
0.03412531316280365,
-0.03798855468630791,
0.012564011849462986,
-0.08228030055761337,
0.05137435346841812,
-0.036768585443496704,
0.02087506651878357,
-0.0050620343536138535,
-0.0044944086112082005,
0.0044647566974163055,
-0.04252956062555313,
-0.028804881498217583,
-0.059270281344652176,
0.022806689143180847,
-0.05750809982419014,
0.03424392268061638,
-0.02766963094472885,
0.044732287526130676,
-0.029499588534235954,
0.024416374042630196,
-0.013631487265229225,
0.050222158432006836,
0.04978161305189133,
-0.0009149786201305687,
-0.04093682020902634,
0.066217340528965,
0.049205515533685684,
-0.03446419537067413,
0.002323452616110444,
0.004013621248304844,
0.014987010508775711,
0.003473529824987054,
0.04784999042749405,
-0.06492958962917328,
0.002431470900774002,
-0.005006966181099415,
0.051306579262018204,
0.0030181584879755974,
-0.01938399113714695,
-0.002130714012309909,
0.024890806525945663,
-0.04066571593284607,
0.012250547297298908,
-0.030990663915872574,
0.04954439774155617,
0.022874465212225914,
-0.03446419537067413,
-0.04639280587434769,
0.027720462530851364,
0.023196402937173843,
-0.05442428216338158,
-0.04717222973704338,
-0.011835417710244656,
-0.0010214083595201373,
-0.04883274808526039,
-0.006472626235336065,
0.039310190826654434,
-0.0011691392865031958,
-0.007031780201941729,
0.00838306825608015,
0.014673545956611633,
-0.011479592882096767,
0.05527148395776749,
-0.04168235883116722,
0.026195498183369637,
-0.010335869155824184,
-0.04378341883420944,
0.005235711112618446,
-0.04229234531521797,
0.006498042494058609,
-0.011454176157712936,
0.026144666597247124,
-0.01294525247067213,
-0.03219369053840637,
-0.033498384058475494,
-0.03893742337822914,
0.03415920212864876,
-0.005498343612998724,
-0.05310264602303505,
0.09170118719339371,
-0.007023307960480452,
-0.001171257346868515,
0.037785228341817856,
-0.036328040063381195,
-0.0375480093061924,
-0.050256047397851944,
-0.022552527487277985,
-0.001717702834866941,
-0.027229085564613342,
-0.003092288738116622,
-0.03187175467610359,
-0.013055388815701008,
0.011089880019426346,
-0.04825665056705475,
0.006438738200813532,
0.041207924485206604,
-0.0036705045495182276,
-0.017350705340504646,
-0.05327208712697029,
0.05269598960876465,
-0.028330449014902115,
-0.019316215068101883,
0.06082913279533386,
-0.011759169399738312,
0.04025905951857567,
0.010327397845685482,
0.009302282705903053,
0.0351419560611248,
-0.022230591624975204,
0.05686422437429428,
0.003060518763959408,
-0.030990663915872574,
0.056118689477443695,
0.001342815812677145,
-0.0016562807140871882,
-0.0605919174849987,
0.006455682218074799,
0.03044845536351204,
0.005544940009713173,
0.0028211839962750673,
0.07292718440294266,
-0.023399731144309044,
-0.02536524087190628,
0.021010620519518852,
0.042461786419153214,
0.07773929089307785,
0.03520973399281502,
-0.05784698203206062,
-0.04107237234711647,
-0.08594021201133728,
0.026602156460285187,
0.05794864520430565,
-0.00826022308319807,
0.0072774686850607395,
-0.01731681637465954,
-0.018723173066973686,
-0.005100158508867025,
0.031363435089588165,
0.05544092506170273,
-0.036328040063381195,
-0.01269956398755312,
-0.008395776152610779,
0.06916560232639313,
-0.00024965996271930635,
-0.010878078639507294,
-0.0023636948317289352,
-0.011860833503305912,
-0.003964907489717007,
0.019129831343889236,
0.021264780312776566,
-0.03368476778268814,
0.029618196189403534,
0.05391596257686615,
-0.00835765153169632,
0.02883877046406269,
-0.008988817222416401,
0.02677159570157528,
0.013478990644216537,
-0.03117704950273037,
-0.027686575427651405,
-0.01312316581606865,
0.034515026956796646,
-0.04269900172948837,
-0.07191053777933121,
-0.0012750396272167563,
0.019400935620069504,
0.02936403639614582,
-0.04842609167098999,
0.08173809200525284,
-0.0009816958336159587,
0.05723699554800987,
-0.04378341883420944,
-0.03598915785551071,
0.008488968014717102,
-0.020790347829461098,
0.000021742655007983558,
0.024568870663642883,
-0.03666691854596138,
0.03775133937597275,
0.03849687799811363,
-0.08207696676254272,
0.005045090336352587,
-0.037378571927547455,
0.023857219144701958,
0.04358009248971939,
0.05083214491605759,
-0.019960088655352592,
-0.03326116502285004,
-0.0025416072458028793,
0.03380337730050087,
0.03219369053840637,
-0.011564312502741814,
0.045816704630851746,
-0.004528297111392021,
-0.0005355907487682998,
-0.08153475821018219,
-0.00941241905093193,
-0.02604300156235695,
-0.00809501949697733,
0.015918932855129242,
-0.011496536433696747,
-0.04839220270514488,
0.0015292003517970443,
0.007302884943783283,
-0.016147678717970848,
-0.021230893209576607,
-0.03175314515829086,
0.01611378975212574,
0.005676256027072668,
0.024602757766842842,
-0.0727238580584526,
-0.015724075958132744,
0.03436252847313881,
-0.019434822723269463,
0.025111079216003418,
-0.03964907303452492,
0.016173094511032104,
0.014292304404079914,
-0.009734355844557285,
-0.004545241128653288,
0.018367348238825798,
-0.01719820871949196,
0.00395643524825573,
0.05835530161857605,
0.016461143270134926,
-0.03368476778268814,
-0.011894721537828445,
0.041140150278806686,
0.02916070632636547,
0.0027788239531219006,
0.00761211384087801,
0.01207263395190239,
-0.036768585443496704,
-0.0067098429426550865,
0.02204420603811741,
-0.016579750925302505,
0.015275059267878532,
0.013724679127335548,
-0.03093983232975006,
0.03727690503001213,
-0.010429061949253082,
-0.03659914433956146,
-0.016944048926234245,
0.04700278863310814,
0.04378341883420944,
-0.01065780594944954,
-0.04324121028184891,
0.03343060612678528,
0.06072746962308884,
-0.06682732701301575,
-0.019350102171301842,
-0.08268695324659348,
-0.04866330698132515,
0.03537917137145996,
0.03029595874249935,
0.050662703812122345,
-0.016571279615163803,
0.020892011001706123,
0.008912568911910057,
0.04971383884549141,
-0.058016419410705566,
0.0030520467553287745,
-0.0050705065950751305,
-0.005926181096583605,
-0.08045034110546112,
-0.028364336118102074,
0.013478990644216537,
0.020773403346538544,
0.005231474991887808,
-0.018062354996800423,
-0.0395812951028347,
0.10200317203998566,
-0.044562846422195435,
-0.004202123731374741,
0.02229836769402027,
-0.042224567383527756,
0.01882483810186386,
-0.019367046654224396,
0.02241697534918785,
-0.04164846986532211,
-0.03771745041012764,
-0.0715038850903511,
-0.054627612233161926,
0.02463664673268795,
0.0035158901009708643,
-0.03646359220147133,
0.05923639237880707,
-0.04236011952161789,
0.0199939776211977,
-0.0399879552423954,
0.03283756598830223,
0.007777318358421326,
0.0036959205754101276,
0.002850836142897606,
-0.021756157279014587,
0.01635947823524475,
-0.022840576246380806,
-0.06492958962917328,
0.034430306404829025,
0.014546465128660202,
-0.01671530306339264,
0.03683635964989662,
-0.04991716518998146,
0.02390805259346962,
-0.020502299070358276,
-0.08492357283830643,
0.07597710937261581,
0.020502299070358276,
0.051306579262018204,
-0.0266529880464077,
0.0023636948317289352,
-0.030160406604409218,
-0.07184276729822159,
-0.006116801407188177,
0.01818096451461315,
-0.03700580075383186,
0.02168838120996952,
0.06764063984155655,
-0.006193049717694521,
0.012462347745895386,
0.022705024108290672,
-0.054254841059446335,
0.007675653789192438,
-0.0036133183166384697,
-0.058423079550266266,
0.00702754408121109,
0.048154983669519424,
-0.04171624779701233,
-0.0032934993505477905,
-0.033820319920778275,
-0.006307422183454037,
-0.0014614241663366556,
0.010276565328240395,
-0.020892011001706123,
-0.0072774686850607395,
0.047273892909288406,
0.06777619570493698,
-0.019977033138275146,
0.015232698991894722,
0.0005083214491605759,
0.0039797332137823105,
-0.019231494516134262,
-0.010242677293717861,
-0.06903005391359329,
-0.06086302176117897,
0.014470216818153858,
0.03292228654026985,
-0.0008164913160726428,
-0.002996978582814336,
0.055712029337882996,
0.032651182264089584,
0.007387605030089617,
0.010276565328240395,
0.05293320491909981,
-0.04713834077119827,
0.05598313361406326,
0.009675051085650921,
0.03246479481458664,
0.024619702249765396,
-0.0016562807140871882,
0.04042850062251091,
0.013046917505562305,
-0.005650840234011412,
-0.02519579976797104,
-0.013258717954158783,
0.007514685392379761,
-0.06374350935220718,
-0.00405809935182333,
-0.04249567165970802,
-0.10220649838447571,
0.05500037968158722,
0.014275360852479935,
0.04995105415582657,
0.01918066293001175,
-0.021976429969072342,
0.005659312009811401,
0.0541192889213562,
0.022027263417840004,
-0.06770841777324677,
-0.08017923682928085,
0.017384594306349754,
-0.024501094594597816,
-0.0666240006685257,
-0.030160406604409218,
0.017257513478398323,
0.024619702249765396,
-0.02189170941710472,
-0.07041946798563004,
-0.020129529759287834,
-0.05903306230902672,
0.035514723509550095,
0.029618196189403534,
0.026669932529330254,
-0.009607275016605854,
-0.0043419124558568,
0.06367573142051697,
-0.030109573155641556,
0.007654473651200533,
0.00809501949697733,
-0.08214474469423294,
-0.001704994821920991,
0.008387303911149502,
0.001063768519088626,
0.007082612253725529,
-0.03295617550611496,
0.02843211218714714,
-0.01122543215751648,
0.016223926097154617,
-0.018892614170908928,
0.043071769177913666,
0.04269900172948837,
-0.025754952803254128,
-0.014580353163182735,
-0.049205515533685684,
0.03839521482586861,
-0.023365842178463936,
0.08255140483379364,
0.000333321193465963,
-0.0520860031247139,
0.06248965114355087,
0.025941338390111923,
0.04574893042445183,
0.007823914289474487,
0.04086904600262642,
-0.01946871168911457,
0.029211539775133133,
-0.025958281010389328,
-0.012504708021879196,
-0.006489570252597332,
0.03380337730050087,
0.00035529551678337157,
0.02338278666138649,
0.020908955484628677,
0.030075686052441597,
0.00351800792850554,
-0.07902704179286957,
0.11535508185625076,
0.009259922429919243,
-0.04046238586306572,
-0.021213948726654053
]
|
32,329 | bqplot.axes | BaseAxis | null | class BaseAxis(Widget):
axis_types = {}
_view_module = Unicode('bqplot').tag(sync=True)
_model_module = Unicode('bqplot').tag(sync=True)
_view_module_version = Unicode(__frontend_version__).tag(sync=True)
_model_module_version = Unicode(__frontend_version__).tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
-0.023720338940620422,
-0.07650343328714371,
-0.0365421436727047,
0.04466262087225914,
-0.013186870142817497,
0.005053037777543068,
-0.03525996580719948,
0.03953389823436737,
-0.014905348420143127,
-0.044484540820121765,
0.044484540820121765,
0.022010765969753265,
0.01612520031630993,
0.0022093127481639385,
-0.030149050056934357,
-0.011040998622775078,
0.023399794474244118,
-0.02591073140501976,
0.024628549814224243,
-0.09808681160211563,
-0.01758546195924282,
-0.006268437951803207,
-0.03757501393556595,
-0.033799704164266586,
0.025109367445111275,
0.07119663804769516,
-0.011174559593200684,
0.008761567063629627,
-0.023577874526381493,
-0.0610816553235054,
-0.08975263684988022,
-0.013810152187943459,
-0.012474548071622849,
-0.014851924031972885,
0.03061205893754959,
-0.0695226788520813,
-0.006437614560127258,
-0.016071775928139687,
0.006299602333456278,
0.0533529557287693,
0.06289807707071304,
-0.05011188983917236,
0.04241880401968956,
-0.06938020884990692,
0.03207232058048248,
0.02429019659757614,
-0.007221169304102659,
0.057199496775865555,
-0.017353957518935204,
-0.012617012485861778,
0.02058611996471882,
-0.023969652131199837,
-0.014353298582136631,
0.062256988137960434,
-0.0526762492954731,
0.04747629538178444,
0.006361930165439844,
0.10207581520080566,
-0.049043405801057816,
0.09865666925907135,
-0.035206541419029236,
0.03538462147116661,
-0.006108165252953768,
-0.04156401753425598,
0.002613333286717534,
0.010978670790791512,
0.004888313356786966,
-0.004115888383239508,
-0.029650423675775528,
0.023257330060005188,
-0.018030663952231407,
0.008472185581922531,
-0.01641903445124626,
0.0013957069022580981,
-0.00043824530439451337,
-0.03237505629658699,
-0.01714916341006756,
0.04113662615418434,
-0.043843451887369156,
-0.029899736866354942,
0.06827611476182938,
0.03173396736383438,
0.022010765969753265,
-0.011459488421678543,
0.03452983498573303,
-0.03134218975901604,
-0.04078046232461929,
0.03383531793951988,
-0.01197592169046402,
-0.038714729249477386,
-0.029864121228456497,
-0.04327359050512314,
0.024949096143245697,
0.05381596460938454,
-0.0042360927909612656,
-0.08305680751800537,
-0.047155749052762985,
-0.03235724940896034,
-0.0646432638168335,
0.006669119466096163,
0.00031052809208631516,
-0.012901941314339638,
-0.0280833151191473,
-0.03454764187335968,
0.0013600907986983657,
-0.03814487159252167,
-0.030647676438093185,
-0.016329992562532425,
-0.06371724605560303,
-0.009104372002184391,
0.023328561335802078,
-0.0002705990627873689,
0.021921725943684578,
0.03623940795660019,
-0.02865317277610302,
0.059229616075754166,
-0.06336108595132828,
0.030950412154197693,
0.07176649570465088,
-0.012216330505907536,
-0.07190895825624466,
0.07051993161439896,
-0.014709459617733955,
0.012367699295282364,
0.04790368676185608,
0.03828733414411545,
0.02724633552134037,
0.04416399449110031,
-0.06834734231233597,
-0.015733422711491585,
0.016018351539969444,
-0.02576826699078083,
-0.030309323221445084,
-0.04099415987730026,
0.06681585311889648,
-0.00044353207340463996,
0.08455268293619156,
0.033746279776096344,
-0.08747320622205734,
0.07921025902032852,
-0.03362162038683891,
0.02507375180721283,
0.01389919314533472,
0.011361544020473957,
-0.059514544904232025,
0.01677519455552101,
-0.048758476972579956,
-0.004389687441289425,
-0.023346370086073875,
-0.021921725943684578,
-0.04523247852921486,
-0.01029305998235941,
0.02078200876712799,
-0.0006572288111783564,
0.010569085367023945,
-0.008734854869544506,
-0.02443266101181507,
-0.018627233803272247,
-0.014068369753658772,
0.04558863863348961,
-0.03390655294060707,
-0.016303282231092453,
0.03217916935682297,
-0.05502691492438316,
-0.002851516008377075,
0.044769469648599625,
0.02051488868892193,
-0.06496381014585495,
-0.01656149886548519,
0.04366536810994148,
-0.011815649457275867,
-0.05392281338572502,
0.014442338608205318,
0.005622895900160074,
-0.026249084621667862,
0.010168403387069702,
0.006353026255965233,
0.06133096665143967,
0.030594252049922943,
0.011904689483344555,
0.023755956441164017,
0.021155977621674538,
-0.05905153602361679,
-0.014353298582136631,
-0.02815454639494419,
-0.04184894636273384,
0.04102977737784386,
0.002597751095890999,
0.020550504326820374,
0.0277449619024992,
0.017808062955737114,
-0.01401494536548853,
-0.014843020588159561,
-0.04313112795352936,
0.002566586947068572,
0.016979986801743507,
0.020034071058034897,
-0.03882157802581787,
0.011815649457275867,
0.06681585311889648,
0.01389919314533472,
0.032125744968652725,
0.03292710706591606,
0.03429832682013512,
0.031840816140174866,
0.030843565240502357,
0.03821610286831856,
-0.03531338647007942,
-0.006250630132853985,
0.0025309708435088396,
0.001252129441127181,
-0.005137626081705093,
-0.06282684206962585,
0.04957764595746994,
-0.012617012485861778,
0.014593707397580147,
-0.05531184375286102,
0.002193730790168047,
-0.029472343623638153,
0.020051877945661545,
0.07190895825624466,
0.0001975581981241703,
0.0347435288131237,
-0.03283806890249252,
0.03750377893447876,
-0.030380554497241974,
0.08469514548778534,
-0.010693741962313652,
-0.001975581981241703,
-0.04530370980501175,
-0.017434094101190567,
-0.00830300897359848,
0.0025443269405514,
0.047440677881240845,
0.02161898836493492,
0.0010573536856099963,
0.014424530789256096,
-0.014878636226058006,
-0.018030663952231407,
0.0026712093967944384,
0.021921725943684578,
0.03590105473995209,
-0.027370993047952652,
0.01818203181028366,
-0.06795556843280792,
-0.04241880401968956,
-0.025857307016849518,
0.03207232058048248,
0.00362394074909389,
-0.042739350348711014,
-0.0014346620300784707,
-0.04783245548605919,
-0.011842361651360989,
-0.02106693759560585,
0.0414215549826622,
-0.03509969264268875,
-0.027976466342806816,
-0.013908096589148045,
0.00020980123372282833,
-0.06749255955219269,
-0.018173128366470337,
0.022438159212470055,
-0.039142120629549026,
0.06596106290817261,
0.07593357563018799,
-0.0061437818221747875,
0.08804306387901306,
0.00768863083794713,
0.002477546688169241,
0.027762768790125847,
0.1137579008936882,
0.03118191845715046,
-0.03333669155836105,
0.036061327904462814,
-0.007448222022503614,
0.0002653122937772423,
0.005159886088222265,
-0.0012276433408260345,
-0.005938989110291004,
-0.024343620985746384,
-0.005133173894137144,
-0.07436647266149521,
-0.0006227256963029504,
0.04362975433468819,
-0.024949096143245697,
-0.07778561860322952,
-0.004848245065659285,
-0.06653092056512833,
-0.022562814876437187,
0.028955910354852676,
0.00027685973327606916,
0.03625721484422684,
-0.020408039912581444,
-0.0015749005833640695,
-0.03189424052834511,
0.011005382984876633,
0.02030119113624096,
0.04676397144794464,
-0.012492355890572071,
0.038999658077955246,
0.02169021964073181,
0.02352445013821125,
0.015252606011927128,
0.03846541419625282,
0.018591618165373802,
-0.022438159212470055,
0.07593357563018799,
-0.012928653508424759,
0.0596926249563694,
0.003209903370589018,
0.0013589777518063784,
0.062328219413757324,
-0.008503349497914314,
0.02149433083832264,
-0.05075297877192497,
0.03517092391848564,
-0.019909413531422615,
-0.0372188501060009,
0.007808835245668888,
0.05766250565648079,
-0.049826961010694504,
-0.04822423309087753,
-0.01973133347928524,
-0.06339669972658157,
0.009086564183235168,
0.005400294903665781,
-0.00022343553428072482,
-0.03611475229263306,
0.02309705689549446,
-0.033959973603487015,
0.007007472682744265,
0.01670396327972412,
0.019927222281694412,
0.004741396754980087,
-0.01946421153843403,
-0.08412528783082962,
0.02908056601881981,
-0.012091674841940403,
-0.015136852860450745,
-0.01656149886548519,
0.0224737748503685,
0.01944640465080738,
-0.036898307502269745,
0.014353298582136631,
-0.06314738839864731,
0.003695172956213355,
0.03180519863963127,
-0.032125744968652725,
0.057698123157024384,
0.03221478685736656,
-0.019784757867455482,
-0.005551663693040609,
-0.024254580959677696,
-0.021102555096149445,
0.049613263458013535,
-0.04373660311102867,
-0.01375672873109579,
-0.011040998622775078,
-0.04487631842494011,
0.022580623626708984,
0.045054398477077484,
-0.007190005388110876,
0.0017952753696590662,
0.06770625710487366,
-0.051857076585292816,
-0.018520385026931763,
0.047369446605443954,
-0.047226980328559875,
0.061758361756801605,
0.0182532649487257,
-0.002244928851723671,
-0.008614649996161461,
0.03657776117324829,
0.024664167314767838,
-0.039925675839185715,
0.0533529557287693,
0.021245019510388374,
0.007510550320148468,
-0.015012197196483612,
-0.09488135576248169,
0.07436647266149521,
-0.03349696472287178,
0.003982327878475189,
-0.010907438583672047,
-0.04868724197149277,
-0.0013545257970690727,
0.028564132750034332,
-0.004080272279679775,
0.014157409779727459,
-0.005475979298353195,
0.013783440925180912,
-0.05538307502865791,
-0.05855290964245796,
0.003775309305638075,
-0.07963765412569046,
-0.059799473732709885,
-0.018858738243579865,
0.003376853885129094,
-0.009135535918176174,
-0.045339327305555344,
0.011210175231099129,
-0.008565678261220455,
0.049328334629535675,
0.004211606923490763,
0.016062872484326363,
-0.02598196268081665,
0.01610739342868328,
0.01401494536548853,
0.01706012338399887,
0.006032481323927641,
-0.026658669114112854,
-0.023417603224515915,
-0.025607993826270103,
-0.0393202006816864,
0.010756069794297218,
-0.029116181656718254,
0.01586698368191719,
-0.02161898836493492,
0.017211493104696274,
0.00784890353679657,
-0.05068174749612808,
0.07764315605163574,
0.02507375180721283,
-0.023791572079062462,
0.008089312352240086,
0.025750458240509033,
-0.01481630839407444,
0.02297240123152733,
-0.009651970118284225,
0.014540283009409904,
0.015306029468774796,
0.050325583666563034,
-0.08013628423213959,
-0.017069028690457344,
-0.002900488208979368,
-0.0101773077622056,
0.027424415573477745,
-0.0575912743806839,
-0.008307461626827717,
-0.022651854902505875,
-0.012287563644349575,
-0.030665483325719833,
0.03810925409197807,
-0.017888199537992477,
0.04010375589132309,
0.0037908912636339664,
-0.0632186233997345,
0.027281951159238815,
-0.012109482660889626,
-0.06414464116096497,
-0.01344508770853281,
0.10050870478153229,
0.00857458170503378,
-0.04829546436667442,
0.05570362135767937,
-0.10684837400913239,
-0.039711978286504745,
-0.08198831975460052,
-0.0016572627937421203,
0.00617939792573452,
-0.01937517151236534,
0.008138285018503666,
-0.06200767308473587,
-0.08469514548778534,
0.03850103169679642,
0.018787506967782974,
0.03419148176908493,
-0.03850103169679642,
0.00030468482873402536,
0.03821610286831856,
0.0319298580288887,
0.006424258463084698,
0.020746393129229546,
0.0006299602100625634,
-0.059372082352638245,
0.03525996580719948,
0.015306029468774796,
0.05345980450510979,
-0.02753126434981823,
-0.042668119072914124,
-0.014193026348948479,
-0.004910573363304138,
0.012002633884549141,
0.03974759578704834,
0.010720454156398773,
0.0357942059636116,
0.014442338608205318,
-0.026213468983769417,
-0.00507529778406024,
-0.0012421123683452606,
-0.005516047589480877,
0.03867911174893379,
-0.024966903030872345,
0.032891493290662766,
0.07543495297431946,
0.00966087356209755,
0.04751191288232803,
0.01882312260568142,
-0.024486085399985313,
0.0336928553879261,
0.031858623027801514,
-0.07212265580892563,
0.013026597909629345,
0.012803996913135052,
0.0723363533616066,
-0.06784871965646744,
0.018716273829340935,
0.037254467606544495,
-0.025465529412031174,
-0.03600790351629257,
-0.0337284691631794,
-0.044413309544324875,
0.049399565905332565,
-0.014442338608205318,
0.036346256732940674,
-0.033746279776096344,
-0.044199611991643906,
0.06396655738353729,
0.0049194772727787495,
0.017264917492866516,
0.0045989323407411575,
-0.010408812202513218,
-0.004053560085594654,
-0.04338043928146362,
-0.018929971382021904,
0.01624985784292221,
-0.06784871965646744,
-0.003267779480665922,
-0.032553140074014664,
0.05780497193336487,
0.070911705493927,
-0.014335490763187408,
-0.007310209795832634,
-0.012332083657383919,
0.007381442002952099,
0.05791182070970535,
-0.09716078639030457,
0.056772105395793915,
0.04466262087225914,
0.027370993047952652,
0.007047540973871946,
-0.02956138364970684,
0.05082421004772186,
-0.006820487789809704,
0.007808835245668888,
0.014727267436683178,
0.015679998323321342,
-0.008120476268231869,
0.03271340951323509,
0.010515660978853703,
0.01973133347928524,
0.036684609949588776,
0.0372188501060009,
-0.015617670491337776,
-0.054100893437862396,
-0.021725837141275406,
-0.012073866091668606,
0.003100828966125846,
0.06517750769853592,
-0.0032967175357043743,
0.015439590439200401,
0.016089584678411484,
0.024592934176325798,
0.04241880401968956,
0.0028158999048173428,
0.03574078157544136,
-0.0172025877982378,
-0.003525996347889304,
-0.020140917971730232,
0.025661418214440346,
0.008089312352240086,
-0.05274748057126999,
0.004280613269656897,
-0.02309705689549446,
0.04170648381114006,
0.044698238372802734,
0.03757501393556595,
0.029792888090014458,
-0.0849800780415535,
-0.04740506410598755,
-0.06215013936161995,
0.05189269408583641,
0.0019165927078574896,
-0.02072858437895775,
0.0007323565660044551,
-0.012964269146323204,
0.05132283642888069,
0.02128063514828682,
0.060369331389665604,
-0.0179149117320776,
-0.07133910059928894,
0.051073525100946426,
0.030932605266571045,
-0.033461350947618484,
0.029614808037877083,
0.012198522686958313,
-0.05413651093840599,
-0.07529249042272568,
0.0004632878699339926,
-0.017576558515429497,
0.03144903853535652,
0.05050366371870041,
0.0101773077622056,
0.03209012746810913,
0.010195115581154823,
-0.013142350129783154,
0.019428595900535583,
-0.01512794941663742,
-0.04234757274389267,
0.002136967610567808,
0.024681974202394485,
-0.007710891310125589,
0.009059851989150047,
0.008151641115546227,
0.025946347042918205,
-0.03924896940588951,
-0.0101773077622056,
0.014299874193966389,
0.05313925817608833,
-0.04338043928146362,
-0.00015109028026927263,
0.05869537591934204,
-0.0050174216739833355,
0.0006349687464535236,
-0.04836669936776161,
0.016205336898565292,
0.054243359714746475,
-0.021957341581583023,
0.009224576875567436,
-0.01432658638805151,
0.02058611996471882,
-0.02991754561662674,
-0.0049684494733810425,
-0.09851419925689697,
-0.00877937488257885,
0.024521702900528908,
-0.031858623027801514,
0.0028158999048173428,
0.02900933474302292,
0.01449576299637556,
0.08412528783082962,
-0.01250126026570797,
0.04754752665758133,
0.03460106626152992,
0.02261623926460743,
0.015786847099661827,
-0.04031745344400406,
0.00192660978063941,
-0.018734082579612732,
0.004265030845999718,
0.0030830209143459797,
-0.01512794941663742,
-0.015386166051030159,
-0.0031653831247240305,
0.02190391719341278,
0.03144903853535652,
-0.0011475069914013147,
-0.011601952835917473,
0.04630096256732941,
-0.06072549521923065,
-0.0026778874453157187,
-0.021049130707979202,
0.007109868805855513,
0.03385312855243683,
0.02373814769089222,
-0.03160931169986725,
-0.0006661328370682895,
0.015920408070087433,
-0.012385507114231586,
-0.02822577953338623,
0.022669663652777672,
-0.01700669899582863,
-0.013765632174909115,
-0.012287563644349575,
-0.02865317277610302,
0.0005642930045723915,
0.022990208119153976,
0.0020657351706176996,
0.025536762550473213,
-0.015386166051030159,
-0.017977239564061165,
-0.003172061173245311,
-0.05798305198550224,
0.0138724809512496,
-0.01801285520195961,
0.012474548071622849,
-0.00026809482369571924,
0.014878636226058006,
-0.03469010442495346,
-0.051643382757902145,
-0.031627118587493896,
-0.008360885083675385,
-0.018734082579612732,
-0.020372424274683,
0.0646432638168335,
-0.0737253800034523,
0.018591618165373802,
-0.05531184375286102,
0.022224461659789085,
0.023435410112142563,
0.032196976244449615,
-0.044199611991643906,
-0.037468165159225464,
0.046657122671604156,
0.04815300181508064,
0.042596884071826935,
-0.007305757608264685,
-0.012581395916640759,
0.04569548740983009,
-0.030149050056934357,
0.018840929493308067,
0.02049707993865013,
0.008187256753444672,
-0.005288994405418634,
0.04135031998157501,
-0.05940769612789154,
-0.023292945697903633,
0.040139373391866684,
0.009678682312369347,
-0.0018331174505874515,
-0.005413651000708342,
0.04850916191935539,
0.014273161999881268,
0.03282025828957558,
0.0604049488902092,
0.05855290964245796,
-0.028136739507317543,
0.007933491840958595,
-0.04893655702471733,
0.0059968652203679085,
-0.03363943099975586,
0.020977897569537163,
-0.049755726009607315,
-0.013640975579619408,
0.008107120171189308,
0.014540283009409904,
-0.03169834986329079,
-0.008173900656402111,
0.01309783011674881,
0.0014346620300784707,
0.020817624405026436,
-0.030362747609615326,
-0.018929971382021904,
-0.0365421436727047,
0.048758476972579956,
-0.0071766492910683155,
0.0003884383768308908,
0.021529948338866234,
0.025251831859350204,
0.04234757274389267,
0.03217916935682297,
0.018413536250591278,
-0.08597732335329056,
0.0336928553879261,
0.02423677407205105,
-0.0030474048107862473,
-0.0027802838012576103,
0.03814487159252167,
-0.020835433155298233,
-0.03607913479208946,
0.029650423675775528,
-0.03602571040391922,
0.019535444676876068,
-0.002969494555145502,
0.056772105395793915,
-0.01541287824511528,
0.014023849740624428,
-0.016490265727043152
]
|
32,386 | bqplot.marks | Bins | Backend histogram mark.
A `Bars` instance that bins sample data.
It is very similar in purpose to the `Hist` mark, the difference being that
the binning is done in the backend (python), which avoids large amounts of
data being shipped back and forth to the frontend. It should therefore be
preferred for large data.
The binning method is the numpy `histogram` method.
The following documentation is in part taken from the numpy documentation.
Attributes
----------
icon: string (class-level attribute)
font-awesome icon for that mark
name: string (class-level attribute)
user-friendly name of the mark
bins: nonnegative int (default: 10)
or {'auto', 'fd', 'doane', 'scott', 'rice', 'sturges', 'sqrt'}
If `bins` is an int, it defines the number of equal-width
bins in the given range (10, by default).
If `bins` is a string (method name), `histogram` will use
the method chosen to calculate the optimal bin width and
consequently the number of bins (see `Notes` for more detail on
the estimators) from the data that falls within the requested
range.
density : bool (default: `False`)
If `False`, the height of each bin is the number of samples in it.
If `True`, the height of each bin is the value of the
probability *density* function at the bin, normalized such that
the *integral* over the range is 1. Note that the sum of the
histogram values will not be equal to 1 unless bins of unity
width are chosen; it is not a probability *mass* function.
min : float (default: None)
The lower range of the bins. If not provided, lower range
is simply `x.min()`.
max : float (default: None)
The upper range of the bins. If not provided, lower range
is simply `x.max()`.
Data Attributes
sample: numpy.ndarray (default: [])
sample of which the histogram must be computed.
Notes
-----
The fields which can be passed to the default tooltip are:
All the `Bars` data attributes (`x`, `y`, `color`)
index: index of the bin
| class Bins(Bars):
"""Backend histogram mark.
A `Bars` instance that bins sample data.
It is very similar in purpose to the `Hist` mark, the difference being that
the binning is done in the backend (python), which avoids large amounts of
data being shipped back and forth to the frontend. It should therefore be
preferred for large data.
The binning method is the numpy `histogram` method.
The following documentation is in part taken from the numpy documentation.
Attributes
----------
icon: string (class-level attribute)
font-awesome icon for that mark
name: string (class-level attribute)
user-friendly name of the mark
bins: nonnegative int (default: 10)
or {'auto', 'fd', 'doane', 'scott', 'rice', 'sturges', 'sqrt'}
If `bins` is an int, it defines the number of equal-width
bins in the given range (10, by default).
If `bins` is a string (method name), `histogram` will use
the method chosen to calculate the optimal bin width and
consequently the number of bins (see `Notes` for more detail on
the estimators) from the data that falls within the requested
range.
density : bool (default: `False`)
If `False`, the height of each bin is the number of samples in it.
If `True`, the height of each bin is the value of the
probability *density* function at the bin, normalized such that
the *integral* over the range is 1. Note that the sum of the
histogram values will not be equal to 1 unless bins of unity
width are chosen; it is not a probability *mass* function.
min : float (default: None)
The lower range of the bins. If not provided, lower range
is simply `x.min()`.
max : float (default: None)
The upper range of the bins. If not provided, lower range
is simply `x.max()`.
Data Attributes
sample: numpy.ndarray (default: [])
sample of which the histogram must be computed.
Notes
-----
The fields which can be passed to the default tooltip are:
All the `Bars` data attributes (`x`, `y`, `color`)
index: index of the bin
"""
# Mark decoration
icon = 'fa-signal'
name = 'Backend Histogram'
# Scaled Attributes
sample = Array([]).tag(
sync=False, display_name='Sample', rtype='Number',
atype='bqplot.Axis', **array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
# Binning options
min = Float(None, allow_none=True).tag(sync=True)
max = Float(None, allow_none=True).tag(sync=True)
density = Bool().tag(sync=True)
bins = (Int(10) | List() | Enum(['auto', 'fd', 'doane',
'scott', 'rice', 'sturges', 'sqrt']))\
.tag(sync=True, display_name='Number of bins')
def __init__(self, **kwargs):
'''
Sets listeners on the data and the binning parameters.
Adjusts `Bars` defaults to suit a histogram better.
'''
self.observe(self.bin_data,
names=['sample', 'bins', 'density', 'min', 'max'])
# One unique color by default
kwargs.setdefault('colors', [CATEGORY10[0]])
# No spacing between bars
kwargs.setdefault('padding', 0.)
super(Bins, self).__init__(**kwargs)
def bin_data(self, *args):
'''
Performs the binning of `sample` data, and draws the corresponding bars
'''
# Get range
_min = self.sample.min() if self.min is None else self.min
_max = self.sample.max() if self.max is None else self.max
_range = (min(_min, _max), max(_min, _max))
# Bin the samples
counts, bin_edges = histogram(self.sample, bins=self.bins,
range=_range, density=self.density)
midpoints = (bin_edges[:-1] + bin_edges[1:]) / 2
# Redraw the underlying Bars
with self.hold_sync():
self.x, self.y = midpoints, counts
| (**kwargs) | [
0.0044245910830795765,
-0.07450348883867264,
-0.06500127166509628,
-0.0055271899327635765,
0.0040554809384047985,
-0.017102109268307686,
-0.08010639995336533,
0.060117654502391815,
-0.017821401357650757,
-0.043157510459423065,
-0.01625031791627407,
0.06363839656114578,
0.0016314201056957245,
-0.02140839770436287,
-0.07052845507860184,
-0.014168156310915947,
0.03308742493391037,
0.027276303619146347,
0.016657285392284393,
0.02629200927913189,
-0.028733815997838974,
0.011196345090866089,
-0.011366704478859901,
0.02184375748038292,
0.0013758823042735457,
0.04463395103812218,
-0.006483091041445732,
-0.052016157656908035,
-0.005285848863422871,
0.02375555969774723,
-0.017092645168304443,
-0.05746763199567795,
0.028449885547161102,
-0.007192918565124273,
0.05883050337433815,
-0.085482157766819,
0.02419092133641243,
0.05394688993692398,
-0.034809939563274384,
0.06223767250776291,
0.05318973958492279,
-0.08517929911613464,
0.07813780754804611,
-0.023604130372405052,
0.08086354285478592,
0.03933390602469444,
0.010003834962844849,
0.0224873349070549,
-0.016146209090948105,
-0.04183249920606613,
0.019004447385668755,
-0.046488966792821884,
0.02227911911904812,
0.028430957347154617,
-0.037592463195323944,
0.09426508843898773,
0.04853327199816704,
0.05080471932888031,
0.012227961793541908,
0.07821352034807205,
-0.012862074188888073,
0.06719700247049332,
0.06818129867315292,
-0.09668796509504318,
-0.013941011391580105,
-0.02419092133641243,
-0.009417044930160046,
-0.010003834962844849,
-0.006511484272778034,
0.019875168800354004,
0.032159917056560516,
0.015578347258269787,
0.015256558544933796,
0.051334723830223083,
-0.036399953067302704,
-0.038993190973997116,
-0.03178134188055992,
0.01392208319157362,
0.04281679540872574,
-0.0006006914773024619,
0.05886835977435112,
0.01878676749765873,
0.055271901190280914,
-0.03293599560856819,
0.015464774332940578,
-0.04997185617685318,
-0.0031445357017219067,
0.05163758248090744,
0.022846980020403862,
0.007959532551467419,
-0.04595896229147911,
0.03929604962468147,
0.06136695295572281,
0.044898953288793564,
-0.022657692432403564,
-0.08737502992153168,
-0.03657031059265137,
-0.03284135088324547,
0.03456386551260948,
0.020632319152355194,
-0.026348795741796494,
-0.03492351248860359,
0.010174193419516087,
0.04531538486480713,
-0.03895533084869385,
0.035926733165979385,
-0.011054379865527153,
-0.007334883790463209,
-0.05148615315556526,
-0.0018976054852828383,
0.012682250700891018,
0.0018893241649493575,
0.0010635581566020846,
-0.023452699184417725,
-0.029642395675182343,
-0.00040253132465295494,
-0.01712103933095932,
-0.0026145312003791332,
0.025837719440460205,
-0.01867319457232952,
-0.05258401855826378,
0.013827439397573471,
0.018124261870980263,
-0.010713662952184677,
0.015985315665602684,
0.019723739475011826,
0.008745074272155762,
0.018521765246987343,
-0.05648333951830864,
0.019212663173675537,
0.020196957513689995,
-0.011574920266866684,
-0.031800270080566406,
0.021578755229711533,
0.05496903881430626,
-0.022354833781719208,
0.04531538486480713,
0.040810346603393555,
-0.02625415287911892,
0.05008542537689209,
0.06984702497720718,
0.0014468650333583355,
0.024739854037761688,
0.0008056542137637734,
-0.05318973958492279,
0.007301758509129286,
0.037081386893987656,
-0.031043121591210365,
0.019610166549682617,
-0.04031820222735405,
-0.05353045463562012,
-0.01887194626033306,
0.018171584233641624,
0.06208624318242073,
0.03395814821124077,
-0.002467833459377289,
-0.0577704943716526,
-0.0172724686563015,
0.0033148943912237883,
0.0427410788834095,
-0.0262162946164608,
0.014045119285583496,
0.03022918663918972,
-0.07677493989467621,
-0.07874352484941483,
0.07700208574533463,
-0.01855015754699707,
0.010013299994170666,
-0.021559827029705048,
0.011555991135537624,
-0.009473830461502075,
-0.03861461579799652,
-0.028014523908495903,
0.05780835077166557,
-0.02994525618851185,
0.06708342581987381,
-0.009814548306167126,
0.023850202560424805,
0.005446742754429579,
0.02042410336434841,
0.020386245101690292,
-0.03853889927268028,
-0.04046963155269623,
-0.05780835077166557,
-0.03717603161931038,
-0.00406021298840642,
0.061745528131723404,
-0.02748451940715313,
0.04618610814213753,
0.03272777795791626,
-0.016941215842962265,
-0.016467997804284096,
0.032954923808574677,
0.022392690181732178,
0.020670175552368164,
-0.012246889993548393,
-0.0033480196725577116,
-0.010193122550845146,
0.034809939563274384,
-0.019913027063012123,
0.039977483451366425,
0.02975596860051155,
0.04183249920606613,
-0.0045263334177434444,
0.04891184717416763,
0.011395096778869629,
0.040999636054039,
0.007453188765794039,
-0.05708905681967735,
-0.04266536235809326,
-0.05421189218759537,
-0.06280553340911865,
-0.04342251271009445,
-0.00232823402620852,
0.01696014404296875,
-0.013250112533569336,
0.058414068073034286,
-0.03229241818189621,
-0.016146209090948105,
-0.013884225860238075,
0.09184221178293228,
0.016477461904287338,
-0.031364910304546356,
0.03781960904598236,
-0.03445029258728027,
0.033466000109910965,
0.07011202722787857,
0.004410394933074713,
0.06666699796915054,
-0.03145955502986908,
-0.017215682193636894,
-0.004377269651740789,
0.0006293803453445435,
0.006161302328109741,
-0.07408706098794937,
-0.006908987648785114,
0.0453532449901104,
0.01787818782031536,
0.00006791422492824495,
0.033825647085905075,
0.016269246116280556,
0.028904175385832787,
0.02506164275109768,
-0.01918427087366581,
-0.03575637564063072,
-0.030210258439183235,
0.020405173301696777,
0.03895533084869385,
-0.02716273069381714,
-0.03320099785923958,
-0.018720516934990883,
-0.03507494181394577,
0.024683067575097084,
-0.038633543998003006,
0.0827564224600792,
-0.004519234877079725,
-0.012767430394887924,
-0.05337902531027794,
0.018105333670973778,
0.003975033760070801,
-0.024645209312438965,
-0.04031820222735405,
0.019894098863005638,
0.07571493089199066,
0.01786872372031212,
0.019439809024333954,
0.031875986605882645,
0.011489740572869778,
-0.018162118270993233,
0.03850104287266731,
-0.001588830491527915,
0.01699800230562687,
-0.03225456178188324,
-0.037592463195323944,
-0.024342350661754608,
0.027503449469804764,
0.07155060768127441,
-0.015133521519601345,
-0.009488027542829514,
-0.024361278861761093,
-0.011224738322198391,
-0.04122678190469742,
0.053568314760923386,
-0.03316314145922661,
0.06965773552656174,
-0.040734633803367615,
-0.006175498943775892,
-0.029964184388518333,
0.0061944276094436646,
-0.0188246238976717,
-0.0016195897478610277,
-0.008872843347489834,
-0.044861096888780594,
0.0049451314844191074,
0.0188246238976717,
-0.016950679942965508,
-0.0006086770445108414,
-0.007997389882802963,
-0.036248523741960526,
-0.03855782747268677,
0.009918656200170517,
-0.05485546588897705,
0.06420626491308212,
0.03594566509127617,
-0.025213072076439857,
-0.018332477658987045,
0.09835369884967804,
-0.030323829501867294,
-0.001733162091113627,
-0.019572310149669647,
0.03030490130186081,
0.056937627494335175,
0.04016676917672157,
0.011063843965530396,
-0.04682968556880951,
-0.006965773645788431,
0.00418088398873806,
0.005877371411770582,
-0.011574920266866684,
0.07476849108934402,
-0.04338465631008148,
-0.004164321348071098,
-0.021559827029705048,
-0.012833680957555771,
0.01489691250026226,
0.03287920728325844,
-0.0006063109613023698,
0.011385632678866386,
-0.04701897129416466,
-0.0200644563883543,
0.0000931648537516594,
-0.019894098863005638,
0.03446922078728676,
0.008366500027477741,
0.000276980601483956,
0.0012516624992713332,
-0.0012930691009387374,
0.0012433811789378524,
-0.02581879124045372,
-0.07912210375070572,
0.011451883241534233,
-0.020840534940361977,
0.00903846975415945,
0.05398474633693695,
-0.006994166877120733,
-0.030929548665881157,
0.03770603612065315,
-0.008304981514811516,
0.020196957513689995,
0.08676931262016296,
0.05004756897687912,
0.03278456628322601,
-0.0034071719273924828,
0.01759425736963749,
0.05424974858760834,
-0.09237221628427505,
0.003156366292387247,
-0.025724148377776146,
-0.051978301256895065,
0.0017840330256149173,
-0.00022167321003507823,
-0.005186473019421101,
-0.006014605052769184,
0.041416067630052567,
-0.028809530660510063,
0.01664782129228115,
-0.03410957753658295,
0.02411520481109619,
-0.03844425454735756,
-0.0023720068857073784,
0.027938809245824814,
-0.039031047374010086,
-0.045618247240781784,
0.02915024943649769,
0.03412850573658943,
-0.000841737084556371,
-0.00911418441683054,
-0.01124366745352745,
0.009842940606176853,
-0.02661379799246788,
0.053719744086265564,
0.01538905967026949,
-0.03681638464331627,
0.024720925837755203,
-0.005020846147090197,
-0.002225309144705534,
-0.0143195865675807,
-0.03808461129665375,
0.003743157023563981,
-0.03450708091259003,
0.022298047319054604,
-0.05500689893960953,
-0.04031820222735405,
-0.014877984300255775,
-0.10766663402318954,
-0.05970122292637825,
0.04372537136077881,
0.023093054071068764,
0.042286790907382965,
-0.011688492260873318,
0.017849795520305634,
-0.04667825624346733,
0.0202537439763546,
0.016666749492287636,
0.014016726985573769,
-0.035093870013952255,
0.035926733165979385,
-0.01676139235496521,
0.0011617509881034493,
0.011347775347530842,
-0.014234406873583794,
0.015464774332940578,
-0.01902337558567524,
0.028033453971147537,
0.028147025033831596,
-0.04452037811279297,
-0.013022968545556068,
-0.08010639995336533,
0.0018845919985324144,
-0.027863094583153725,
-0.0029623466543853283,
0.0788949579000473,
0.056899771094322205,
0.00764720793813467,
0.0449746698141098,
-0.026064865291118622,
-0.031838130205869675,
-0.01104491576552391,
0.0010487701511010528,
0.005465671420097351,
0.02506164275109768,
-0.028620243072509766,
-0.07866781204938889,
-0.013392078690230846,
-0.04198392853140831,
-0.025686290115118027,
-0.0224873349070549,
-0.025629503652453423,
0.04929041862487793,
-0.002111736685037613,
-0.01970481127500534,
0.0033432873897254467,
0.06768915057182312,
-0.023149840533733368,
-0.04743540287017822,
-0.01378011703491211,
-0.04028034210205078,
-0.018143190070986748,
0.03532101586461067,
-0.05962551012635231,
-0.004206910729408264,
0.007173989899456501,
0.03532101586461067,
0.019950883463025093,
-0.02010231465101242,
-0.064357690513134,
-0.012947252951562405,
-0.06685628741979599,
-0.0071976506151258945,
0.015218701213598251,
-0.0020786114037036896,
0.038387469947338104,
-0.06678056716918945,
-0.03533994406461716,
-0.016231387853622437,
-0.013959940522909164,
0.053568314760923386,
-0.011925101280212402,
-0.010884021408855915,
0.05035042762756348,
0.043195366859436035,
0.017168359830975533,
0.005186473019421101,
0.012625465169548988,
-0.02082160674035549,
0.008125158958137035,
0.003688736818730831,
-0.005181740503758192,
-0.0679541528224945,
-0.03666495531797409,
0.038387469947338104,
-0.02517521381378174,
-0.008006853982806206,
0.018455514684319496,
-0.0011043732520192862,
0.009956513531506062,
0.0341663621366024,
0.0054278140887618065,
0.0510697215795517,
0.0016917554894462228,
-0.022108759731054306,
0.004741647746413946,
-0.0002731356944423169,
0.041491784155368805,
-0.021673399955034256,
0.041567496955394745,
0.06776486337184906,
-0.012597071938216686,
0.018853018060326576,
-0.037478890269994736,
-0.0034734224900603294,
-0.014745483174920082,
-0.021389467641711235,
-0.03687317296862602,
0.00466829864308238,
-0.0519404411315918,
-0.016543712466955185,
0.014139763079583645,
-0.05095614865422249,
-0.05175115540623665,
-0.042286790907382965,
-0.049631137400865555,
0.017802473157644272,
0.016969608142971992,
-0.00846114382147789,
-0.04690539836883545,
-0.027276303619146347,
0.0012753233313560486,
-0.0014433158794417977,
-0.01417762041091919,
0.02133268117904663,
0.027427732944488525,
-0.018408192321658134,
-0.06507698446512222,
-0.008309713564813137,
-0.023490557447075844,
0.002292742719873786,
-0.03967462480068207,
0.014338514767587185,
0.019118020310997963,
-0.011376168578863144,
-0.006965773645788431,
0.0200644563883543,
0.011054379865527153,
-0.0038117736112326384,
0.047851838171482086,
-0.02061339095234871,
-0.02756023406982422,
0.04190821573138237,
0.01966695301234722,
0.012123852968215942,
0.0072970264591276646,
0.056748341768980026,
-0.017130503430962563,
0.0467161126434803,
0.03844425454735756,
0.008943825960159302,
0.006719700060784817,
0.06416840106248856,
-0.012067067436873913,
0.043157510459423065,
-0.0007062783697620034,
0.04811684042215347,
-0.03645673766732216,
0.014026191085577011,
-0.012379391118884087,
-0.029528822749853134,
0.004452984314411879,
0.030456330627202988,
0.04989613965153694,
-0.03539672866463661,
0.0660991370677948,
-0.0008997063268907368,
-0.021351611241698265,
-0.011470812372863293,
0.06481198221445084,
-0.009407579898834229,
0.023604130372405052,
-0.011546527035534382,
-0.03569959104061127,
-0.0018266227561980486,
0.03530208766460419,
-0.02014017105102539,
-0.0002191592357121408,
0.021389467641711235,
0.05311402305960655,
-0.002058499725535512,
-0.020954107865691185,
-0.06333553791046143,
-0.08245356380939484,
-0.01791604608297348,
0.05091829225420952,
-0.03736531734466553,
-0.05920907482504845,
0.010912414640188217,
0.03074026294052601,
-0.07389777153730392,
0.02343377098441124,
0.028052382171154022,
0.024758782237768173,
-0.0065446095541119576,
-0.008844450116157532,
-0.0413782112300396,
-0.05970122292637825,
0.057581204921007156,
0.04111320897936821,
-0.07798638194799423,
-0.09214507043361664,
-0.03134598210453987,
-0.005456207320094109,
0.056824054569005966,
0.048003267496824265,
-0.0577704943716526,
0.015616204589605331,
0.05004756897687912,
0.012824216857552528,
0.04217321798205376,
-0.05394688993692398,
-0.03240599110722542,
-0.038198184221982956,
-0.04857112839818001,
0.026386654004454613,
-0.0013841636246070266,
0.019439809024333954,
-0.002383837243542075,
-0.05799763649702072,
-0.012294212356209755,
-0.034223150461912155,
0.03887961804866791,
0.04754897579550743,
0.01700746640563011,
-0.008721414022147655,
0.02065124735236168,
0.013941011391580105,
-0.018493371084332466,
-0.07881924510002136,
0.02491021156311035,
-0.024493779987096786,
0.00864096637815237,
-0.0515618696808815,
0.021597683429718018,
-0.018739445134997368,
0.059284791350364685,
-0.04929041862487793,
0.04020462930202484,
0.0015545221976935863,
0.002401582896709442,
-0.0027872559148818254,
0.020916249603033066,
0.045504674315452576,
0.0072970264591276646,
-0.0586412139236927,
-0.001011504209600389,
0.04183249920606613,
-0.0019555746112018824,
-0.03337135538458824,
-0.031232409179210663,
0.018417656421661377,
0.019013911485671997,
-0.014130298979580402,
0.011234203353524208,
-0.00001702476765785832,
-0.06136695295572281,
0.012029210105538368,
-0.016174601390957832,
0.053568314760923386,
0.055953335016965866,
-0.024569494649767876,
-0.012559214606881142,
0.00323208118788898,
-0.03944747895002365,
0.010354016907513142,
-0.005295312963426113,
0.038425326347351074,
0.006819075904786587,
-0.0006625056266784668,
-0.008352302946150303,
0.02014017105102539,
0.023130912333726883,
0.011262595653533936,
0.044898953288793564,
0.015341738238930702,
-0.08487644046545029,
-0.0674620047211647,
-0.04205964505672455,
-0.0023365153465420008,
-0.001801778795197606,
0.0401289127767086,
-0.0067291646264493465,
-0.043119654059410095,
0.027787379920482635,
-0.007107739336788654,
-0.028052382171154022,
0.05023685842752457,
0.060988377779722214,
0.09017648547887802,
-0.001228001550771296,
-0.04618610814213753,
-0.056937627494335175,
-0.01970481127500534,
0.010372946038842201,
-0.032197773456573486,
0.0550447553396225,
-0.02513735741376877,
-0.007912210188806057,
-0.004062579479068518,
-0.03821711242198944,
-0.07548778504133224,
0.025799863040447235,
-0.07965210825204849,
0.05258401855826378,
-0.03689210116863251,
0.004372537136077881,
0.040583204478025436,
0.004907274153083563,
0.03034275956451893,
-0.04766254872083664,
-0.03026704303920269,
0.03547244518995285,
0.031838130205869675,
0.022222332656383514,
0.08381643146276474,
0.016865501180291176,
-0.024039490148425102,
0.02935846522450447,
-0.016856037080287933,
-0.01855015754699707,
0.005546118598431349,
-0.012502428144216537,
-0.005588708445429802,
-0.0057969242334365845,
0.03248170390725136,
0.007789173629134893,
0.008196141570806503,
-0.003253375878557563,
0.00008347866969415918,
0.04542895779013634,
-0.00945490226149559,
-0.048078980296850204,
-0.019165342673659325,
0.029169177636504173,
-0.012606536038219929,
-0.021578755229711533,
-0.00685220118612051,
0.013590830378234386,
-0.010827234946191311,
0.02903667651116848,
-0.01596638560295105,
0.08290784806013107,
-0.001705951988697052,
-0.011158487759530544,
-0.06204838678240776,
-0.043081797659397125,
0.018294619396328926,
0.03812246769666672,
-0.0011215273989364505,
0.025667361915111542,
0.030058827251195908,
0.029225964099168777,
-0.019534451887011528,
0.03929604962468147,
0.030172400176525116,
-0.06269196420907974,
0.03757353499531746,
0.04118892177939415,
-0.017688900232315063,
0.032670993357896805,
-0.013174397870898247,
-0.0035822626668959856,
-0.05977693945169449,
0.008233998902142048,
-0.0003185350797139108,
0.030285973101854324,
-0.017688900232315063,
0.05636976659297943,
0.060269083827733994,
-0.014196549542248249,
0.0607612319290638
]
|
32,391 | bqplot.marks | __init__ |
Sets listeners on the data and the binning parameters.
Adjusts `Bars` defaults to suit a histogram better.
| def __init__(self, **kwargs):
'''
Sets listeners on the data and the binning parameters.
Adjusts `Bars` defaults to suit a histogram better.
'''
self.observe(self.bin_data,
names=['sample', 'bins', 'density', 'min', 'max'])
# One unique color by default
kwargs.setdefault('colors', [CATEGORY10[0]])
# No spacing between bars
kwargs.setdefault('padding', 0.)
super(Bins, self).__init__(**kwargs)
| (self, **kwargs) | [
-0.045462820678949356,
-0.030502380803227425,
-0.04539233446121216,
-0.025744644924998283,
-0.020881179720163345,
-0.000897031684871763,
-0.06230873614549637,
0.06280212849378586,
0.009383315220475197,
0.008612385019659996,
-0.03543633222579956,
0.0868375152349472,
0.024863582104444504,
-0.04225575551390648,
-0.043806422501802444,
-0.00026197839179076254,
0.017154285684227943,
0.031964946538209915,
0.024334944784641266,
0.017823893576860428,
-0.03450240567326546,
-0.02784157171845436,
-0.027894435450434685,
0.051559772342443466,
0.009171860292553902,
0.026678569614887238,
-0.05064346641302109,
-0.05385053530335426,
-0.019912010058760643,
0.03168300539255142,
-0.054590627551078796,
-0.06481095403432846,
0.02162127196788788,
0.021497923880815506,
0.04789455235004425,
-0.05258180573582649,
0.013753384351730347,
0.03224688395857811,
-0.0543791726231575,
0.07548943161964417,
0.05349811166524887,
-0.07689912617206573,
0.010096975602209568,
0.024599263444542885,
0.07534845918416977,
0.02354198880493641,
0.01493400800973177,
0.021903211250901222,
-0.008885514922440052,
-0.04271390661597252,
-0.02683716081082821,
-0.014793038368225098,
0.0304495170712471,
0.048599403351545334,
0.0036806382704526186,
0.07090790569782257,
0.029920879751443863,
0.06213252246379852,
0.009030889719724655,
0.09092564135789871,
-0.03883723169565201,
0.04038790240883827,
0.04475796967744827,
-0.10347197204828262,
-0.019577207043766975,
-0.06047612428665161,
-0.01871376670897007,
0.02354198880493641,
0.011207113973796368,
0.017700543627142906,
0.03661695495247841,
0.015400971285998821,
0.022872380912303925,
0.06918102502822876,
-0.039894506335258484,
-0.04733067378401756,
-0.04694300517439842,
0.03908392786979675,
0.014986871741712093,
0.045462820678949356,
0.05871399864554405,
0.006497835274785757,
0.028158755972981453,
0.009339261800050735,
0.0238944124430418,
-0.08169210702180862,
-0.028387831524014473,
0.048634644597768784,
0.0348900705575943,
0.007242333143949509,
-0.04521612450480461,
0.03859053552150726,
0.016916397958993912,
0.027823951095342636,
-0.023365775123238564,
-0.043383512645959854,
-0.03837908059358597,
0.021427437663078308,
0.03841432183980942,
-0.015806259587407112,
-0.04652009531855583,
-0.05148928984999657,
0.02461688406765461,
0.04144517704844475,
-0.04211478307843208,
-0.002484596101567149,
-0.00868287030607462,
-0.008537494577467442,
-0.06477571278810501,
0.025674158707261086,
0.04253769293427467,
0.002356841927394271,
0.03129533678293228,
-0.007986830547451973,
-0.04482845589518547,
0.02454639971256256,
-0.014158673584461212,
-0.04574476182460785,
0.005986819043755531,
-0.013083777390420437,
-0.04567427560687065,
0.01041415799409151,
0.04842318966984749,
0.030079470947384834,
-0.0015484672039747238,
0.06058185175061226,
-0.03351561352610588,
0.010264377109706402,
-0.026290902867913246,
0.05307520180940628,
0.05490780994296074,
-0.06093427538871765,
-0.0217093788087368,
-0.010167459957301617,
0.07214139401912689,
-0.05843206122517586,
0.03110150434076786,
0.06509289145469666,
0.012484654784202576,
0.042854875326156616,
0.06689026206731796,
0.02565653808414936,
-0.0006861273432150483,
-0.005330427549779415,
-0.03032616898417473,
0.03217640146613121,
0.0012070555239915848,
-0.011700509116053581,
-0.006911934819072485,
-0.041938573122024536,
-0.0651986226439476,
-0.009559527039527893,
-0.000738991133403033,
0.03397376835346222,
0.058573029935359955,
-0.0037290966138243675,
-0.04253769293427467,
-0.03300459682941437,
0.012951618060469627,
0.030801942571997643,
0.0036167611833661795,
0.02112787775695324,
0.05085492134094238,
-0.07711058109998703,
-0.06801801919937134,
0.071507029235363,
-0.027365798130631447,
-0.0068502603098750114,
-0.0114097585901618,
0.017321687191724777,
0.012431791052222252,
-0.04701349139213562,
-0.01207936555147171,
0.05089016631245613,
-0.012088176794350147,
0.03221164271235466,
0.004301787354052067,
0.009964816272258759,
0.0014416383346542716,
0.04644961282610893,
0.02967418171465397,
-0.023013349622488022,
-0.01874900795519352,
-0.010581559501588345,
-0.00483262725174427,
-0.04969191923737526,
0.04306633025407791,
-0.018167506903409958,
0.0030066254548728466,
-0.0007406431250274181,
0.03746277466416359,
-0.009770981967449188,
-0.0015418592374771833,
-0.007158632390201092,
0.03585924208164215,
-0.02289000153541565,
0.006440566387027502,
-0.0371103510260582,
0.007378897629678249,
-0.04669630900025368,
0.03883723169565201,
-0.005330427549779415,
0.014528719708323479,
0.026907647028565407,
0.04211478307843208,
0.005229105707257986,
0.04412360489368439,
0.038097139447927475,
-0.014678499661386013,
-0.06643210351467133,
0.0035815187729895115,
-0.034255705773830414,
0.026290902867913246,
0.021268846467137337,
-0.0050440821796655655,
-0.018731387332081795,
-0.02292524464428425,
-0.04063459858298302,
-0.021427437663078308,
-0.020563997328281403,
0.05018531531095505,
0.02542746067047119,
-0.002511027967557311,
0.022414227947592735,
-0.040705084800720215,
0.033039841800928116,
0.06657307595014572,
-0.03781519830226898,
0.06178009882569313,
0.008215907029807568,
-0.017030935734510422,
-0.0011938395909965038,
-0.011462622322142124,
0.02422921732068062,
-0.07023829966783524,
0.009286398068070412,
0.019612450152635574,
0.006057304330170155,
-0.029321758076548576,
-0.0011607997585088015,
0.012105797417461872,
0.006211489904671907,
0.027242450043559074,
-0.01940099522471428,
0.0031189608853310347,
-0.017806271091103554,
0.027330556884407997,
0.046837277710437775,
-0.026220418512821198,
-0.0033700638450682163,
-0.011744562536478043,
-0.032229263335466385,
-0.001270932494662702,
-0.014757795259356499,
0.05698711797595024,
-0.02370058000087738,
-0.05476684123277664,
-0.017427414655685425,
0.007770970463752747,
-0.03799141198396683,
-0.03862577676773071,
0.01901332661509514,
0.0013381135649979115,
0.100441113114357,
0.03459051251411438,
0.012625624425709248,
0.02925127185881138,
0.004568308591842651,
-0.020916422829031944,
0.012396547943353653,
0.06269640475511551,
0.005083729978650808,
0.006753343623131514,
-0.031418684870004654,
-0.02845831587910652,
-0.002779752016067505,
0.07231760025024414,
-0.041127994656562805,
0.013074966147542,
0.013841490261256695,
0.03774471580982208,
-0.005026461090892553,
0.020264435559511185,
-0.007427356205880642,
0.04891658574342728,
-0.01411462016403675,
0.004753331653773785,
-0.019348131492733955,
-0.03654646873474121,
-0.02289000153541565,
0.01238773763179779,
-0.022326121106743813,
0.004907517693936825,
0.032881248742341995,
-0.011497864499688148,
-0.03462575376033783,
0.04098702222108841,
0.009295208379626274,
-0.04750688746571541,
-0.006863476242870092,
0.0013204923598095775,
-0.08451151102781296,
0.05173598602414131,
0.0012213727459311485,
-0.04652009531855583,
-0.007854671217501163,
0.0827493816614151,
-0.0038854852318763733,
0.007453788071870804,
-0.01890759915113449,
0.04930425435304642,
0.04648485407233238,
0.027964921668171883,
0.02895171195268631,
-0.07094314694404602,
0.00334583455696702,
0.005810606759041548,
-0.021215982735157013,
-0.012969238683581352,
0.08549829572439194,
-0.048141252249479294,
-0.016158685088157654,
-0.04539233446121216,
-0.03106626123189926,
0.008167448453605175,
0.04514563828706741,
0.0371103510260582,
0.018696144223213196,
-0.037286560982465744,
-0.007118984591215849,
-0.00999124813824892,
-0.017656490206718445,
0.05522499233484268,
-0.00362336914986372,
-0.021568408235907555,
-0.023401018232107162,
-0.00496478658169508,
0.017823893576860428,
-0.00727757578715682,
-0.0672074407339096,
0.00018240745703224093,
-0.031242473050951958,
0.017973672598600388,
0.057233814150094986,
0.04091653972864151,
-0.007991236634552479,
0.004753331653773785,
-0.00992957316339016,
0.024282081052660942,
0.03859053552150726,
0.02657284215092659,
0.03792092576622963,
-0.026149932295084,
0.03788568452000618,
0.07682864367961884,
-0.04482845589518547,
0.03321605175733566,
-0.0500795878469944,
-0.02112787775695324,
-0.011550728231668472,
0.023171940818428993,
0.03192970156669617,
-0.007969209924340248,
0.01822037063539028,
0.020423026755452156,
0.052863746881484985,
0.01336571667343378,
0.01943623647093773,
-0.004405312240123749,
-0.020370163023471832,
0.018149886280298233,
-0.03971829265356064,
-0.0347491018474102,
0.04740116000175476,
0.011277599260210991,
-0.02921603061258793,
-0.019612450152635574,
-0.029973743483424187,
0.03830859437584877,
-0.029815152287483215,
0.01411462016403675,
0.003821608377620578,
-0.04736591503024101,
0.01656397432088852,
-0.016502298414707184,
0.00020677433349192142,
-0.07115460187196732,
-0.016326086595654488,
0.006775369867682457,
-0.027665359899401665,
0.04169187322258949,
-0.007643216755241156,
-0.024334944784641266,
-0.00044080655789002776,
-0.08232647180557251,
-0.04743640124797821,
0.06283736974000931,
-0.0010209310567006469,
0.039401110261678696,
-0.006911934819072485,
-0.009541906416416168,
-0.08176258951425552,
-0.012052933685481548,
0.008295202627778053,
-0.0027334962505847216,
-0.014881144277751446,
0.004110156092792749,
-0.026555221527814865,
0.04059935733675957,
-0.03622928634285927,
0.027594875544309616,
0.029956122860312462,
-0.007317223586142063,
0.0185551755130291,
0.03071383573114872,
-0.027894435450434685,
-0.004669630900025368,
-0.1045292466878891,
0.013453823514282703,
-0.05578887090086937,
-0.015973661094903946,
0.07746300846338272,
0.07133081555366516,
0.01336571667343378,
0.06946296244859695,
-0.009779793210327625,
0.004898706916719675,
-0.013189504854381084,
0.036757923662662506,
-0.013929597102105618,
-0.007444977294653654,
-0.01809702254831791,
-0.0871899351477623,
-0.031048640608787537,
0.0060837361961603165,
0.008453793823719025,
-0.030379032716155052,
-0.006013250909745693,
0.02852880209684372,
0.028088269755244255,
-0.04165663197636604,
-0.028123512864112854,
0.06794753670692444,
-0.02454639971256256,
-0.04891658574342728,
-0.031119124963879585,
-0.030925290659070015,
-0.023612473160028458,
0.0020958271343261003,
-0.07316341996192932,
-0.01338333822786808,
-0.01770935393869877,
0.008211501874029636,
0.005149809643626213,
-0.0014074972132220864,
-0.04976240545511246,
-0.0652691051363945,
-0.01763886958360672,
0.021462680771946907,
-0.02334815450012684,
0.007057310082018375,
-0.007982425391674042,
-0.09092564135789871,
-0.05254656448960304,
-0.031964946538209915,
-0.02213228866457939,
0.04475796967744827,
-0.002170717576518655,
-0.0005842545069754124,
0.06851141154766083,
0.011066144332289696,
0.044581759721040726,
0.011726940982043743,
-0.002550675766542554,
-0.03622928634285927,
0.00895159412175417,
0.0033304160460829735,
-0.017506711184978485,
-0.05518975108861923,
-0.00006793817010475323,
0.038097139447927475,
0.005198268219828606,
0.01920716091990471,
0.016863534227013588,
-0.04045838490128517,
0.025022173300385475,
-0.00911018531769514,
-0.011841478757560253,
0.03563016280531883,
0.022713789716362953,
-0.01069609820842743,
0.01641419343650341,
-0.01878425106406212,
0.020176328718662262,
0.005158620420843363,
0.030502380803227425,
0.0696391761302948,
0.018801871687173843,
0.02845831587910652,
0.017929621040821075,
-0.009092563763260841,
0.014044134877622128,
-0.014960439875721931,
-0.04824697971343994,
-0.027894435450434685,
-0.058960698544979095,
-0.03404425084590912,
0.012713730335235596,
-0.04997386038303375,
-0.030132334679365158,
0.017515521496534348,
-0.05536596104502678,
-0.016423003748059273,
0.013233557343482971,
0.018202750012278557,
-0.04821173474192619,
-0.036793168634176254,
0.008766571059823036,
-0.036299772560596466,
-0.0020000117365270853,
0.027348177507519722,
0.03427333012223244,
0.01874900795519352,
-0.062484946101903915,
-0.006171842105686665,
-0.02526886947453022,
-0.015788638964295387,
-0.020810695365071297,
-0.006211489904671907,
0.03178873285651207,
0.0008012161124497652,
-0.012898754328489304,
-0.014828280545771122,
0.03249358385801315,
-0.009938384406268597,
0.037638988345861435,
-0.02653760090470314,
-0.00740973511710763,
-0.01755957491695881,
0.014370128512382507,
0.009867899119853973,
0.0009719220106489956,
0.10516361147165298,
-0.04997386038303375,
0.013127829879522324,
0.030431896448135376,
-0.00597360311076045,
0.02112787775695324,
0.04063459858298302,
0.0011563944863155484,
0.012969238683581352,
0.00740092433989048,
-0.01587674394249916,
-0.04391214996576309,
-0.009656444191932678,
-0.0028810740914195776,
-0.027753466740250587,
-0.03087242692708969,
0.02960369735956192,
0.05233510956168175,
-0.030819563195109367,
0.023612473160028458,
0.007779781240969896,
0.04496942460536957,
-0.03305746242403984,
0.04391214996576309,
0.000245320814428851,
0.0009614593582227826,
-0.06181534007191658,
-0.027101479470729828,
-0.0038854852318763733,
-0.0029119113460183144,
-0.0830313190817833,
-0.010881121270358562,
-0.01770935393869877,
0.026008963584899902,
0.03337464481592178,
-0.020581617951393127,
-0.05480208247900009,
-0.060335155576467514,
-0.03397376835346222,
0.04042314365506172,
-0.043806422501802444,
-0.062449704855680466,
0.0049868132919073105,
0.05219413712620735,
-0.03841432183980942,
-0.00334583455696702,
0.03022044152021408,
0.00868287030607462,
0.023365775123238564,
0.0032665389589965343,
-0.053780049085617065,
-0.07330439239740372,
0.02458164095878601,
0.0020726993680000305,
-0.07090790569782257,
-0.06611492484807968,
-0.026449494063854218,
0.018361341208219528,
0.031154368072748184,
0.04327778518199921,
-0.06329552084207535,
0.03191208094358444,
0.0207402091473341,
-0.02925127185881138,
0.03707510605454445,
0.0030352601315826178,
-0.042431965470314026,
-0.013321664184331894,
-0.0651281327009201,
0.015612426213920116,
0.0184846892952919,
0.05134831741452217,
0.0162996556609869,
-0.03490769490599632,
0.007537488825619221,
-0.062484946101903915,
0.04909279942512512,
0.039013445377349854,
-0.015453835017979145,
-0.006409728899598122,
-0.01340095978230238,
0.05314568430185318,
-0.025409840047359467,
-0.06385940313339233,
0.02357723005115986,
-0.028652150183916092,
-0.004506634082645178,
-0.05367432162165642,
0.0010572748724371195,
-0.005114567466080189,
0.03055524453520775,
-0.06488143652677536,
0.01943623647093773,
-0.01393840741366148,
-0.002113448455929756,
-0.019224781543016434,
0.050678711384534836,
0.004229099489748478,
0.04444078728556633,
-0.010643234476447105,
0.04736591503024101,
0.002182832220569253,
0.02197369746863842,
0.017859134823083878,
-0.047718342393636703,
0.027365798130631447,
0.023647716268897057,
-0.04969191923737526,
0.019383372738957405,
-0.029321758076548576,
-0.06939247995615005,
0.063189797103405,
0.00879740808159113,
0.051101621240377426,
0.05279326066374779,
-0.014387749135494232,
0.01822037063539028,
-0.00228195171803236,
-0.05346286669373512,
0.036370255053043365,
0.03760374337434769,
0.04426457732915878,
0.0369693785905838,
-0.013392148539423943,
-0.03300459682941437,
-0.0217093788087368,
-0.006193868815898895,
-0.0008397626224905252,
0.03293411433696747,
-0.00968287605792284,
-0.06657307595014572,
-0.027066238224506378,
-0.02415873110294342,
-0.004933949559926987,
-0.008229123428463936,
0.03524249792098999,
0.020528754219412804,
-0.04215002804994583,
-0.0018788656452670693,
-0.030766699463129044,
-0.026854783296585083,
-0.006577130872756243,
0.0829608365893364,
0.09304019063711166,
-0.06403561681509018,
-0.013180693611502647,
-0.00012272923777345568,
0.0179824847728014,
-0.005678447429090738,
-0.02350674569606781,
0.01887235790491104,
0.012378927320241928,
-0.023401018232107162,
-0.0125022754073143,
-0.058608271181583405,
-0.07654670625925064,
0.034255705773830414,
-0.05614129826426506,
0.046379126608371735,
-0.031119124963879585,
-0.038942959159612656,
0.025832749903202057,
0.018731387332081795,
-0.022942865267395973,
-0.02292524464428425,
-0.06336601078510284,
0.09000933915376663,
0.03746277466416359,
-0.012581571005284786,
0.09078466892242432,
-0.011374515481293201,
-0.02791205793619156,
-0.0035859241615980864,
0.04606194421648979,
-0.062449704855680466,
0.00414099358022213,
-0.04891658574342728,
-0.030590487644076347,
-0.010044111870229244,
0.02607944793999195,
-0.023841548711061478,
0.033656585961580276,
0.04010596126317978,
-0.020000116899609566,
0.07337488234043121,
-0.020299678668379784,
-0.01424677949398756,
-0.02412348985671997,
0.07108411937952042,
-0.05240559205412865,
-0.013947217725217342,
0.021956074982881546,
0.005823822692036629,
0.05261704698204994,
0.03459051251411438,
-0.0006547395023517311,
0.06061709299683571,
0.005471397656947374,
-0.013859111815690994,
-0.04225575551390648,
-0.0008772077853791416,
0.026555221527814865,
0.01744503527879715,
-0.01480184867978096,
0.035718269646167755,
0.031806353479623795,
0.03416759893298149,
-0.027171965688467026,
0.024105867370963097,
0.05219413712620735,
-0.02918078750371933,
0.038097139447927475,
0.004942760337144136,
-0.029057439416646957,
0.02845831587910652,
-0.014343696646392345,
0.00906613189727068,
-0.03150679171085358,
-0.00837890338152647,
0.002645389875397086,
0.02572702243924141,
-0.05927788093686104,
0.07513700425624847,
0.06639686226844788,
0.048951826989650726,
0.019348131492733955
]
|
32,418 | bqplot.marks | bin_data |
Performs the binning of `sample` data, and draws the corresponding bars
| def bin_data(self, *args):
'''
Performs the binning of `sample` data, and draws the corresponding bars
'''
# Get range
_min = self.sample.min() if self.min is None else self.min
_max = self.sample.max() if self.max is None else self.max
_range = (min(_min, _max), max(_min, _max))
# Bin the samples
counts, bin_edges = histogram(self.sample, bins=self.bins,
range=_range, density=self.density)
midpoints = (bin_edges[:-1] + bin_edges[1:]) / 2
# Redraw the underlying Bars
with self.hold_sync():
self.x, self.y = midpoints, counts
| (self, *args) | [
-0.009392044506967068,
-0.03008916601538658,
-0.019216902554035187,
-0.009582482278347015,
0.024393346160650253,
-0.0044666314497590065,
-0.0197535902261734,
0.05605795234441757,
-0.004187466576695442,
-0.004934069234877825,
-0.05917420610785484,
0.06789971888065338,
0.008959230966866016,
-0.022125406190752983,
-0.05110657215118408,
0.009348763152956963,
0.0011231499956920743,
0.04470093548297882,
-0.011235828511416912,
0.043073561042547226,
-0.022488968446850777,
0.011980266310274601,
-0.0336209200322628,
0.08012235909700394,
0.011599390767514706,
0.022315843030810356,
-0.056092578917741776,
-0.04002655670046806,
-0.0252243485301733,
-0.01360764354467392,
0.0006010691868141294,
-0.08787836879491806,
0.059278082102537155,
0.02965635433793068,
0.03711805120110512,
-0.0621519610285759,
0.029760228469967842,
0.042381059378385544,
-0.08282311260700226,
0.06592608988285065,
0.03981880471110344,
-0.09057912975549698,
0.0260553490370512,
0.04636294022202492,
0.043246686458587646,
0.025085847824811935,
0.024133658036589622,
0.027042163535952568,
-0.027925102040171623,
-0.030695104971528053,
-0.0060161021538078785,
-0.04227718338370323,
-0.00522838206961751,
0.024653034284710884,
0.04092680662870407,
0.03836455196142197,
-0.004336787387728691,
0.05411894991993904,
0.05976283177733421,
0.0781141072511673,
0.029812166467308998,
0.03985343128442764,
0.04123843088746071,
-0.07582885771989822,
0.0003040512092411518,
-0.017070148140192032,
-0.04251955822110176,
0.013633612543344498,
-0.028790727257728577,
0.026418911293148994,
0.03015841729938984,
0.05411894991993904,
0.034313421696424484,
0.06668784469366074,
-0.04670919105410576,
-0.031127918511629105,
0.0035815283190459013,
0.05581557750701904,
0.0395071804523468,
0.016775835305452347,
0.058931831270456314,
0.017580868676304817,
0.010872265323996544,
-0.006487868260592222,
-0.00815419852733612,
-0.024670347571372986,
-0.02849641442298889,
0.05723520368337631,
0.011521484702825546,
-0.018697526305913925,
-0.01744236797094345,
0.04009580612182617,
0.05605795234441757,
0.060282208025455475,
0.019874777644872665,
-0.06229046359658241,
-0.031716544181108475,
0.027925102040171623,
-0.00348847359418869,
0.015070552006363869,
-0.08413887023925781,
-0.04009580612182617,
0.028254039585590363,
0.022315843030810356,
-0.033828672021627426,
0.019961340352892876,
0.026072660461068153,
-0.021277092397212982,
-0.10643739998340607,
0.05501919984817505,
0.004990335088223219,
-0.0074660261161625385,
0.01874946430325508,
-0.012239954434335232,
-0.05720058083534241,
-0.02361428365111351,
0.01167729776352644,
0.003878005314618349,
-0.02712872438132763,
-0.008959230966866016,
0.0010793276596814394,
-0.010699139907956123,
0.02595147304236889,
0.030106479302048683,
-0.01176386047154665,
0.03576767444610596,
-0.00697694718837738,
0.014274176210165024,
-0.0966731384396553,
0.04470093548297882,
0.031301043927669525,
-0.020636528730392456,
-0.04435468837618828,
0.012378455139696598,
0.025189721956849098,
-0.041307684034109116,
0.04930606856942177,
0.011945641599595547,
0.03815680369734764,
0.0060896803624928,
0.07257410138845444,
-0.0035707082133740187,
0.047332439571619034,
-0.02513778582215309,
0.00810226146131754,
0.02378740906715393,
0.057442955672740936,
0.0038498726207762957,
0.036425549536943436,
-0.05353032425045967,
-0.03646017611026764,
0.025674473494291306,
0.014412675984203815,
0.006362352520227432,
0.018524400889873505,
-0.01652480475604534,
-0.039195556193590164,
-0.018351275473833084,
-0.029708292335271835,
0.018282026052474976,
-0.002190034370869398,
0.010846296325325966,
0.02832328900694847,
-0.059520456939935684,
-0.04141155630350113,
0.08697812259197235,
-0.001414216822013259,
0.012750674039125443,
0.01370286289602518,
-0.02958710305392742,
0.014222238212823868,
-0.022419719025492668,
-0.03273798152804375,
0.05148744583129883,
-0.005635226611047983,
-0.0033175123389810324,
-0.03317079693078995,
-0.00961710698902607,
0.0361139252781868,
0.026869038119912148,
0.02588222362101078,
-0.0453588142991066,
0.018887963145971298,
-0.034919362515211105,
-0.033136170357465744,
-0.04646681621670723,
0.03933405503630638,
-0.00815419852733612,
0.008933262899518013,
0.015226365067064762,
0.009002512320876122,
-0.045151062309741974,
-0.017676087096333504,
-0.013642269186675549,
0.045324187725782394,
-0.010179764591157436,
-0.030452730134129524,
-0.017390429973602295,
0.018801400437951088,
-0.010006639175117016,
0.05501919984817505,
-0.06582221388816833,
0.017174024134874344,
-0.005120179150253534,
0.016671961173415184,
-0.023164156824350357,
0.037602800875902176,
0.06897309422492981,
-0.010811671614646912,
-0.04009580612182617,
-0.014421332627534866,
-0.05283782258629799,
0.02226390689611435,
-0.0019346745684742928,
-0.007868542335927486,
0.036667924374341965,
0.008054652251303196,
-0.056750454008579254,
-0.0180569626390934,
-0.006622040644288063,
0.047436315566301346,
0.015373521484434605,
-0.03320541977882385,
0.04754019156098366,
-0.0015061895828694105,
0.030037229880690575,
0.06918084621429443,
-0.0298294797539711,
0.032980360090732574,
-0.02082696743309498,
0.03895317763090134,
-0.013547049835324287,
-0.012802612036466599,
-0.013183487579226494,
-0.047921065241098404,
-0.011175233870744705,
0.04556656256318092,
0.012326517142355442,
-0.003596676979213953,
0.02654009871184826,
0.02671322412788868,
0.004304326139390469,
0.01479355152696371,
-0.0772831067442894,
-0.010318264365196228,
-0.02503390982747078,
-0.0006281200330704451,
0.014646395109593868,
0.0012529939413070679,
-0.010058576241135597,
-0.0268863495439291,
0.016455553472042084,
-0.012387110851705074,
-0.015018614940345287,
0.06201346218585968,
-0.014611770398914814,
-0.02468765899538994,
-0.046259064227342606,
-0.011668641120195389,
0.003598840907216072,
0.005224054213613272,
0.016758523881435394,
0.023129532113671303,
0.05017169564962387,
0.03691030293703079,
0.011833109892904758,
-0.004752287641167641,
0.0001128019139287062,
0.03325735777616501,
0.010811671614646912,
-0.050621818751096725,
-0.013036330230534077,
0.014213582500815392,
-0.01814352534711361,
-0.018887963145971298,
0.05283782258629799,
0.10546790063381195,
-0.03344779834151268,
0.012482330203056335,
-0.010049920529127121,
0.009478607214987278,
0.019026463851332664,
0.0495484434068203,
-0.02326803281903267,
0.06755346804857254,
-0.024306783452630043,
0.016066022217273712,
0.006721587385982275,
0.006825462449342012,
-0.015312927775084972,
-0.02370084635913372,
0.01121851522475481,
-0.032824546098709106,
0.05166057124733925,
-0.023129532113671303,
-0.01226592343300581,
0.0361139252781868,
-0.03981880471110344,
-0.033482421189546585,
-0.02631503716111183,
-0.02908504009246826,
-0.07631360739469528,
0.03826067969202995,
0.037775926291942596,
0.0018740807427093387,
0.0008493956993333995,
0.054326701909303665,
-0.030141104012727737,
-0.026349661871790886,
-0.05976283177733421,
0.03729117661714554,
0.037775926291942596,
0.08226911723613739,
-0.01491473987698555,
-0.014784895814955235,
-0.016195867210626602,
0.015053239651024342,
0.026366975158452988,
-0.05418819934129715,
0.05983208492398262,
-0.05263007432222366,
-0.0029517854563891888,
0.009807544760406017,
0.03190698102116585,
0.04494331404566765,
0.07672910392284393,
-0.01838590018451214,
0.02891191467642784,
-0.05048331990838051,
0.0020601903088390827,
0.01735580526292324,
0.016490180045366287,
0.027630789205431938,
0.006505181081593037,
0.00571313314139843,
0.006920681335031986,
-0.034919362515211105,
0.04103068262338638,
-0.011815797537565231,
-0.02269671857357025,
0.013304674997925758,
-0.027786601334810257,
0.055261578410863876,
0.058447081595659256,
0.03621780127286911,
0.00353824719786644,
0.0010068315314128995,
-0.022575531154870987,
-0.0028219413943588734,
0.02503390982747078,
0.03656405210494995,
0.05027557164430618,
-0.04428543522953987,
0.004295669961720705,
0.034244172275066376,
-0.03940330445766449,
0.045670438557863235,
-0.02025565318763256,
-0.03017572872340679,
0.022471657022833824,
0.04317743703722954,
0.0008418214856646955,
-0.02496466040611267,
0.00463975640013814,
-0.007812276482582092,
0.04965231940150261,
-0.02191765606403351,
0.06253283470869064,
-0.06481809169054031,
0.036010049283504486,
0.024254845455288887,
-0.04175780713558197,
-0.056265704333782196,
0.0495830699801445,
0.020359529182314873,
0.0019249363103881478,
-0.03408835828304291,
-0.0504486970603466,
0.019684340804815292,
-0.017935775220394135,
-0.013668238185346127,
0.0243587214499712,
-0.0034560125786811113,
0.04141155630350113,
-0.009348763152956963,
-0.004211271647363901,
-0.03905705362558365,
-0.031127918511629105,
-0.01474161446094513,
-0.016516147181391716,
-0.016195867210626602,
-0.00849179271608591,
-0.02209078148007393,
-0.04470093548297882,
-0.06699946522712708,
-0.05920883268117905,
0.10242089629173279,
0.015607240609824657,
0.017174024134874344,
0.007366478908807039,
-0.005172116681933403,
-0.04854431748390198,
-0.065510593354702,
-0.00936607550829649,
0.016057366505265236,
-0.03334392234683037,
-0.027838539332151413,
-0.07846035808324814,
0.023164156824350357,
-0.036841049790382385,
0.004250224679708481,
0.0554693266749382,
0.013174830935895443,
0.05200682207942009,
0.037845179438591,
-0.030037229880690575,
-0.02721528708934784,
-0.004470959305763245,
-0.04182705655694008,
-0.010924202390015125,
0.0004836686421185732,
0.060455333441495895,
0.03201085701584816,
0.0034971297718584538,
0.016715241596102715,
-0.011720579117536545,
0.016784492880105972,
-0.03971492871642113,
0.030279604718089104,
0.02780391462147236,
-0.012568892911076546,
-0.04269268363714218,
-0.08261536806821823,
-0.0016014084685593843,
0.012239954434335232,
-0.014481926336884499,
-0.04504718631505966,
-0.00206884671933949,
0.03618317469954491,
-0.012828580103814602,
-0.03204548358917236,
-0.010274983011186123,
0.06918084621429443,
-0.05758145451545715,
-0.05536545068025589,
-0.03233979642391205,
-0.059035707265138626,
-0.05920883268117905,
0.0205845907330513,
-0.0512450709939003,
-0.037014175206422806,
-0.03512711077928543,
0.03805292770266533,
0.0028370898216962814,
-0.012326517142355442,
-0.046674564480781555,
-0.07707535475492477,
0.0025384488981217146,
0.05422282591462135,
-0.012023547664284706,
-0.010950171388685703,
-0.01698358543217182,
-0.07361285388469696,
-0.03159535676240921,
0.012222642078995705,
-0.04269268363714218,
0.060455333441495895,
-0.00032677387935109437,
-0.004488271661102772,
0.048198066651821136,
0.01311423722654581,
0.029292790219187737,
-0.010136483237147331,
0.004674381576478481,
0.03812217712402344,
-0.0012529939413070679,
-0.010482733137905598,
0.01958046481013298,
-0.005829992704093456,
-0.018593650311231613,
0.0003925073833670467,
0.010015294887125492,
-0.011408952996134758,
0.056161828339099884,
-0.058516331017017365,
0.007513635326176882,
-0.007444385439157486,
0.03050466813147068,
0.04040743038058281,
-0.016195867210626602,
0.05778920650482178,
-0.012698736041784286,
-0.035092487931251526,
-0.015139802359044552,
-0.05017169564962387,
-0.00463975640013814,
0.032963044941425323,
0.001351458951830864,
0.031474169343709946,
-0.021398279815912247,
0.014248207211494446,
-0.02974291704595089,
-0.009643075987696648,
-0.04830194264650345,
-0.024012470617890358,
0.030435416847467422,
-0.017797274515032768,
0.001691217184998095,
-0.02191765606403351,
-0.007846901193261147,
-0.018333962187170982,
-0.04972156882286072,
-0.022367781028151512,
0.0002826810523401946,
0.03981880471110344,
-0.02956979162991047,
-0.02335459552705288,
0.037775926291942596,
-0.08960962295532227,
0.009946045465767384,
0.006102664861828089,
0.02505122311413288,
-0.008976543322205544,
0.018437838181853294,
0.027959726750850677,
-0.030868230387568474,
0.0030448401812464,
-0.017667431384325027,
-0.02553597278892994,
0.020272966474294662,
-0.002008252777159214,
0.01600542850792408,
0.027163350954651833,
-0.003042676020413637,
0.0038866617251187563,
0.05269932374358177,
0.015771709382534027,
-0.052733950316905975,
-0.004691693931818008,
0.02191765606403351,
0.013469143770635128,
-0.01286320574581623,
0.0563003271818161,
-0.04913294315338135,
0.024549158290028572,
0.0340191088616848,
-0.006163258571177721,
-0.043315935879945755,
0.07285109907388687,
0.009824857115745544,
0.048024941235780716,
-0.01055198349058628,
0.00979023240506649,
0.019441964104771614,
0.03505786135792732,
-0.04161930829286575,
-0.03434804826974869,
-0.0005772644653916359,
-0.008249417878687382,
0.03246098384261131,
-0.055261578410863876,
0.018437838181853294,
0.015537990257143974,
0.028202101588249207,
-0.06793434172868729,
0.010958828032016754,
-0.0126035176217556,
0.023129532113671303,
-0.05678508058190346,
-0.017044179141521454,
-0.00979023240506649,
0.0462244376540184,
-0.051210448145866394,
-0.00927951280027628,
0.015191740356385708,
0.021986905485391617,
-0.00005521748244063929,
-0.06661859154701233,
-0.04487406089901924,
-0.026488162577152252,
-0.04660531505942345,
0.017476992681622505,
-0.02496466040611267,
-0.03211473301053047,
-0.017667431384325027,
0.02614191174507141,
-0.0453934371471405,
-0.003955911844968796,
0.021398279815912247,
0.02243703044950962,
0.011201202869415283,
-0.024635720998048782,
-0.035906173288822174,
-0.045254938304424286,
0.032305169850587845,
-0.018299337476491928,
-0.03836455196142197,
-0.07852961122989655,
-0.019268838688731194,
-0.018801400437951088,
0.04940994456410408,
0.05384194850921631,
-0.05425744876265526,
0.05287244915962219,
0.0007530947914347053,
-0.005765070673078299,
0.051799073815345764,
-0.018351275473833084,
-0.08039936423301697,
-0.018887963145971298,
-0.03836455196142197,
0.025570597499608994,
0.058273956179618835,
0.08019161224365234,
-0.011772516183555126,
-0.024601096287369728,
0.02032490260899067,
-0.03836455196142197,
0.05304557457566261,
0.04899444431066513,
0.02572641149163246,
-0.021190529689192772,
0.005198085214942694,
0.05308019742369652,
-0.012482330203056335,
-0.06949247419834137,
0.021952280774712563,
0.021657967939972878,
0.023666219785809517,
-0.015780365094542503,
-0.012975736521184444,
-0.05089882016181946,
0.03538680076599121,
-0.06357158720493317,
0.0007298311102204025,
0.01663733646273613,
-0.001412052777595818,
-0.004432006273418665,
0.017606837674975395,
-0.005133163183927536,
0.06789971888065338,
-0.037187300622463226,
0.03201085701584816,
-0.0029582774732261896,
0.03652942553162575,
-0.026020724326372147,
-0.03909168019890785,
0.005522695370018482,
-0.012915142811834812,
-0.011538797058165073,
0.0040229978039860725,
-0.03711805120110512,
-0.03767205402255058,
0.03736042603850365,
0.028254039585590363,
0.0035815283190459013,
0.053980451077222824,
0.005682835821062326,
-0.021052028983831406,
-0.0028176133055239916,
-0.055261578410863876,
0.053738076239824295,
0.027751976624131203,
0.0007087314734235406,
-0.05148744583129883,
0.016343023627996445,
-0.02141559310257435,
0.01045676413923502,
-0.00841821450740099,
0.003012379165738821,
0.08109186589717865,
0.02243703044950962,
-0.1167556643486023,
0.017018212005496025,
-0.03228785842657089,
-0.01504458300769329,
-0.020567279309034348,
-0.038780052214860916,
-0.03774130344390869,
-0.02612459845840931,
0.000004184423687547678,
-0.05169519782066345,
-0.02300834469497204,
-0.01663733646273613,
0.08039936423301697,
0.07929135859012604,
-0.03173385560512543,
-0.054084327071905136,
-0.025103159248828888,
0.033655546605587006,
0.012871861457824707,
-0.03292842209339142,
0.03183773159980774,
-0.03246098384261131,
-0.044320061802864075,
0.026176536455750465,
0.0009841087739914656,
-0.058273956179618835,
0.06914622336626053,
-0.05169519782066345,
0.021380966529250145,
-0.01718267984688282,
-0.012638142332434654,
0.023129532113671303,
-0.0031097622122615576,
-0.024393346160650253,
-0.046916939318180084,
0.0026488162111490965,
0.05086419731378555,
0.06035145744681358,
0.03131835535168648,
0.06031683459877968,
-0.06710334122180939,
0.0018091588281095028,
0.008284042589366436,
0.028548352420330048,
-0.11287765949964523,
0.0298294797539711,
-0.01386733166873455,
-0.03320541977882385,
-0.02235046774148941,
0.06699946522712708,
-0.02730184979736805,
0.0066003999672830105,
0.002713738242164254,
-0.029344728216528893,
0.050206318497657776,
0.00894191861152649,
-0.03587155044078827,
-0.015693802386522293,
0.0037481614854186773,
-0.05436132475733757,
0.012006235308945179,
0.01831665076315403,
0.0074660261161625385,
0.05114119499921799,
0.030868230387568474,
-0.014386707916855812,
0.1109386533498764,
0.002441065851598978,
0.0019162800163030624,
-0.03074704296886921,
0.013754799962043762,
0.02200421877205372,
0.009980670176446438,
-0.024012470617890358,
0.0327899195253849,
-0.004548865836113691,
0.008747152984142303,
-0.055573202669620514,
0.04992932081222534,
0.08116111159324646,
-0.032564856112003326,
0.04795569181442261,
-0.01798771321773529,
0.00527599174529314,
0.011279109865427017,
-0.011209859512746334,
0.025328222662210464,
-0.03646017611026764,
-0.0067389002069830894,
0.0010447025997564197,
0.024133658036589622,
-0.0340191088616848,
0.004059786908328533,
0.08053786307573318,
0.020549966022372246,
0.0428658090531826
]
|
32,476 | bqplot.marks | Boxplot | Boxplot marks.
Attributes
----------
stroke: Color or None
stroke color of the marker
color: Color
fill color of the box
opacities: list of floats (default: [])
Opacities for the markers of the boxplot. Defaults to 1 when the
list is too short, or the element of the list is set to None.
outlier-color: color
color for the outlier
box_width: int (default: None)
width of the box in pixels. The minimum value is 5.
If set to None, box_with is auto calculated
auto_detect_outliers: bool (default: True)
Flag to toggle outlier auto-detection
Data Attributes
x: numpy.ndarray (default: [])
abscissas of the data points (1d array)
y: numpy.ndarray (default: [[]])
Sample data points (2d array)
| class Boxplot(Mark):
"""Boxplot marks.
Attributes
----------
stroke: Color or None
stroke color of the marker
color: Color
fill color of the box
opacities: list of floats (default: [])
Opacities for the markers of the boxplot. Defaults to 1 when the
list is too short, or the element of the list is set to None.
outlier-color: color
color for the outlier
box_width: int (default: None)
width of the box in pixels. The minimum value is 5.
If set to None, box_with is auto calculated
auto_detect_outliers: bool (default: True)
Flag to toggle outlier auto-detection
Data Attributes
x: numpy.ndarray (default: [])
abscissas of the data points (1d array)
y: numpy.ndarray (default: [[]])
Sample data points (2d array)
"""
# Mark decoration
icon = 'fa-birthday-cake'
name = 'Boxplot chart'
# Scaled attributes
x = Array([]).tag(sync=True, scaled=True, rtype='Number',
atype='bqplot.Axis', **array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
# Second dimension must contain OHLC data, otherwise the behavior
# is undefined.
y = Array([[]]).tag(sync=True, scaled=True, rtype='Number',
atype='bqplot.Axis', **array_serialization)\
.valid(array_dimension_bounds(1, 2), array_supported_kinds())
# Other attributes
scales_metadata = Dict({
'x': {'orientation': 'horizontal', 'dimension': 'x'},
'y': {'orientation': 'vertical', 'dimension': 'y'}
}).tag(sync=True)
stroke = Color(None, allow_none=True)\
.tag(sync=True, display_name='Stroke color')
box_fill_color = Color('steelblue')\
.tag(sync=True, display_name='Fill color for the box')
outlier_fill_color = Color('gray').tag(sync=True,
display_name='Outlier fill color')
opacities = List(trait=Float(1.0, min=0, max=1, allow_none=True))\
.tag(sync=True, display_name='Opacities')
box_width = Int(None, min=5, allow_none=True).tag(sync=True, display_name='Box Width')
auto_detect_outliers = Bool(True).tag(sync=True, display_name='Auto-detect Outliers')
_view_name = Unicode('Boxplot').tag(sync=True)
_model_name = Unicode('BoxplotModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.045036785304546356,
-0.07630817592144012,
-0.04638340324163437,
0.021153075620532036,
-0.028970923274755478,
-0.007729008328169584,
-0.06403902173042297,
0.011408820748329163,
0.027063218876719475,
-0.03916405141353607,
-0.001838737167418003,
0.0015196175081655383,
-0.01068875566124916,
-0.0011356218019500375,
-0.024089444428682327,
0.006143930368125439,
0.011100221425294876,
-0.0319259949028492,
0.07735554128885269,
0.013484851457178593,
0.01882455311715603,
-0.021901194006204605,
-0.015476719476282597,
0.004773936700075865,
0.05236835777759552,
0.05165764316916466,
0.03233746066689491,
-0.012802192941308022,
0.006751777604222298,
0.02803577296435833,
-0.07541043311357498,
-0.047355957329273224,
-0.007036997936666012,
-0.0079814987257123,
0.03731245547533035,
-0.05438827723264694,
0.03749948367476463,
-0.0033338069915771484,
0.012484242208302021,
0.035535670816898346,
0.050572868436574936,
-0.022331364452838898,
0.06725592911243439,
-0.045410845428705215,
0.01603780873119831,
0.014924981631338596,
-0.04443829134106636,
0.060709886252880096,
-0.03882739692926407,
-0.036003246903419495,
0.007705629803240299,
-0.03261800482869148,
0.027811337262392044,
0.04585971683263779,
-0.06194428354501724,
0.031402312219142914,
0.02139621414244175,
0.05760519206523895,
-0.007700954098254442,
0.08042283356189728,
-0.02672656439244747,
0.07619596272706985,
0.04776742309331894,
-0.03493717685341835,
-0.048627760261297226,
0.007967471145093441,
-0.023734087124466896,
-0.00338991591706872,
-0.018403736874461174,
0.039986979216337204,
0.052517980337142944,
-0.002187080215662718,
-0.015804022550582886,
0.025379950180649757,
-0.017309611663222313,
-0.02609066292643547,
-0.06411383301019669,
0.04413904249668121,
-0.04649562016129494,
-0.0035465534310787916,
0.05895180627703667,
0.0437275767326355,
0.04769261181354523,
-0.04073509946465492,
0.024369988590478897,
-0.03577880933880806,
0.017262855544686317,
0.10361453145742416,
0.05150802060961723,
0.027138030156493187,
-0.014485461637377739,
0.008972756564617157,
0.03381499648094177,
0.016645656898617744,
-0.04933847486972809,
-0.08356493711471558,
-0.015186823904514313,
-0.0449993796646595,
-0.03598454222083092,
0.01383085735142231,
0.010034151375293732,
-0.03764910623431206,
0.016290299594402313,
0.019413698464632034,
-0.052405763417482376,
0.0056155710481107235,
-0.03635860234498978,
-0.018328925594687462,
-0.023285215720534325,
0.02996218204498291,
0.008523885160684586,
0.019993489608168602,
-0.049749940633773804,
0.02240617573261261,
-0.03654563054442406,
0.027979664504528046,
-0.04039844498038292,
0.014859520830214024,
-0.0012589446268975735,
-0.07256758213043213,
-0.038602959364652634,
0.056857071816921234,
0.006564747542142868,
-0.01309208944439888,
-0.017964215949177742,
0.03467533364892006,
0.04174506291747093,
0.05543564632534981,
-0.05016140639781952,
-0.04148321971297264,
0.030504567548632622,
-0.03256189450621605,
-0.0313275009393692,
-0.0030930060893297195,
0.024220364168286324,
-0.023453542962670326,
0.047991856932640076,
-0.018216706812381744,
-0.03731245547533035,
0.06815367937088013,
0.0346379280090332,
0.0008094885270111263,
-0.0037920300383120775,
-0.02784874476492405,
-0.076757051050663,
0.029906071722507477,
-0.000544432201422751,
-0.07391419261693954,
0.007336245849728584,
-0.04084732010960579,
-0.04009919986128807,
0.005031102802604437,
-0.0015932604437693954,
0.018095137551426888,
0.05704410374164581,
-0.014868873171508312,
0.006723722908645868,
-0.03991216793656349,
0.006709695793688297,
0.05599673464894295,
-0.0560341402888298,
0.020797718316316605,
0.0330294705927372,
-0.021134372800588608,
-0.04297946020960808,
0.0525553859770298,
-0.025847524404525757,
-0.037200234830379486,
-0.027886150404810905,
0.017721077427268028,
-0.01679527945816517,
-0.021976007148623466,
-0.04148321971297264,
0.022817641496658325,
-0.010726161301136017,
0.07084690779447556,
-0.0166830625385046,
0.04776742309331894,
0.03136490657925606,
-0.018600117415189743,
-0.031028252094984055,
-0.006438502576202154,
-0.033328719437122345,
0.01697295904159546,
-0.059251055121421814,
-0.018366331234574318,
0.016337057575583458,
-0.03263670951128006,
0.012147588655352592,
0.0011671831598505378,
-0.020816421136260033,
0.025772713124752045,
0.004568203818053007,
0.017926810309290886,
-0.015635695308446884,
0.005124617833644152,
-0.015701156109571457,
-0.0015196175081655383,
-0.0040889400988817215,
0.00440455274656415,
0.041707657277584076,
0.039313673973083496,
0.032674115151166916,
-0.010726161301136017,
0.017851999029517174,
-0.030392350628972054,
0.01512136310338974,
-0.029157953336834908,
-0.03598454222083092,
0.028709081932902336,
-0.007616790477186441,
-0.00642915116623044,
-0.06344052404165268,
0.024594424292445183,
0.050946928560733795,
0.0008480634423904121,
0.024482207372784615,
-0.009276680648326874,
-0.06336571276187897,
0.032879848033189774,
0.07589671015739441,
-0.030560676008462906,
-0.05973733216524124,
0.05745556950569153,
-0.013858911581337452,
0.03834111988544464,
0.12732991576194763,
0.0013641489204019308,
0.06445048749446869,
-0.05199429765343666,
-0.024500910192728043,
0.006302905734628439,
-0.034076839685440063,
0.028840001672506332,
-0.0512835830450058,
0.02397722564637661,
0.038210198283195496,
-0.03228135034441948,
-0.07757998257875443,
-0.02369668148458004,
0.04713151976466179,
0.0001586831349413842,
0.0032589950133115053,
0.04425126314163208,
0.0014284404460340738,
-0.030953438952565193,
0.025959743186831474,
0.06014879792928696,
-0.06897660344839096,
-0.040435854345560074,
-0.013615773059427738,
-0.02451961301267147,
0.06426345556974411,
-0.002662837505340576,
0.05446309223771095,
-0.053902000188827515,
-0.03252448886632919,
-0.05023621767759323,
0.03753688931465149,
-0.02036754973232746,
0.017019715160131454,
-0.03439478948712349,
0.013344579376280308,
0.09336529672145844,
0.03624638542532921,
0.03841593116521835,
0.01759950816631317,
-0.007504572626203299,
-0.012334618717432022,
0.02397722564637661,
-0.008542587980628014,
0.026333801448345184,
-0.01687009260058403,
-0.0012449173955246806,
0.0005111175123602152,
0.018777796998620033,
0.012689975090324879,
0.01520552672445774,
-0.012184994295239449,
-0.01400853507220745,
-0.0012355658691376448,
-0.06403902173042297,
0.008406991139054298,
0.005498677492141724,
0.014073995873332024,
-0.10024799406528473,
-0.007864604704082012,
-0.0322626493871212,
0.001489225192926824,
-0.025754010304808617,
-0.04256799444556236,
-0.006471232511103153,
-0.018702983856201172,
-0.029812557622790337,
-0.0004170181055087596,
0.023827603086829185,
-0.007345597259700298,
0.03946329653263092,
-0.019862569868564606,
-0.013279118575155735,
0.047617796808481216,
-0.018581414595246315,
0.0629168376326561,
0.046869680285453796,
0.04832851141691208,
0.005928846076130867,
0.04784223437309265,
-0.035442154854536057,
0.028634268790483475,
0.014896927401423454,
0.01568245328962803,
0.03779873251914978,
0.015429962426424026,
-0.04032363370060921,
-0.0396503284573555,
0.03882739692926407,
0.02444480173289776,
-0.008467776700854301,
-0.013802802190184593,
0.01614067517220974,
0.006424474995583296,
-0.1132652759552002,
-0.051956892013549805,
-0.03532993793487549,
0.04556047171354294,
-0.008874566294252872,
-0.01827281527221203,
0.0006885036127641797,
0.012474890798330307,
0.015504774637520313,
0.02055457979440689,
-0.008832484483718872,
0.009828418493270874,
0.025884930044412613,
-0.005082536023110151,
-0.040996942669153214,
-0.015224229544401169,
0.011605202220380306,
-0.006349663250148296,
-0.025866227224469185,
-0.00884651206433773,
-0.016430571675300598,
-0.06366495788097382,
0.028933517634868622,
-0.03151452913880348,
0.023640573024749756,
0.028522051870822906,
-0.025192920118570328,
-0.009426304139196873,
0.10810325294733047,
0.010445617139339447,
0.02803577296435833,
0.007383003365248442,
0.0008223468321375549,
0.029719041660428047,
-0.02451961301267147,
0.022331364452838898,
-0.053153883665800095,
-0.029906071722507477,
0.005306971725076437,
0.02941979467868805,
-0.03338482603430748,
-0.002602052642032504,
0.05483715236186981,
-0.004593920428305864,
-0.008495830930769444,
-0.0008100729901343584,
-0.029064437374472618,
0.05865256115794182,
0.01873103901743889,
-0.004280645400285721,
-0.04148321971297264,
-0.05105914920568466,
-0.02812928892672062,
0.03261800482869148,
-0.004025817383080721,
-0.04657043144106865,
-0.0007300008437596262,
0.02543605864048004,
-0.021134372800588608,
0.0437275767326355,
-0.049936968833208084,
0.008378936909139156,
-0.010127666406333447,
0.01110957283526659,
0.00030187785159796476,
-0.023434840142726898,
0.004493392072618008,
0.045672688633203506,
-0.018656227737665176,
0.03604065254330635,
-0.02758690156042576,
0.03753688931465149,
-0.000798383669462055,
-0.0629168376326561,
-0.03519901633262634,
-0.008795078843832016,
0.024557018652558327,
0.00537243252620101,
-0.022443581372499466,
-0.024182958528399467,
0.0014740289188921452,
0.009473062120378017,
0.002459442475810647,
0.008093716576695442,
-0.04776742309331894,
-0.020591985434293747,
-0.0022911156993359327,
0.02203211560845375,
0.04582231119275093,
0.0086174001917243,
-0.021414916962385178,
0.020348846912384033,
-0.035741403698921204,
0.03220653906464577,
-0.00032759446185082197,
-0.0313275009393692,
-0.044213853776454926,
0.006719047203660011,
-0.011287251487374306,
0.0022209794260561466,
0.04810407757759094,
0.05880218371748924,
0.002538930159062147,
0.011997964233160019,
-0.025099406018853188,
-0.04021141678094864,
0.00230631185695529,
0.022537095472216606,
0.006443178281188011,
0.03770521655678749,
-0.033777590841054916,
-0.07892659306526184,
-0.0011321150232106447,
-0.04234355688095093,
-0.0162154883146286,
-0.0409221313893795,
-0.084387868642807,
0.011277900077402592,
-0.00440455274656415,
0.02683878317475319,
0.014317134395241737,
0.0333661250770092,
-0.0251742172986269,
-0.0017662631580606103,
0.010408210568130016,
-0.06295424699783325,
0.036096759140491486,
0.019507212564349174,
-0.04769261181354523,
0.04391460865736008,
0.058315906673669815,
0.022555800154805183,
0.004016465973109007,
-0.0011642607860267162,
-0.07720591872930527,
-0.0029433821327984333,
-0.1032404750585556,
0.0025552953593432903,
0.028709081932902336,
-0.008271395228803158,
-0.029569419100880623,
-0.09920062869787216,
-0.03153323009610176,
0.03912664204835892,
0.02130270004272461,
0.027811337262392044,
-0.01097865216434002,
-0.018300870433449745,
-0.014981091022491455,
0.023939820006489754,
-0.033066876232624054,
0.0029106519650667906,
-0.008958729915320873,
0.010548483580350876,
0.05285463482141495,
-0.016262244433164597,
-0.0006978551391512156,
-0.03532993793487549,
-0.0072614336386322975,
-0.017842646688222885,
-0.06213131546974182,
0.005199429579079151,
0.019413698464632034,
-0.017393775284290314,
0.07279201596975327,
0.023023374378681183,
-0.015261635184288025,
0.05150802060961723,
-0.0066348835825920105,
-0.060896918177604675,
0.04859035462141037,
-0.029457200318574905,
0.031664151698350906,
-0.004886154551059008,
0.01844114251434803,
0.03731245547533035,
0.0010315864346921444,
-0.006686316803097725,
-0.03826630488038063,
-0.008215285837650299,
0.0041076429188251495,
0.007700954098254442,
-0.023210404440760612,
0.05031102895736694,
-0.05562267452478409,
-0.0440642312169075,
0.009940636344254017,
-0.02057328261435032,
-0.03383369743824005,
-0.04204430803656578,
-0.05061027780175209,
0.07017359882593155,
-0.006952834315598011,
-0.00963203702121973,
-0.011586498469114304,
-0.037948355078697205,
0.05719372630119324,
0.036452118307352066,
0.006326284725219011,
0.02313559129834175,
0.012961167842149734,
0.005877412855625153,
-0.05124617740511894,
-0.021919898688793182,
0.022537095472216606,
-0.0028007719665765762,
-0.0165147352963686,
-0.016458626836538315,
0.0330294705927372,
0.025305138900876045,
-0.032879848033189774,
0.01271802932024002,
0.016711115837097168,
-0.01630900241434574,
0.05753038078546524,
-0.007060376461595297,
0.036844879388809204,
0.0660589411854744,
0.004801991395652294,
0.0090849744156003,
0.001178288017399609,
0.027717823162674904,
0.016112621873617172,
-0.010511077009141445,
0.0670689046382904,
0.0333661250770092,
0.008205934427678585,
0.05910143256187439,
-0.001967320218682289,
0.07286682724952698,
0.022630611434578896,
0.07922584563493729,
-0.02573530748486519,
0.01176417712122202,
-0.002261892193928361,
-0.009239274077117443,
-0.014055293053388596,
0.03106565773487091,
-0.03532993793487549,
0.004593920428305864,
0.12029759585857391,
0.020030897110700607,
-0.03374018520116806,
0.0033922537695616484,
0.018843257799744606,
-0.029756449162960052,
0.022331364452838898,
0.021433619782328606,
-0.0421939343214035,
0.04563528299331665,
-0.009487088769674301,
0.013110792264342308,
-0.027736525982618332,
0.0534905344247818,
0.05584711208939552,
-0.005582841113209724,
0.009706849232316017,
-0.0805724561214447,
-0.06018620356917381,
-0.029064437374472618,
0.02195730432868004,
-0.011717420071363449,
-0.10114573687314987,
0.009047568775713444,
0.010034151375293732,
-0.0421939343214035,
-0.012259806506335735,
0.007607439067214727,
0.0506850890815258,
-0.013391337357461452,
0.051582831889390945,
-0.030224023386836052,
-0.018375681713223457,
0.03607805818319321,
0.020217927172780037,
-0.003212237497791648,
-0.061719849705696106,
-0.00034805084578692913,
-0.021153075620532036,
0.010950597003102303,
0.06938806921243668,
-0.02878389321267605,
0.012325266376137733,
-0.009959339164197445,
0.022649314254522324,
-0.016280947253108025,
-0.03912664204835892,
-0.05154542624950409,
-0.01624354161322117,
0.015074605122208595,
0.02700711041688919,
-0.007939416915178299,
-0.022836344316601753,
0.006031712517142296,
-0.04013660550117493,
-0.02792355604469776,
0.03312298655509949,
0.019058341160416603,
0.01779589056968689,
0.03908923640847206,
-0.007551330141723156,
0.009613334201276302,
-0.004834721330553293,
-0.01543931383639574,
-0.07406381517648697,
0.012680623680353165,
-0.02912054769694805,
0.0031467771623283625,
-0.040697693824768066,
0.055473051965236664,
0.015551531687378883,
0.06718111783266068,
-0.12545962631702423,
0.03882739692926407,
0.0035652564838528633,
-0.024687940254807472,
0.00611120043322444,
-0.024856265634298325,
0.04230615124106407,
0.016991661861538887,
-0.022630611434578896,
-0.0002885812136810273,
0.014607030898332596,
0.0363398976624012,
-0.03519901633262634,
0.005409838166087866,
0.013699935749173164,
0.03716282919049263,
0.013653178699314594,
-0.003100019646808505,
-0.015112011693418026,
-0.00638706935569644,
-0.022836344316601753,
-0.0173189640045166,
0.06321609020233154,
-0.0036447441671043634,
-0.004881478846073151,
0.029812557622790337,
-0.05064768344163895,
-0.032225243747234344,
-0.04391460865736008,
-0.04354054853320122,
0.035180315375328064,
0.0547623373568058,
-0.018020326271653175,
0.007817847654223442,
0.0660589411854744,
0.024126850068569183,
0.03699450194835663,
-0.003897234331816435,
0.013064034283161163,
-0.041071753948926926,
-0.030916033312678337,
-0.04948809742927551,
-0.05580970644950867,
0.00834620650857687,
0.012278509326279163,
0.00486745173111558,
-0.010529780760407448,
-0.005825979635119438,
0.007612114772200584,
-0.07137058675289154,
0.09336529672145844,
0.0004950446309521794,
0.022480987012386322,
0.027960961684584618,
-0.01208212785422802,
-0.04701930284500122,
-0.005255538504570723,
-0.00479263998568058,
-0.009893878363072872,
0.052143920212984085,
-0.012512296438217163,
-0.0028568808920681477,
-0.044400885701179504,
-0.019862569868564606,
-0.05446309223771095,
0.009856472723186016,
-0.052330952137708664,
0.061009135097265244,
-0.050946928560733795,
-0.04290464520454407,
0.07346532493829727,
-0.009374870918691158,
0.04451310262084007,
-0.06467492133378983,
-0.010548483580350876,
0.009061596356332302,
-0.00278908247128129,
-0.02064809575676918,
0.045410845428705215,
0.03153323009610176,
-0.03613416478037834,
0.018478548154234886,
-0.027493387460708618,
0.001892508240416646,
-0.0031210605520755053,
-0.012409429997205734,
0.005320999305695295,
-0.007509248331189156,
0.07447528094053268,
0.014644436538219452,
0.023771492764353752,
-0.0019287453033030033,
0.049188848584890366,
-0.02184508554637432,
-0.004692111164331436,
-0.022518392652273178,
-0.01807643473148346,
0.04701930284500122,
0.06213131546974182,
0.009996744804084301,
0.018048379570245743,
0.003850477049127221,
-0.0035021337680518627,
-0.010969300754368305,
-0.006377717945724726,
0.030672894790768623,
-0.018646875396370888,
0.01406464446336031,
-0.07847772538661957,
-0.02921406179666519,
-0.015186823904514313,
0.05839071795344353,
-0.005400486756116152,
0.03381499648094177,
0.06396421045064926,
0.028091883286833763,
0.033235203474760056,
0.03897701948881149,
0.023303918540477753,
-0.05797925218939781,
0.06714371591806412,
0.05551045760512352,
-0.03106565773487091,
0.05517380312085152,
-0.03615286946296692,
0.026614347472786903,
-0.08206869661808014,
-0.023808898404240608,
-0.021826382726430893,
0.02019922249019146,
0.018871311098337173,
0.06676965206861496,
0.03746207803487778,
-0.05842812359333038,
0.022293956950306892
]
|
32,593 | bqplot.axes | ColorAxis | A colorbar axis.
A color axis is the visual representation of a color scale.
Attributes
----------
scale: ColorScale
The scale represented by the axis
| class ColorAxis(Axis):
"""A colorbar axis.
A color axis is the visual representation of a color scale.
Attributes
----------
scale: ColorScale
The scale represented by the axis
"""
orientation = Enum(['horizontal', 'vertical'],
default_value='horizontal').tag(sync=True)
side = Enum(['bottom', 'top', 'left', 'right'],
default_value='bottom').tag(sync=True)
label = Unicode().tag(sync=True)
scale = Instance(ColorScale).tag(sync=True, **widget_serialization)
_view_name = Unicode('ColorAxis').tag(sync=True)
_model_name = Unicode('ColorAxisModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
-0.010727424174547195,
-0.046946119517087936,
-0.050109799951314926,
0.02634582668542862,
0.013063821010291576,
0.0031864086631685495,
-0.05425531044602394,
-0.010854698717594147,
0.00184888974763453,
-0.053273480385541916,
0.030327701941132545,
0.001195471384562552,
0.049746159464120865,
0.013227459974586964,
0.0299276951700449,
-0.0012159262550994754,
0.028364038094878197,
-0.014563841745257378,
0.05352802947163582,
-0.016118409112095833,
0.019618459045886993,
0.004493245389312506,
0.00011235954298172146,
0.01060924120247364,
0.012691088020801544,
0.03909146040678024,
0.0016636599320918322,
0.009954686276614666,
-0.03723689168691635,
-0.04170968011021614,
-0.07956475764513016,
-0.02814585156738758,
0.0038523271214216948,
0.018145710229873657,
0.03609142079949379,
-0.068982794880867,
0.02054574526846409,
-0.013345642946660519,
-0.035636868327856064,
0.020163921639323235,
0.01821843907237053,
-0.018336622044444084,
0.029727693647146225,
-0.049018874764442444,
0.07149191945791245,
0.03703688830137253,
0.0015091121895238757,
0.04378243535757065,
-0.04967343062162399,
-0.07014644891023636,
0.027636753395199776,
-0.040073294192552567,
-0.02258213795721531,
0.048182498663663864,
0.024400344118475914,
0.04821886494755745,
0.0006397817633114755,
0.10509239137172699,
-0.012854726985096931,
0.08851034194231033,
-0.04672793298959732,
0.008281935006380081,
0.0013602464459836483,
-0.0752737894654274,
-0.03514594957232475,
0.024218523874878883,
0.005295529495924711,
0.013800195418298244,
0.0003406298055779189,
0.010154688730835915,
0.0021420756820589304,
0.00915922038257122,
0.02329123765230179,
-0.0010289917699992657,
0.001964800525456667,
-0.04254605621099472,
-0.037673261016607285,
0.08429209887981415,
-0.020327560603618622,
-0.04265514761209488,
0.015618402510881424,
0.03458230569958687,
0.05287347361445427,
-0.017963889986276627,
0.01721842586994171,
-0.039164189249277115,
-0.02140030264854431,
0.011727438308298588,
-0.024527618661522865,
0.01636386848986149,
-0.02550945058465004,
-0.03960055857896805,
-0.0210366602987051,
0.037309616804122925,
0.023163963109254837,
-0.04552791640162468,
0.0036114146932959557,
0.021418483927845955,
-0.015872951596975327,
0.019763914868235588,
-0.041382402181625366,
-0.0182911679148674,
-0.005150072742253542,
-0.0007948976126499474,
-0.045564278960227966,
-0.056618981063365936,
-0.057273536920547485,
0.014345657080411911,
-0.058582644909620285,
-0.0088864890858531,
0.057746272534132004,
0.05261892452836037,
0.03960055857896805,
0.011900167912244797,
-0.01654568873345852,
0.02289123274385929,
-0.04963706433773041,
0.016118409112095833,
0.005795536562800407,
-0.03569141402840614,
-0.026964018121361732,
0.02498217113316059,
0.01840025931596756,
0.035273224115371704,
0.026327645406126976,
0.07716472446918488,
-0.015063849277794361,
0.01876390166580677,
-0.09192857146263123,
0.001407974399626255,
-0.0007136464701034129,
-0.0392005555331707,
0.004252332728356123,
-0.04043693467974663,
0.09258312731981277,
-0.015609311871230602,
0.06945552676916122,
0.035036858171224594,
-0.08421937376260757,
0.10160143673419952,
0.028691314160823822,
0.04098239913582802,
-0.0028750405181199312,
-0.04261878505349159,
-0.033618658781051636,
0.018836630508303642,
-0.0231275986880064,
-0.017309335991740227,
-0.015472945757210255,
-0.010027414187788963,
-0.0436369813978672,
0.003661415306851268,
0.026727650314569473,
0.0006880778819322586,
0.029418596997857094,
-0.018072983250021935,
-0.021909400820732117,
-0.022418498992919922,
-0.0021136661525815725,
0.04320061206817627,
-0.07218284159898758,
0.014063835144042969,
0.021236663684248924,
-0.06149177998304367,
0.013336552307009697,
0.02283668704330921,
0.0036045964807271957,
-0.0802193135023117,
-0.040655121207237244,
0.020654836669564247,
-0.03549141064286232,
-0.10785607248544693,
0.00017216152627952397,
0.03441866859793663,
-0.021182117983698845,
0.00047017709584906697,
0.002171621657907963,
0.05127345025539398,
0.0017852524761110544,
-0.021018479019403458,
0.00016591143503319472,
0.019109360873699188,
-0.0000963792044785805,
-0.019072996452450752,
0.010400147177278996,
-0.024473072960972786,
0.0245639830827713,
0.01827298477292061,
0.038509633392095566,
-0.025891274213790894,
0.061091773211956024,
-0.0007181919645518064,
-0.007041008677333593,
-0.026091277599334717,
0.0009125128854066133,
-0.04607337713241577,
-0.011418343521654606,
-0.061382684856653214,
0.06305543333292007,
0.029000408947467804,
0.023563969880342484,
0.0026386736426502466,
0.040836941450834274,
0.01168198324739933,
0.03387320786714554,
0.03094589151442051,
0.06265543401241302,
-0.008972854353487492,
-0.011872895061969757,
-0.01717296987771988,
-0.017436610534787178,
-0.00917285680770874,
-0.0533098429441452,
0.01580931432545185,
0.0033455018419772387,
-0.006095540709793568,
-0.03741871193051338,
-0.01790025271475315,
-0.02885495312511921,
0.021436667069792747,
0.09301949292421341,
0.024945806711912155,
0.037745989859104156,
-0.009150129742920399,
-0.00472279405221343,
-0.03583687171339989,
0.050400711596012115,
-0.04476426914334297,
-0.0026886742562055588,
-0.024363981559872627,
-0.006481909658759832,
-0.03478230908513069,
0.022127585485577583,
0.05345530062913895,
-0.017763886600732803,
0.017936617136001587,
0.019109360873699188,
0.04516427591443062,
-0.040364205837249756,
0.012291083112359047,
-0.012363811023533344,
0.027218567207455635,
-0.01374564878642559,
0.032182272523641586,
-0.0037795989774167538,
-0.04127331078052521,
0.036782339215278625,
0.04160058870911598,
-0.03314592316746712,
-0.061455413699150085,
-0.06563729047775269,
-0.06694640219211578,
0.013382007367908955,
-0.006936461664736271,
0.010345600545406342,
-0.02336396649479866,
-0.07592834532260895,
-0.044546082615852356,
0.022182131186127663,
-0.05832809582352638,
-0.018836630508303642,
-0.013672920875251293,
0.04796431586146355,
0.08771032840013504,
0.08392845839262009,
0.006140995770692825,
0.04145513102412224,
0.015345671214163303,
-0.013991107232868671,
0.05640079826116562,
0.1069106012582779,
0.024836715310811996,
-0.01198198739439249,
0.04381880164146423,
-0.0015693403547629714,
-0.013836558908224106,
-0.002386397449299693,
-0.04301878809928894,
0.0321459099650383,
-0.006968280300498009,
0.002011392032727599,
-0.054946232587099075,
-0.01664569042623043,
0.009691045619547367,
0.0008579666609875858,
-0.0713464617729187,
0.004500063601881266,
-0.03520049899816513,
0.005359166767448187,
0.027218567207455635,
-0.007645562756806612,
0.009663772769272327,
-0.028127670288085938,
-0.022563954815268517,
0.009845593944191933,
-0.01063651405274868,
0.017072968184947968,
0.029564054682850838,
-0.024454891681671143,
0.0010568330762907863,
0.047527942806482315,
-0.05178254842758179,
0.028582222759723663,
0.008222843520343304,
-0.0015227488474920392,
-0.00725919334217906,
0.03752780333161354,
-0.0006744413403794169,
0.027091292664408684,
0.00858648493885994,
-0.003729598131030798,
0.08487392961978912,
-0.049855250865221024,
0.039164189249277115,
-0.06316453218460083,
0.05640079826116562,
0.00184548064135015,
-0.05581897124648094,
0.04010965675115585,
0.07949203252792358,
-0.06338271498680115,
-0.07701926678419113,
-0.03810963034629822,
-0.05407349020242691,
0.019745733588933945,
0.0271822027862072,
0.01314564049243927,
0.001761388499289751,
0.05447349697351456,
-0.007136464584618807,
-0.014000197872519493,
-0.008745578117668629,
0.030582251027226448,
0.0029795875307172537,
-0.02163666859269142,
-0.12232900410890579,
0.02263668365776539,
0.009031945839524269,
-0.008795578964054585,
-0.02080029435455799,
0.005977357272058725,
0.0030500430148094893,
-0.034036844968795776,
0.005240983329713345,
-0.028636768460273743,
-0.02903677336871624,
0.009936504065990448,
-0.05294620245695114,
0.018091164529323578,
0.031582266092300415,
0.027582207694649696,
-0.004425062332302332,
-0.013900196179747581,
0.009545589797198772,
0.049927979707717896,
0.010500147938728333,
-0.0009670591098256409,
-0.037745989859104156,
-0.004990979563444853,
-0.014009288512170315,
0.016763873398303986,
0.0014147927286103368,
0.011609255336225033,
0.012354720383882523,
-0.03574595972895622,
0.013536554761230946,
-0.009168311022222042,
-0.03207318112254143,
0.0757828876376152,
0.024836715310811996,
0.01690932922065258,
-0.011609255336225033,
0.014891119673848152,
-0.00362277845852077,
-0.022418498992919922,
0.01049105729907751,
-0.01970936916768551,
0.009136492386460304,
0.030273154377937317,
-0.09803774952888489,
0.041127853095531464,
-0.021582122892141342,
-0.013572919182479382,
-0.009791047312319279,
-0.035945963114500046,
-0.01063651405274868,
0.016472959890961647,
0.03112771175801754,
-0.0147638451308012,
0.021363938227295876,
-0.009454678744077682,
-0.020345741882920265,
-0.04236423596739769,
-0.05047344043850899,
-0.09803774952888489,
-0.04032784327864647,
0.023654880002141,
0.04243696480989456,
-0.009354677982628345,
-0.06309179961681366,
-0.01228199154138565,
-0.008386482484638691,
0.06669185310602188,
0.012536540627479553,
0.005131890531629324,
-0.03201863542199135,
0.010881971567869186,
-0.00788192916661501,
0.019673004746437073,
0.041746046394109726,
0.0025454906281083822,
-0.02174576185643673,
-0.0023295783903449774,
0.0026932198088616133,
-0.010563785210251808,
-0.07556470483541489,
0.034036844968795776,
-0.0815284252166748,
-0.004211422987282276,
-0.03603687137365341,
-0.05127345025539398,
0.06523728370666504,
0.04040057212114334,
-0.002182985423132777,
0.028182215988636017,
-0.013336552307009697,
0.03281864523887634,
0.024400344118475914,
-0.004029602278023958,
0.0041864230297505856,
-0.01479111798107624,
0.0407642126083374,
-0.06487364321947098,
-0.02180030755698681,
0.003968237899243832,
-0.011391069740056992,
0.01371837593615055,
-0.025073081254959106,
0.024036703631281853,
0.007241011597216129,
-0.03643687814474106,
-0.03261864185333252,
0.004745521582663059,
-0.014282019808888435,
-0.027145838364958763,
-0.0025227628648281097,
-0.05883719399571419,
-0.004361425060778856,
0.028945863246917725,
-0.056618981063365936,
0.04247332736849785,
0.08298299461603165,
0.008504665456712246,
-0.03232773020863533,
0.026982199400663376,
-0.09687409549951553,
-0.054509859532117844,
-0.06618275493383408,
0.019927553832530975,
-0.026873107999563217,
-0.013282005675137043,
-0.030073152855038643,
-0.08451028168201447,
-0.10254690051078796,
0.0016727509209886193,
0.03727325424551964,
0.05585533380508423,
-0.015191123820841312,
-0.00009282801329391077,
0.004618247039616108,
0.02067301981151104,
-0.0001751445233821869,
0.022127585485577583,
0.00412960397079587,
-0.048073407262563705,
0.03574595972895622,
-0.0044977907091379166,
0.034382302314043045,
-0.06756459176540375,
-0.03303683176636696,
-0.007186465431004763,
0.0037932354025542736,
0.017072968184947968,
0.029982242733240128,
0.013082003220915794,
0.07094645500183105,
0.04941888153553009,
-0.014645661227405071,
0.034873221069574356,
0.021582122892141342,
-0.026691285893321037,
0.018800266087055206,
-0.027764027938246727,
0.007745563983917236,
0.027691300958395004,
0.010554694570600986,
0.02683674357831478,
0.014545660465955734,
-0.03047315776348114,
0.023691244423389435,
0.003454594174399972,
-0.06414636224508286,
0.009100128896534443,
-0.0436369813978672,
0.049018874764442444,
-0.09687409549951553,
-0.04421880841255188,
0.016191137954592705,
0.0043227882124483585,
-0.05298256874084473,
-0.011636528186500072,
-0.00023309988318942487,
0.05203709751367569,
-0.03807326406240463,
0.051418907940387726,
-0.004311424680054188,
-0.04850977659225464,
0.06407362967729568,
0.007304648868739605,
-0.029891330748796463,
-0.016563870012760162,
0.030727706849575043,
0.02958223596215248,
0.008668304421007633,
-0.0431278832256794,
0.06185542047023773,
-0.04709157347679138,
-0.0250912643969059,
-0.018563898280262947,
0.04021875187754631,
0.049200695008039474,
-0.028545858338475227,
-0.013336552307009697,
0.0032682279124855995,
-0.006736458744853735,
0.015063849277794361,
-0.05818264186382294,
0.0640372708439827,
0.021727580577135086,
-0.007131918799132109,
-0.005659170914441347,
-0.0015557038132101297,
0.08552847802639008,
0.013827468268573284,
-0.0243094339966774,
0.024163978174328804,
0.04672793298959732,
-0.013409280218183994,
0.007736472878605127,
-0.005645534489303827,
0.006259179208427668,
0.03714597970247269,
-0.003525049891322851,
-0.038036901503801346,
-0.04276423901319504,
0.030927710235118866,
-0.0486188679933548,
-0.023109417408704758,
0.015372944995760918,
-0.004818249959498644,
0.00950013380497694,
0.05530987307429314,
0.04421880841255188,
0.002850040327757597,
0.007936475798487663,
0.04981888458132744,
0.017836615443229675,
-0.04349152371287346,
-0.013436553999781609,
-0.008659212850034237,
-0.015045667067170143,
-0.015136577188968658,
0.005513714160770178,
-0.0037773260846734047,
0.054400768131017685,
0.05080071836709976,
0.05650988966226578,
0.023673061281442642,
-0.04447335749864578,
-0.052364375442266464,
-0.03663688153028488,
0.023163963109254837,
0.007072827313095331,
-0.08058295398950577,
0.0024659440387040377,
-0.012991093099117279,
0.028873136267066002,
0.046327926218509674,
0.02801857702434063,
-0.032782282680273056,
-0.002130711916834116,
0.044546082615852356,
-0.024473072960972786,
-0.03714597970247269,
0.016891147941350937,
-0.03640051558613777,
-0.024782167747616768,
-0.040546026080846786,
0.0022613955661654472,
0.027745846658945084,
0.000977854710072279,
0.023563969880342484,
0.0075228335335850716,
0.02396397478878498,
-0.02976405620574951,
-0.01460929773747921,
0.061091773211956024,
-0.06094631552696228,
-0.026182187721133232,
-0.028291309252381325,
0.013609283603727818,
0.005295529495924711,
-0.04563700780272484,
0.022091221064329147,
0.0684736967086792,
-0.060146305710077286,
-0.04792794957756996,
0.046218834817409515,
0.014427476562559605,
0.039818745106458664,
0.04200059175491333,
0.01905481517314911,
0.0012113807024434209,
0.01664569042623043,
-0.047055210918188095,
0.0318913608789444,
0.016191137954592705,
0.016118409112095833,
-0.012418357655405998,
-0.02234577015042305,
0.0418187715113163,
0.01905481517314911,
-0.02150939404964447,
-0.09861957281827927,
-0.021654851734638214,
-0.03454594314098358,
-0.04261878505349159,
0.024000339210033417,
0.0392005555331707,
0.02772766537964344,
0.04098239913582802,
-0.001636386732570827,
0.033673204481601715,
0.044073350727558136,
0.010591058991849422,
0.02550945058465004,
0.002198894741013646,
-0.03052770346403122,
-0.028364038094878197,
-0.02610946074128151,
0.008181934244930744,
0.02330942079424858,
-0.002340942155569792,
-0.01245472114533186,
0.010254690423607826,
0.016809329390525818,
0.003175044897943735,
-0.009400133043527603,
0.015345671214163303,
-0.04629156365990639,
-0.0069591891951859,
0.02150939404964447,
0.07054644823074341,
0.0037091432604938745,
0.019854826852679253,
-0.008959217928349972,
0.0405096635222435,
0.02683674357831478,
-0.022927597165107727,
-0.008322845213115215,
0.0009414905798621476,
0.012936546467244625,
-0.045018818229436874,
-0.013645647093653679,
-0.033127740025520325,
0.011718347668647766,
0.017191151157021523,
-0.021727580577135086,
0.037182342261075974,
-0.02067301981151104,
-0.0027636755257844925,
0.0012068352662026882,
-0.033018648624420166,
0.04941888153553009,
0.0433824323117733,
0.015618402510881424,
0.028527675196528435,
-0.041309673339128494,
-0.009381950832903385,
-0.0752737894654274,
0.0050727990455925465,
0.013845650479197502,
-0.01643659546971321,
-0.061273593455553055,
0.04636429250240326,
-0.0215639416128397,
-0.05647352710366249,
-0.024527618661522865,
0.06469182670116425,
-0.016109319403767586,
0.03347320109605789,
-0.04210968688130379,
-0.02921859547495842,
0.05865537375211716,
0.07254648208618164,
0.015245670452713966,
0.01242744829505682,
0.003122771391645074,
0.07818292081356049,
-0.0021545758936554193,
0.014709298498928547,
0.07534652203321457,
0.004290969576686621,
-0.01787297986447811,
-0.002046619774773717,
-0.021945765241980553,
-0.04021875187754631,
0.02789130248129368,
-0.035036858171224594,
0.01941845566034317,
-0.029436780139803886,
0.05763717740774155,
0.0032955012284219265,
-0.005100071895867586,
0.04923706129193306,
-0.014682025648653507,
-0.019400274381041527,
0.039709653705358505,
-0.058582644909620285,
-0.0373823456466198,
-0.0001792638940969482,
0.014345657080411911,
-0.0022454862482845783,
0.059128109365701675,
-0.029436780139803886,
0.04116421937942505,
-0.02987314946949482,
0.008631939999759197,
0.021909400820732117,
0.026364009827375412,
0.017791161313652992,
-0.01769115962088108,
0.00024290116562042385,
-0.03201863542199135,
0.03089134581387043,
0.006922825239598751,
-0.0023454877082258463,
0.051127996295690536,
0.021782126277685165,
0.007404650095850229,
0.016718417406082153,
0.032836828380823135,
-0.06556456536054611,
0.06567365676164627,
0.024963989853858948,
-0.06018266826868057,
0.012391083873808384,
0.004036420490592718,
-0.00989104900509119,
-0.07007371634244919,
0.02187303639948368,
-0.03614596650004387,
-0.018045710399746895,
0.00799556728452444,
0.06123723089694977,
0.041309673339128494,
0.009754682891070843,
0.0020057102665305138
]
|
32,650 | bqplot.scales | ColorScale | A color scale.
A mapping from numbers to colors. The relation is affine by part.
Attributes
----------
scale_type: {'linear'}
scale type
colors: list of colors (default: [])
list of colors
min: float or None (default: None)
if not None, min is the minimal value of the domain
max: float or None (default: None)
if not None, max is the maximal value of the domain
mid: float or None (default: None)
if not None, mid is the value corresponding to the mid color.
scheme: string (default: 'RdYlGn')
Colorbrewer color scheme of the color scale.
extrapolation: {'constant', 'linear'} (default: 'constant')
How to extrapolate values outside the [min, max] domain.
rtype: string (class-level attribute)
The range type of a color scale is 'Color'. This should not be modified.
dtype: type (class-level attribute)
the associated data type / domain type
| class ColorScale(Scale):
"""A color scale.
A mapping from numbers to colors. The relation is affine by part.
Attributes
----------
scale_type: {'linear'}
scale type
colors: list of colors (default: [])
list of colors
min: float or None (default: None)
if not None, min is the minimal value of the domain
max: float or None (default: None)
if not None, max is the maximal value of the domain
mid: float or None (default: None)
if not None, mid is the value corresponding to the mid color.
scheme: string (default: 'RdYlGn')
Colorbrewer color scheme of the color scale.
extrapolation: {'constant', 'linear'} (default: 'constant')
How to extrapolate values outside the [min, max] domain.
rtype: string (class-level attribute)
The range type of a color scale is 'Color'. This should not be modified.
dtype: type (class-level attribute)
the associated data type / domain type
"""
rtype = 'Color'
dtype = np.number
scale_type = Enum(['linear'], default_value='linear').tag(sync=True)
colors = List(trait=Color(default_value=None, allow_none=True))\
.tag(sync=True)
min = Float(None, allow_none=True).tag(sync=True)
max = Float(None, allow_none=True).tag(sync=True)
mid = Float(None, allow_none=True).tag(sync=True)
scheme = Unicode('RdYlGn').tag(sync=True)
extrapolation = Enum(['constant', 'linear'], default_value='constant').tag(sync=True)
_view_name = Unicode('ColorScale').tag(sync=True)
_model_name = Unicode('ColorScaleModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.006503515411168337,
-0.0741606056690216,
-0.044488899409770966,
0.045869845896959305,
0.009209426119923592,
-0.0008380157523788512,
-0.04956481233239174,
-0.045981813222169876,
0.005108572077006102,
-0.037490855902433395,
-0.0008560940623283386,
0.012232581153512001,
0.09129181504249573,
0.05128166452050209,
0.016048846766352654,
0.0045603918842971325,
0.0037719456013292074,
0.020061058923602104,
0.05799978971481323,
0.0227483082562685,
0.01689794287085533,
0.011075571179389954,
0.04247346147894859,
0.026182014495134354,
-0.020471611991524696,
0.05564844608306885,
0.03568069264292717,
-0.005901683587580919,
-0.02424122393131256,
-0.04228684678673744,
-0.07755699008703232,
0.0019011353142559528,
-0.016925936564803123,
0.047698669135570526,
0.032713521271944046,
-0.08741023391485214,
0.021460669115185738,
0.03379588574171066,
-0.039748888462781906,
0.006886075250804424,
-0.022655000910162926,
0.014537270180881023,
0.0038839143235236406,
-0.039711568504571915,
0.04807189851999283,
0.02390531823039055,
-0.0064382003620266914,
0.025267604738473892,
-0.05710403993725777,
-0.06288909167051315,
0.020658226683735847,
-0.05740262195467949,
-0.0111875394359231,
0.024371854960918427,
0.0007843641215004027,
0.07404863834381104,
-0.007361942436546087,
0.1032351478934288,
-0.01506912149488926,
0.025230281054973602,
-0.0056404233910143375,
0.0005347671685740352,
0.018605466932058334,
-0.06098562106490135,
-0.03571801632642746,
0.016534045338630676,
-0.007408596109598875,
0.011122224852442741,
0.015153097920119762,
0.0143413245677948,
-0.006517511792480946,
-0.0235134270042181,
0.024633115157485008,
0.016888612881302834,
0.0219831895083189,
0.00540249003097415,
-0.017429795116186142,
0.030735408887267113,
0.007683852221816778,
-0.044302284717559814,
0.037808097898960114,
0.025025004521012306,
0.045608583837747574,
-0.06035112962126732,
0.03054879419505596,
-0.08860456943511963,
-0.0177843626588583,
0.001951287966221571,
-0.030754070729017258,
0.003041816409677267,
-0.07360076159238815,
-0.01206462737172842,
-0.018689442425966263,
0.05408088490366936,
0.036539118736982346,
0.007235977333039045,
0.01572227291762829,
0.013622858561575413,
0.011336831375956535,
-0.02806682139635086,
0.004749339073896408,
-0.029279816895723343,
-0.003053479827940464,
0.0024563134647905827,
-0.0416896790266037,
-0.025230281054973602,
-0.05613364279270172,
0.04232417047023773,
-0.04012211784720421,
0.010198482312262058,
-0.0012876400724053383,
0.09651701897382736,
-0.003359061200171709,
0.006022983230650425,
-0.05116969719529152,
-0.020975470542907715,
-0.024875713512301445,
0.011271515861153603,
-0.011252854950726032,
-0.0033637264277786016,
-0.04150306433439255,
0.029858320951461792,
-0.008420979604125023,
0.060089871287345886,
-0.0011051078327000141,
0.03506486490368843,
-0.0005003601545467973,
0.041092514991760254,
-0.0432199202477932,
-0.002000274136662483,
-0.042062908411026,
-0.003755616955459118,
-0.02722705714404583,
-0.0027432332281023264,
0.07083886861801147,
-0.005267194472253323,
0.004637370351701975,
0.055312540382146835,
-0.026331307366490364,
0.12943582236766815,
0.041353773325681686,
0.029653044417500496,
0.01527439709752798,
-0.03564336895942688,
0.0020305991638451815,
0.0001605176366865635,
0.04773598909378052,
-0.0053978245705366135,
-0.04639236629009247,
0.04945284500718117,
-0.04531000182032585,
0.02788020670413971,
0.06762909889221191,
0.025118311867117882,
0.04150306433439255,
-0.016030186787247658,
0.007459914777427912,
-0.037453532218933105,
-0.007124008610844612,
0.017028573900461197,
-0.06094829738140106,
0.0016830295789986849,
0.013744158670306206,
-0.07248107343912125,
0.004352783318608999,
0.013007030822336674,
0.003974888939410448,
-0.07535494118928909,
-0.03625919669866562,
0.035046204924583435,
-0.05146827921271324,
-0.09502410888671875,
0.012661794200539589,
0.07057760655879974,
0.026163354516029358,
0.0470268540084362,
0.014527939260005951,
0.009284071624279022,
0.00039189046947285533,
-0.0011943328427150846,
0.031799111515283585,
-0.0012421527644619346,
-0.018577473238110542,
-0.000775616557803005,
0.002352509181946516,
0.012997699901461601,
-0.02948509156703949,
-0.004823985043913126,
-0.002558951498940587,
-0.02959706075489521,
0.0799456536769867,
-0.004177832044661045,
0.016123494133353233,
-0.0004980274825356901,
0.008668243885040283,
-0.02317752130329609,
-0.028216112405061722,
-0.03209769353270531,
0.04501141980290413,
0.022766970098018646,
0.017775030806660652,
-0.0286826491355896,
0.02194586582481861,
0.00019579943909775466,
0.003981886897236109,
-0.019743815064430237,
0.0439663790166378,
-0.013389591127634048,
-0.022281771525740623,
-0.030343519523739815,
-0.03390785679221153,
-0.01953853853046894,
-0.01310033816844225,
0.04993804171681404,
0.04049534723162651,
-0.0631130263209343,
-0.00658749183639884,
-0.01057171169668436,
-0.010319782420992851,
0.032825492322444916,
0.07979636639356613,
-0.026256661862134933,
0.05781317502260208,
0.014387978240847588,
-0.003550340887159109,
-0.019109325483441353,
0.019762476906180382,
-0.020620903000235558,
0.03392651677131653,
-0.011224862188100815,
0.0031444544438272715,
-0.08860456943511963,
-0.004523069132119417,
0.04236149415373802,
0.026555243879556656,
0.03622187674045563,
0.04650433361530304,
0.08293148875236511,
0.0029765013605356216,
0.03189241886138916,
-0.027824223041534424,
0.04392905533313751,
-0.014695892110466957,
0.030492810532450676,
0.039898183196783066,
-0.03396384045481682,
0.06568830460309982,
0.021050116047263145,
-0.05471537262201309,
-0.03713628649711609,
-0.05038591846823692,
-0.05923144519329071,
0.023046892136335373,
0.025920754298567772,
-0.009288736619055271,
-0.017196526750922203,
-0.07031634449958801,
-0.029858320951461792,
0.016459399834275246,
-0.053670331835746765,
-0.03054879419505596,
-0.033441320061683655,
0.02890658751130104,
0.07367540895938873,
0.032060373574495316,
-0.011840690858662128,
0.005444478243589401,
0.03579266369342804,
-0.01476120762526989,
0.04635504260659218,
0.07710911333560944,
0.036968331784009933,
-0.038069359958171844,
0.03616589307785034,
-0.004737675655633211,
0.01099159475415945,
-0.009377378970384598,
-0.03138855844736099,
0.053744979202747345,
-0.003862920217216015,
-0.0011354326270520687,
-0.05120702087879181,
-0.030847378075122833,
-0.005733730737119913,
0.06636011600494385,
-0.05038591846823692,
-0.01519975159317255,
-0.02386799454689026,
0.009871907532215118,
0.01173805259168148,
-0.017233850434422493,
-0.004301464185118675,
-0.017765700817108154,
-0.027395009994506836,
0.03769613057374954,
-0.010263797827064991,
0.016356760635972023,
0.016683336347341537,
0.00451140571385622,
-0.06471791118383408,
0.029765013605356216,
-0.08711165189743042,
0.0883059874176979,
0.011859351769089699,
-0.04538464918732643,
-0.02244972437620163,
0.021889882162213326,
-0.03543809428811073,
0.007595210336148739,
0.04034605622291565,
-0.00714266998693347,
0.06591224670410156,
-0.05146827921271324,
0.031761787831783295,
-0.04452621936798096,
0.013660182245075703,
0.01842818222939968,
-0.022076496854424477,
0.03280682861804962,
0.08651448786258698,
-0.07520564645528793,
-0.0370803028345108,
-0.045720554888248444,
-0.02718973346054554,
0.035662032663822174,
0.022132480517029762,
0.010832971893250942,
0.0240919329226017,
0.04295865818858147,
0.020676886662840843,
-0.05284922942519188,
-0.011112893931567669,
0.034057147800922394,
0.02343878149986267,
-0.030716747045516968,
-0.08785811066627502,
0.021479329094290733,
0.00441576587036252,
-0.0022265443112701178,
-0.04172700271010399,
-0.01242852583527565,
-0.012456518597900867,
-0.06244121491909027,
-0.0029765013605356216,
0.01735514961183071,
-0.033180058002471924,
0.021404683589935303,
-0.04161503538489342,
0.01525573618710041,
0.02435319311916828,
0.041204482316970825,
-0.021665943786501884,
-0.024110594764351845,
0.030660763382911682,
0.006797433365136385,
-0.007324619218707085,
0.007968439720571041,
-0.06859949231147766,
0.05900750681757927,
-0.037677470594644547,
0.019687829539179802,
-0.03495289757847786,
0.013408252038061619,
-0.02562217228114605,
0.007786490488797426,
0.01758841797709465,
-0.05236402899026871,
-0.03870384767651558,
0.06740515679121017,
0.014276009984314442,
0.03304943069815636,
-0.011336831375956535,
-0.022804291918873787,
-0.01617014780640602,
-0.04542196914553642,
-0.0424361377954483,
-0.0344117134809494,
0.022860277444124222,
-0.019221294671297073,
-0.04079392924904823,
0.020210351794958115,
0.0002542622678447515,
-0.01840019039809704,
0.03220966458320618,
-0.0097506083548069,
-0.01839086040854454,
0.04038337990641594,
0.0038465915713459253,
-0.00833700317889452,
0.01586223393678665,
0.007954442873597145,
-0.01352022122591734,
0.027395009994506836,
-0.04460086673498154,
-0.05751458927989006,
-0.007991766557097435,
0.039711568504571915,
0.05456608161330223,
-0.008593598380684853,
-0.05262529104948044,
-0.04777331277728081,
-0.008005762472748756,
0.045832522213459015,
-0.005547116044908762,
-0.014313332736492157,
-0.011159547604620457,
0.05490198731422424,
0.045869845896959305,
0.007987100630998611,
0.07300359755754471,
0.018558813259005547,
-0.00927474070340395,
-0.02314019948244095,
-0.026256661862134933,
-0.018754757940769196,
-0.08532015234231949,
0.01610483229160309,
-0.09226220846176147,
-0.016580699011683464,
0.009284071624279022,
-0.0016212135087698698,
0.005878356751054525,
0.015666287392377853,
0.03342265635728836,
0.027357686311006546,
-0.04501141980290413,
0.026256661862134933,
0.012885731644928455,
0.011710059829056263,
0.019687829539179802,
-0.016804635524749756,
0.011234193108975887,
-0.03381454944610596,
-0.041204482316970825,
0.03323604166507721,
-0.020900825038552284,
-0.0045603918842971325,
0.04064463824033737,
-0.00435978127643466,
-0.025379572063684464,
-0.005528454668819904,
-0.023625396192073822,
-0.002521628513932228,
-0.005113237537443638,
0.013781481422483921,
-0.04967677965760231,
-0.04822118952870369,
0.0033240709453821182,
-0.033441320061683655,
-0.02937312237918377,
0.028626665472984314,
0.028813280165195465,
0.0015663955127820373,
-0.014248017221689224,
0.02095680870115757,
-0.04210023209452629,
-0.0324895866215229,
-0.059716641902923584,
0.03345998004078865,
-0.012755101546645164,
-0.003734622849151492,
-0.019687829539179802,
-0.04172700271010399,
-0.04613110423088074,
-0.044414252042770386,
0.02898123301565647,
0.06886075437068939,
-0.051916155964136124,
-0.03452368453145027,
-0.030026273801922798,
0.004513738211244345,
-0.004518403671681881,
0.03258289396762848,
-0.05437946692109108,
-0.06240389123558998,
0.05396891385316849,
-0.020564919337630272,
-0.001974614802747965,
-0.058074433356523514,
-0.024147916585206985,
0.039562273770570755,
-0.050609853118658066,
0.05423017591238022,
0.023644058033823967,
0.0026335972361266613,
0.05714135989546776,
0.03220966458320618,
0.019127987325191498,
0.014807861298322678,
0.03094068542122841,
-0.05113237351179123,
-0.003769613103941083,
0.008593598380684853,
0.05284922942519188,
-0.03694967180490494,
0.004208157304674387,
0.03262021392583847,
-0.03525147959589958,
-0.006335562560707331,
0.003347397781908512,
0.022916261106729507,
-0.03185509517788887,
-0.011159547604620457,
-0.03381454944610596,
0.07169729471206665,
-0.06852484494447708,
-0.05766388401389122,
0.031575173139572144,
0.010972932912409306,
-0.027525639161467552,
-0.02704044245183468,
0.033180058002471924,
0.035550061613321304,
-0.053819622844457626,
0.04810921847820282,
-0.016851289197802544,
-0.03702431917190552,
-0.004425096325576305,
-0.002354841912165284,
-0.06490452587604523,
-0.023046892136335373,
0.049004968255758286,
0.012820416130125523,
0.014369317330420017,
-0.018213575705885887,
0.058559633791446686,
-0.02806682139635086,
-0.022281771525740623,
0.016804635524749756,
0.03487825021147728,
0.03933833912014961,
-0.02241240255534649,
0.004604713059961796,
0.044339608401060104,
-0.009965214878320694,
0.024875713512301445,
-0.01617947779595852,
-0.00804775021970272,
0.0006204932578839362,
-0.021442007273435593,
-0.0018381528789177537,
0.03892778605222702,
0.06020183861255646,
0.03357195109128952,
-0.007683852221816778,
0.006811429280787706,
0.011560768820345402,
0.022076496854424477,
-0.009498678147792816,
-0.027544301003217697,
0.007492572534829378,
0.050497885793447495,
-0.0026335972361266613,
-0.004861307796090841,
0.008677574805915356,
0.023998625576496124,
-0.045869845896959305,
-0.026797842234373093,
-0.02435319311916828,
-0.00603231368586421,
-0.022878939285874367,
0.03303076699376106,
0.08136392384767532,
0.0004898631013929844,
-0.07110012322664261,
0.0143413245677948,
-0.017467116937041283,
0.00927474070340395,
-0.013790812343358994,
-0.026331307366490364,
-0.005407155491411686,
0.022169804200530052,
0.0006152446730993688,
0.046056460589170456,
0.025827446952462196,
0.02886926382780075,
0.02489437535405159,
-0.01558231096714735,
-0.031145961955189705,
-0.06471791118383408,
-0.02584610879421234,
0.018885387107729912,
0.009759938344359398,
-0.10136900097131729,
0.01168206799775362,
0.0035853311419487,
-0.023028230294585228,
0.06337428838014603,
-0.01942656934261322,
-0.03422509878873825,
0.015115775167942047,
0.03025021217763424,
-0.039860859513282776,
-0.020173028111457825,
-0.025267604738473892,
-0.027096426114439964,
-0.02459579147398472,
-0.0160581786185503,
0.04198826476931572,
0.047362763434648514,
-0.02937312237918377,
0.004712016321718693,
-0.01124352402985096,
0.014098726212978363,
-0.010198482312262058,
-0.037994712591171265,
0.08076675981283188,
-0.06412074714899063,
0.02944776974618435,
-0.05740262195467949,
-0.007072689943015575,
0.018484165892004967,
-0.059791289269924164,
-0.009433363564312458,
0.053409069776535034,
-0.07972171902656555,
-0.06468059122562408,
0.056805454194545746,
0.02634996734559536,
0.04915425926446915,
0.016646014526486397,
0.010366436094045639,
0.02340145967900753,
0.03659510612487793,
-0.003450035583227873,
0.021479329094290733,
-0.006125621031969786,
0.0003983053320553154,
-0.0156756192445755,
-0.08151321858167648,
0.041055191308259964,
0.03123926743865013,
0.0009354052017442882,
-0.07177194207906723,
0.003382388036698103,
-0.017952315509319305,
0.00036302354419603944,
0.018838735297322273,
0.022076496854424477,
0.056842777878046036,
0.008481629192829132,
-0.022319095209240913,
0.013454905711114407,
0.02547287940979004,
-0.02539823390543461,
0.008920173160731792,
0.014826522208750248,
-0.03297478333115578,
-0.004336454439908266,
-0.0018754757475107908,
-0.005785049870610237,
0.059977903962135315,
0.02974635176360607,
-0.05605899915099144,
0.007735171355307102,
0.008817535825073719,
-0.020546257495880127,
-0.019127987325191498,
0.008607594296336174,
-0.030791394412517548,
-0.05953002721071243,
0.05150560289621353,
0.06833823025226593,
-0.0017775031737983227,
0.03463565185666084,
0.0024329866282641888,
0.045720554888248444,
0.026126030832529068,
-0.009032142348587513,
0.03502754122018814,
-0.04866906255483627,
0.004893965553492308,
-0.03752817586064339,
-0.021330038085579872,
-0.019183970987796783,
0.005705738440155983,
0.047474730759859085,
-0.017803024500608444,
0.04071928560733795,
-0.03163116052746773,
0.04635504260659218,
0.014751876704394817,
-0.05139363557100296,
0.07897526025772095,
0.051916155964136124,
0.02125539258122444,
-0.007096016779541969,
-0.04684023931622505,
-0.0007499570492655039,
-0.021236730739474297,
0.04415299370884895,
0.0094613553956151,
-0.0038116013165563345,
-0.05590970441699028,
-0.001344790798611939,
-0.01610483229160309,
-0.104802705347538,
-0.015423689037561417,
0.037994712591171265,
-0.02715240977704525,
0.033665258437395096,
-0.03513951227068901,
-0.056768134236335754,
0.04045802354812622,
0.041129838675260544,
0.03120194561779499,
0.004068196285516024,
0.013986757025122643,
0.07554154843091965,
0.0026126031298190355,
0.033329349011182785,
0.08427511155605316,
0.03812534362077713,
-0.05116969719529152,
0.008556274697184563,
-0.020098382607102394,
-0.0031397889833897352,
0.016655344516038895,
-0.052401352673769,
0.034784942865371704,
-0.021442007273435593,
0.02168460562825203,
0.0435931496322155,
-0.014957152307033539,
-0.015293058939278126,
-0.012671125121414661,
-0.009731946513056755,
0.006106959655880928,
-0.03724825382232666,
-0.03844258934259415,
-0.0009581488557159901,
0.037490855902433395,
-0.00586902629584074,
0.041391097009181976,
-0.02121806889772415,
-0.003356728469952941,
-0.014994475990533829,
-0.008462968282401562,
-0.005724399816244841,
0.0003198689373675734,
-0.06072435900568962,
-0.0370989628136158,
-0.01808294653892517,
-0.016356760635972023,
0.001877808477729559,
0.034281086176633835,
0.010646357201039791,
0.04523535445332527,
0.020247673615813255,
0.0020142702851444483,
0.04795992746949196,
0.03396384045481682,
-0.06229192391037941,
0.02340145967900753,
0.06759177148342133,
-0.1066688522696495,
0.03312407433986664,
-0.011159547604620457,
0.012241911143064499,
-0.06400877237319946,
0.011234193108975887,
-0.033329349011182785,
-0.018418852239847183,
0.015395697206258774,
0.05897018313407898,
0.050609853118658066,
-0.0017775031737983227,
-0.0005184384062886238
]
|
32,768 | traittypes.traittypes | DataFrame | A pandas dataframe trait type. | class DataFrame(PandasType):
"""A pandas dataframe trait type."""
info_text = 'a pandas dataframe'
def __init__(self, default_value=Empty, allow_none=False, dtype=None, **kwargs):
if 'klass' not in kwargs and self.klass is None:
import pandas as pd
kwargs['klass'] = pd.DataFrame
super(DataFrame, self).__init__(
default_value=default_value, allow_none=allow_none, dtype=dtype, **kwargs)
| (default_value: Any = traittypes.Empty, allow_none: bool = False, dtype=None, **kwargs) | [
0.014088377356529236,
-0.01660974510014057,
0.04310252144932747,
-0.030532484874129295,
0.022508276626467705,
-0.0018645704258233309,
-0.017217082902789116,
0.020170949399471283,
-0.028489625081419945,
-0.024569541215896606,
0.014364439062774181,
0.014171196147799492,
-0.029685894027352333,
0.011382967233657837,
-0.009606966748833656,
-0.00978180579841137,
0.02420145832002163,
0.05355607718229294,
0.01645331084728241,
0.0021049745846539736,
-0.011585412546992302,
0.036256175488233566,
-0.010508770123124123,
0.023005187511444092,
-0.006685307715088129,
0.04976482316851616,
-0.04505335912108421,
-0.045090168714523315,
-0.008557929657399654,
0.01237679086625576,
-0.01272646989673376,
-0.04037870466709137,
-0.043581027537584305,
0.009280292317271233,
-0.007766551338136196,
-0.034857459366321564,
-0.03193119913339615,
0.005074944347143173,
-0.014732521958649158,
0.029557066038250923,
-0.05469713360071182,
-0.03721319139003754,
-0.04637845978140831,
-0.06699110567569733,
-0.03975296393036842,
0.004932312294840813,
0.034066081047058105,
-0.024698369204998016,
-0.027293354272842407,
-0.019747653976082802,
0.020833497866988182,
0.02502964437007904,
0.009432126767933369,
-0.004785079043358564,
-0.058525197207927704,
0.04243997111916542,
-0.018017662689089775,
0.07862252742052078,
-0.0408204048871994,
0.05753137543797493,
0.020870305597782135,
0.06036561354994774,
0.006303421687334776,
-0.04729866608977318,
-0.018128087744116783,
0.02160647325217724,
0.016931818798184395,
-0.016260067000985146,
-0.01917712390422821,
-0.00387407373636961,
-0.04041551426053047,
-0.022195404395461082,
0.012275568209588528,
0.09054841846227646,
0.02190093882381916,
-0.049838438630104065,
-0.1005602777004242,
-0.01102408580482006,
0.01482454314827919,
0.027385376393795013,
0.00774814747273922,
-0.006285017356276512,
-0.027974307537078857,
0.015201828442513943,
0.021569663658738136,
-0.006469058804214001,
-0.03894318267703056,
0.06448814272880554,
0.04553186893463135,
-0.003936187829822302,
-0.033661190420389175,
-0.0013757102424278855,
0.014944169670343399,
0.05683201551437378,
-0.016931818798184395,
-0.021293601021170616,
0.03272257745265961,
0.02164328098297119,
-0.030679717659950256,
0.01020510122179985,
-0.014677309431135654,
0.02679644338786602,
0.017585165798664093,
0.007899981923401356,
-0.06592366844415665,
0.007232830859720707,
0.014980978332459927,
-0.022876359522342682,
0.0018795238574966788,
-0.003802757477387786,
-0.05561734363436699,
0.003993700724095106,
0.0001700946013443172,
-0.00042962186853401363,
0.0078171631321311,
-0.01298412773758173,
-0.030422059819102287,
-0.017990056425333023,
-0.0067037115804851055,
0.029538661241531372,
-0.005102550610899925,
0.0801684781908989,
-0.0029722703620791435,
0.01848696917295456,
0.03193119913339615,
0.029612278565764427,
0.017852025106549263,
-0.07670849561691284,
0.026998888701200485,
0.03682670369744301,
0.06614451855421066,
0.003906280733644962,
-0.017437933012843132,
0.028121542185544968,
0.06540834903717041,
0.05639031529426575,
0.035851284861564636,
0.02653878554701805,
-0.052562251687049866,
0.030900567770004272,
-0.022949974983930588,
-0.006436851341277361,
0.04056274890899658,
-0.019545206800103188,
0.010425951331853867,
0.05237821117043495,
-0.015404273755848408,
-0.012496418319642544,
-0.06978853791952133,
0.00829106941819191,
-0.006354033015668392,
-0.07332213222980499,
-0.006850944831967354,
-0.010784831829369068,
0.020759882405400276,
-0.03493107855319977,
-0.003436974948272109,
-0.044538043439388275,
0.01823851279914379,
-0.03684511035680771,
-0.0002360907383263111,
-0.0407835952937603,
-0.05278310179710388,
0.021238388493657112,
-0.03496788442134857,
0.04715143144130707,
-0.02558176964521408,
-0.09945602715015411,
-0.028250370174646378,
0.029317811131477356,
0.02326284535229206,
0.008488913998007774,
0.05013290420174599,
0.05484436824917793,
-0.01230317447334528,
0.04089402034878731,
0.008396893739700317,
0.0666966438293457,
0.03336672484874725,
-0.0584883913397789,
0.06021837890148163,
0.0435074120759964,
-0.08937055617570877,
0.04232954606413841,
0.004173140972852707,
0.013987153768539429,
-0.02762462943792343,
0.007545701693743467,
0.055690959095954895,
0.06838982552289963,
-0.02433028630912304,
-0.020189352333545685,
0.01807287521660328,
-0.02256348729133606,
0.0476299412548542,
-0.03780212625861168,
0.013379816897213459,
-0.01741952821612358,
-0.029041748493909836,
0.0666598305106163,
0.01919552870094776,
0.02598666027188301,
0.052562251687049866,
-0.027385376393795013,
0.009579360485076904,
0.006873949896544218,
-0.00959776435047388,
-0.009137660264968872,
-0.08451186120510101,
-0.05639031529426575,
0.00462404265999794,
-0.07126086950302124,
0.02217700146138668,
0.007338654715567827,
0.013582263141870499,
-0.0312870554625988,
-0.007692934945225716,
-0.0462312251329422,
0.005558053497225046,
-0.023483695462346077,
0.1493680775165558,
0.011603816412389278,
-0.030385252088308334,
0.04586314409971237,
0.012818491086363792,
-0.040857214480638504,
0.021164773032069206,
-0.05778903141617775,
0.04674654081463814,
-0.030661314725875854,
-0.03736042603850365,
-0.03763648867607117,
-0.0407835952937603,
-0.03165514022111893,
0.0407835952937603,
-0.0033449542243033648,
0.0421455055475235,
0.008903007954359055,
-0.021864131093025208,
-0.029998764395713806,
0.0018622699426487088,
0.039237648248672485,
0.005939939524978399,
0.019950099289417267,
-0.0598502978682518,
-0.04913908243179321,
0.020723072811961174,
0.030974185094237328,
-0.01475092675536871,
-0.017217082902789116,
0.008866199292242527,
-0.06191156059503555,
-0.019637228921055794,
0.009570158086717129,
0.04093082994222641,
-0.02486400678753853,
0.0059629445895552635,
-0.012680459767580032,
0.033127471804618835,
-0.04229273647069931,
-0.034066081047058105,
-0.044133152812719345,
0.03439735621213913,
0.05742095038294792,
-0.01080323662608862,
-0.013996356166899204,
-0.026428360491991043,
-0.03248332440853119,
0.01701463758945465,
0.011438179761171341,
0.12132015824317932,
0.017769206315279007,
0.036108944565057755,
-0.01589198410511017,
-0.036108944565057755,
-0.06750642508268356,
-0.03776531666517258,
-0.02053903229534626,
0.020649457350373268,
-0.007057991810142994,
-0.007030385546386242,
-0.0816408097743988,
-0.014944169670343399,
-0.015146615915000439,
0.017309103161096573,
0.026575593277812004,
-0.030238019302487373,
0.034066081047058105,
-0.0044745090417563915,
0.01496257446706295,
-0.035280756652355194,
0.015836771577596664,
-0.0008724717190489173,
0.003828063141554594,
-0.02883930318057537,
0.040599554777145386,
-0.011235733516514301,
0.025213686749339104,
0.018302926793694496,
-0.025765810161828995,
-0.02364933304488659,
-0.03332991525530815,
0.07685573399066925,
0.08009485900402069,
-0.03086376003921032,
-0.029814723879098892,
0.012385993264615536,
-0.03559362515807152,
-0.020980730652809143,
-0.013066946528851986,
0.023299654945731163,
0.09216798096895218,
-0.03743404150009155,
0.014134387485682964,
-0.01339822169393301,
0.031618330627679825,
-0.03920083865523338,
-0.04770355671644211,
0.014677309431135654,
0.03632979094982147,
-0.07295405119657516,
-0.06588685512542725,
-0.017373517155647278,
-0.04523739963769913,
0.03279619663953781,
0.04523739963769913,
0.0476299412548542,
-0.024937624111771584,
-0.0028204359114170074,
0.051642045378685,
0.008544126525521278,
0.02596825547516346,
0.07899061590433121,
0.017594367265701294,
-0.007775753270834684,
-0.007605514954775572,
-0.01890106312930584,
-0.012698863632977009,
0.010251111350953579,
0.01714346557855606,
0.013996356166899204,
-0.03145269304513931,
-0.0002491749473847449,
-0.03275938704609871,
0.022913167253136635,
-0.07560425251722336,
0.001187067711725831,
-0.02000531181693077,
0.09165266901254654,
0.026814846321940422,
-0.003453078679740429,
0.011171319521963596,
-0.04976482316851616,
0.01006706990301609,
0.021440835669636726,
-0.04917588829994202,
0.01919552870094776,
0.03603532537817955,
-0.03690032288432121,
-0.03526235371828079,
0.06710153073072433,
-0.010389142669737339,
-0.0029285603668540716,
0.010361536405980587,
-0.03386363759636879,
0.02585783042013645,
-0.041961461305618286,
-0.0018024564487859607,
0.0008310623816214502,
0.028636857867240906,
0.014502470381557941,
-0.05097949504852295,
-0.0012744873529300094,
-0.017171071842312813,
0.008617742918431759,
0.006846344098448753,
-0.03783893212676048,
0.0045297215692698956,
-0.06842663139104843,
-0.06209560111165047,
-0.0033794620539993048,
-0.07394787669181824,
0.00465855048969388,
-0.017879631370306015,
-0.020723072811961174,
-0.014916563406586647,
-0.01202711183577776,
0.01928754895925522,
-0.0071868207305669785,
0.008212852291762829,
-0.035961709916591644,
-0.04192465543746948,
-0.04096763953566551,
-0.0032092237379401922,
-0.041814230382442474,
-0.03702915087342262,
-0.045495059341192245,
0.039789773523807526,
0.013278594240546227,
0.0075134942308068275,
0.017355114221572876,
-0.059923913329839706,
-0.005696084350347519,
0.015339858829975128,
-0.014428853988647461,
0.034489378333091736,
0.06205879524350166,
-0.08716205507516861,
-0.006381639279425144,
-0.03563043475151062,
0.10137005895376205,
-0.01245040725916624,
-0.018956275656819344,
0.01326019037514925,
0.04107806459069252,
0.03616415709257126,
0.051053114235401154,
-0.03469182178378105,
0.055543724447488785,
0.005792706273496151,
0.02799271233379841,
0.000291734526399523,
0.03390044346451759,
0.04365464299917221,
0.021827321499586105,
0.0679113119840622,
-0.02747739665210247,
0.0033380526583641768,
0.018569787964224815,
0.014060771092772484,
-0.007922986522316933,
0.026851655915379524,
-0.06739600002765656,
-0.00041294313268736005,
0.03150790557265282,
-0.049838438630104065,
-0.030569294467568398,
-0.02191934362053871,
-0.0005647773505188525,
0.04972801357507706,
0.03886956349015236,
-0.025471344590187073,
0.047409091144800186,
0.027679841965436935,
0.008369287475943565,
-0.03426852822303772,
0.001169813796877861,
0.024808794260025024,
-0.019747653976082802,
-0.00639544241130352,
0.025729002431035042,
0.01891946606338024,
0.08274506032466888,
0.029612278565764427,
-0.035851284861564636,
-0.034213315695524216,
-0.03218885883688927,
-0.0217537060379982,
0.0461944155395031,
0.006869349163025618,
0.001918632653541863,
-0.01646251231431961,
-0.019361166283488274,
-0.05123715475201607,
-0.021790513768792152,
0.03206003084778786,
0.021532855927944183,
-0.07450000196695328,
-0.010260313749313354,
-0.0044469027779996395,
0.04273443669080734,
0.027238141745328903,
0.027017293497920036,
-0.0775182843208313,
-0.025471344590187073,
0.05543329939246178,
-0.043176136910915375,
-0.009947443380951881,
-0.03879594802856445,
-0.02298678457736969,
-0.05999752879142761,
0.01578155905008316,
0.05101630464196205,
0.02079669013619423,
-0.018431756645441055,
-0.04394911229610443,
0.022250616922974586,
-0.016931818798184395,
0.026704421266913414,
-0.009846220724284649,
-0.004081120248883963,
0.05396096780896187,
0.015698740258812904,
0.020851902663707733,
0.05005928874015808,
0.05558053404092789,
0.06301581114530563,
0.012063920497894287,
-0.037323616445064545,
-0.01861579716205597,
0.04586314409971237,
-0.014557682909071445,
-0.06706472486257553,
-0.028250370174646378,
0.06614451855421066,
-0.11035128682851791,
0.04976482316851616,
0.016821393743157387,
-0.041814230382442474,
-0.03139748051762581,
-0.051862895488739014,
0.03794935718178749,
-0.01930595375597477,
0.014023962430655956,
0.006671504583209753,
0.009197474457323551,
-0.0448325090110302,
-0.005226778797805309,
0.017787611111998558,
-0.004601037595421076,
-0.01318657398223877,
-0.004987524822354317,
0.03498629108071327,
-0.0006913059041835368,
0.009399919770658016,
-0.0010346582857891917,
0.04096763953566551,
0.036108944565057755,
0.02733016386628151,
0.045752719044685364,
0.05613265931606293,
-0.035814475268125534,
0.0012790884356945753,
0.015137413516640663,
0.03044046461582184,
0.0625741109251976,
-0.01026951614767313,
0.03384523093700409,
0.07862252742052078,
-0.03853829205036163,
0.007329452782869339,
-0.0001742642925819382,
0.041666995733976364,
-0.03290662169456482,
0.02407262846827507,
-0.0530039519071579,
-0.05944540351629257,
0.021532855927944183,
0.04965439811348915,
0.03846467286348343,
0.004285866394639015,
-0.006524271331727505,
0.000775274820625782,
0.030679717659950256,
-0.027569416910409927,
0.0340108685195446,
0.02460634894669056,
0.03344034031033516,
0.06176432967185974,
-0.026060277596116066,
-0.0016540730139240623,
-0.050648219883441925,
0.0897386372089386,
-0.011879879049956799,
0.008530323393642902,
-0.000047591980546712875,
0.024422306567430496,
0.0503537543118,
-0.050942689180374146,
-0.05782584100961685,
0.02081509307026863,
-0.036108944565057755,
0.027808671817183495,
0.003899379400536418,
0.045495059341192245,
0.03005397692322731,
-0.01877223327755928,
0.07192341983318329,
-0.06312623620033264,
-0.024569541215896606,
-0.05734733119606972,
0.014373641461133957,
-0.003768249647691846,
-0.02830558270215988,
-0.07560425251722336,
-0.03332991525530815,
-0.03734201937913895,
-0.012662054970860481,
0.009606966748833656,
-0.03382682800292969,
-0.013177371583878994,
0.006620893254876137,
0.03198641166090965,
-0.026722826063632965,
0.04582633450627327,
0.03688191622495651,
-0.056095849722623825,
-0.05002247914671898,
0.0612122043967247,
-0.01360986940562725,
-0.028876110911369324,
0.030679717659950256,
-0.049985673278570175,
-0.04707781597971916,
0.03695553541183472,
-0.035575222223997116,
0.02828717976808548,
0.032704174518585205,
0.01284609641879797,
-0.03574085980653763,
0.015100604854524136,
0.025213686749339104,
-0.02571059763431549,
0.03086376003921032,
-0.012698863632977009,
-0.041262105107307434,
-0.047261856496334076,
-0.0231156125664711,
0.012873702682554722,
-0.04012104868888855,
-0.04336017742753029,
0.023299654945731163,
0.06629174947738647,
-0.010315526276826859,
-0.030017169192433357,
0.011171319521963596,
-0.015707941725850105,
-0.037047553807497025,
-0.003956892527639866,
-0.0815671905875206,
0.04593675956130028,
0.02188253402709961,
0.006860147230327129,
-0.05208374559879303,
-0.03211524337530136,
-0.02979631908237934,
-0.02147764340043068,
-0.019674036651849747,
0.0639728233218193,
0.060586463660001755,
0.001932435785420239,
-0.05315118655562401,
0.019250741228461266,
0.018017662689089775,
-0.019637228921055794,
-0.04917588829994202,
-0.023428482934832573,
-0.03342193737626076,
-0.023483695462346077,
-0.019618824124336243,
-0.013444231823086739,
0.02011573687195778,
-0.011502593755722046,
-0.05355607718229294,
0.04950716346502304,
0.046452075242996216,
-0.038427866995334625,
0.021440835669636726,
0.035004694014787674,
-0.008677557110786438,
0.02256348729133606,
-0.051347579807043076,
-0.003469182411208749,
0.012017910368740559,
0.0952598825097084,
0.02624431811273098,
0.01134615857154131,
0.005903131328523159,
0.03574085980653763,
0.024403903633356094,
0.002753721084445715,
0.05116353929042816,
-0.027366971597075462,
-0.04159338027238846,
0.0017460937378928065,
0.014622097834944725,
-0.03723159432411194,
-0.007122406270354986,
0.024569541215896606,
-0.02477198652923107,
0.008682157844305038,
0.026833251118659973,
-0.03894318267703056,
-0.014226407743990421,
-0.010830841958522797,
0.03349555283784866,
0.011686635203659534,
-0.034875866025686264,
0.011392168700695038,
-0.11918527632951736,
0.016775382682681084,
0.014327631331980228,
0.002723814221099019,
0.0448693186044693,
-0.013324604369699955,
-0.04479570314288139,
0.008944417349994183,
-0.01535826362669468,
-0.024937624111771584,
0.02256348729133606,
0.0004684431478381157,
0.03224407136440277,
-0.023336462676525116,
0.04932312294840813,
0.04512697458267212,
0.05970306321978569,
0.004042011685669422,
0.06216922029852867,
0.07899061590433121,
-0.03314587473869324,
0.019361166283488274,
0.07700296491384506,
0.0052635869942605495,
0.014428853988647461,
-0.019140316173434258,
-0.0037475451827049255,
0.009261888451874256,
0.030274827033281326,
-0.03846467286348343,
-0.0224530640989542,
0.03739723190665245,
0.01807287521660328,
0.008976624347269535,
0.06548196822404861,
0.021256793290376663,
-0.0006389690679498017,
-0.03524394705891609,
0.0007171867182478309,
-0.020207757130265236,
-0.0025627778377383947,
0.0353727750480175,
0.021974556148052216,
-0.017566761001944542,
-0.009634573012590408,
0.005258985795080662,
-0.024183053523302078,
-0.003926985431462526,
-0.008373888209462166,
0.020060524344444275,
0.007798758801072836,
-0.0598502978682518,
0.007973598316311836,
-0.003036684822291136,
0.008208250626921654,
-0.0005610390217043459,
-0.009698987007141113,
0.007347857113927603,
0.010370738804340363,
0.038427866995334625,
0.0530039519071579,
0.014023962430655956,
-0.03875914216041565,
-0.058672431856393814,
0.020023714751005173,
0.009335504844784737,
-0.02028137445449829,
0.014327631331980228,
-0.00024788090377114713,
-0.024403903633356094,
-0.03575926274061203,
-0.02191934362053871,
-0.019894886761903763,
0.03255694359540939,
-0.014033164829015732,
-0.004341078922152519,
-0.02937302365899086,
-0.023759758099913597,
0.019894886761903763
]
|
32,770 | traittypes.traittypes | __init__ | null | def __init__(self, default_value=Empty, allow_none=False, dtype=None, **kwargs):
if 'klass' not in kwargs and self.klass is None:
import pandas as pd
kwargs['klass'] = pd.DataFrame
super(DataFrame, self).__init__(
default_value=default_value, allow_none=allow_none, dtype=dtype, **kwargs)
| (self, default_value=traittypes.Empty, allow_none=False, dtype=None, **kwargs) | [
0.014393433928489685,
-0.0075489431619644165,
0.03694459795951843,
-0.027325782924890518,
-0.02209022454917431,
0.013471558690071106,
-0.008562136441469193,
0.030074015259742737,
-0.0020111671183258295,
-0.03784907981753349,
-0.008662151172757149,
0.07256726175546646,
-0.0450153574347496,
0.00736630754545331,
-0.0007604386191815138,
-0.008109895512461662,
0.0498160682618618,
0.028873836621642113,
0.059452276676893234,
0.026090817525982857,
-0.00026702319155447185,
0.013697679154574871,
-0.05026830732822418,
0.056495316326618195,
-0.0015056575648486614,
0.0575389489531517,
-0.05322526767849922,
-0.035222601145505905,
0.02342955395579338,
0.032474368810653687,
0.02562118135392666,
-0.02821286953985691,
-0.058652155101299286,
0.0452936589717865,
0.009714480489492416,
-0.05026830732822418,
-0.043867360800504684,
-0.003280920209363103,
-0.03297879174351692,
0.011053809896111488,
-0.024890638887882233,
-0.0607394203543663,
-0.03934495151042938,
-0.07054957002401352,
-0.056286588311195374,
0.024090521037578583,
0.045328445732593536,
-0.015906700864434242,
0.00662271911278367,
-0.04320639371871948,
-0.0027851946651935577,
0.05586913600564003,
0.0013186733704060316,
-0.0055182077921926975,
-0.06428777426481247,
0.052633874118328094,
-0.023586098104715347,
0.08822175115346909,
-0.03355279192328453,
0.04609377682209015,
-0.024734094738960266,
0.031239405274391174,
-0.0010985321132466197,
-0.055451683700084686,
-0.0040332055650651455,
0.025395061820745468,
-0.007440231274813414,
-0.02741275168955326,
-0.019533324986696243,
0.026247361674904823,
-0.0314481295645237,
-0.028647717088460922,
-0.005766070447862148,
0.09420524537563324,
-0.000581607804633677,
-0.0026177787221968174,
-0.11639983206987381,
-0.020298656076192856,
-0.0058834790252149105,
0.017559120431542397,
0.021533621475100517,
-0.009810146875679493,
-0.029743531718850136,
0.01750693842768669,
0.035570479929447174,
-0.026543058454990387,
-0.05332963168621063,
0.08307316154241562,
0.053747083991765976,
-0.0038310016971081495,
-0.04574589803814888,
-0.004878982901573181,
0.022281557321548462,
0.03628363087773323,
0.0249080341309309,
-0.0017339522019028664,
0.01047111488878727,
0.016672031953930855,
-0.0062704929150640965,
-0.010027570649981499,
-0.003787516849115491,
-0.0010985321132466197,
0.032370008528232574,
0.0015828429022803903,
-0.045919839292764664,
0.0029308684170246124,
0.02445579320192337,
-0.028021536767482758,
-0.01810702681541443,
-0.017828725278377533,
-0.08035971969366074,
0.04059731215238571,
0.004783316515386105,
0.009114392101764679,
-0.009592724032700062,
-0.009984086267650127,
-0.039414528757333755,
-0.012071351520717144,
0.007353262044489384,
0.01786351203918457,
-0.03937973827123642,
0.04912031069397926,
0.008892619982361794,
0.02287294901907444,
0.036561932414770126,
0.02649087645113468,
-0.011827836744487286,
-0.056843191385269165,
0.04825061932206154,
0.03791865333914757,
0.08989156037569046,
-0.009366603568196297,
-0.022107619792222977,
-0.008035971783101559,
0.032717883586883545,
0.014036859385669231,
0.036457568407058716,
0.07688093930482864,
-0.0051529365591704845,
0.017376484349370003,
0.008940453641116619,
-0.04953776299953461,
0.054547201842069626,
-0.0049050734378397465,
0.037257686257362366,
0.04804189130663872,
0.031900372356176376,
0.0031635116320103407,
-0.06223529577255249,
0.021568408235907555,
0.002073132898658514,
-0.03016098402440548,
0.011810443364083767,
-0.010253691114485264,
0.03449206054210663,
-0.03367454931139946,
0.0034048515371978283,
-0.03847525641322136,
-0.00027327414136379957,
-0.006983642000705004,
0.03494429960846901,
-0.01808963343501091,
-0.02901298925280571,
0.009331815876066685,
-0.031343769282102585,
0.061852630227804184,
-0.038962285965681076,
-0.08543872833251953,
-0.002646043663844466,
0.01706339418888092,
0.045363232493400574,
-0.013906405307352543,
0.043519482016563416,
0.04644165560603142,
-0.014193404465913773,
0.06313977390527725,
0.031100254505872726,
0.021655378863215446,
0.01741127111017704,
-0.01568927802145481,
0.032822247594594955,
0.03036971017718315,
-0.05221642181277275,
0.04553717374801636,
0.005961751565337181,
-0.014306464232504368,
-0.015184855088591576,
-0.022490283474326134,
0.042267125099897385,
0.07131490111351013,
-0.013680284842848778,
-0.012323562987148762,
0.0006441170698963106,
0.008153379894793034,
0.045363232493400574,
-0.039310164749622345,
0.05117278918623924,
-0.022159799933433533,
-0.027743235230445862,
0.0607394203543663,
0.041362643241882324,
-0.007022778037935495,
0.05607786402106285,
-0.04734613746404648,
0.02002035267651081,
0.0055877831764519215,
-0.029169533401727676,
-0.01854187436401844,
-0.05948706343770027,
-0.04484141618013382,
-0.010323266498744488,
-0.05242514982819557,
-0.017828725278377533,
-0.014923946931958199,
0.0027504069730639458,
-0.005583434831351042,
-0.03096110187470913,
-0.045571960508823395,
0.0012404009466990829,
-0.017933087423443794,
0.12050478905439377,
-0.04244106262922287,
-0.03515302762389183,
0.046476442366838455,
0.02763887122273445,
-0.005583434831351042,
0.06004366651177406,
-0.0761851891875267,
0.03948410227894783,
0.006031327415257692,
-0.055590834468603134,
-0.037605565041303635,
-0.03621405363082886,
-0.03459642454981804,
0.0407712496817112,
0.013949889689683914,
0.05813033878803253,
0.01683727465569973,
-0.035326965153217316,
-0.029186926782131195,
0.0016980773070827127,
0.0197768397629261,
0.016898153349757195,
0.010401538573205471,
-0.02558639459311962,
-0.026716995984315872,
0.0007642435375601053,
0.05266866087913513,
-0.012253986671566963,
-0.01763739250600338,
0.01461955439299345,
-0.019255023449659348,
-0.0019492014544084668,
0.007831593975424767,
0.01707209087908268,
-0.006961899809539318,
-0.009027422405779362,
0.0036374947521835566,
0.009297028183937073,
-0.041362643241882324,
0.003796213772147894,
-0.05712149664759636,
-0.002428620122373104,
0.05579955875873566,
-0.03155249357223511,
0.005048573017120361,
-0.031900372356176376,
-0.041467003524303436,
0.019411567598581314,
0.022472890093922615,
0.06084378436207771,
0.018854964524507523,
0.05134672671556473,
-0.027725841850042343,
-0.032926611602306366,
-0.04198881983757019,
-0.057852037250995636,
-0.05005957931280136,
-0.022733798250555992,
-0.013480255380272865,
-0.0018763645784929395,
-0.055138591676950455,
0.009010029025375843,
0.00004127648935536854,
0.013567225076258183,
0.0029547850135713816,
-0.038510046899318695,
-0.017672179266810417,
-0.020055141299962997,
-0.016132822260260582,
-0.04139743000268936,
0.04212797060608864,
-0.02149883285164833,
0.03501387685537338,
-0.00744892843067646,
0.011671291664242744,
0.0075315493158996105,
0.005439935252070427,
0.032717883586883545,
0.02901298925280571,
-0.034300725907087326,
-0.06630546599626541,
0.11646940559148788,
0.06449650228023529,
-0.022125013172626495,
-0.046719957143068314,
0.03083934634923935,
-0.03174382820725441,
0.0072532473132014275,
-0.002428620122373104,
0.04038858413696289,
0.0799422636628151,
-0.020455200225114822,
0.015219642780721188,
-0.014106434769928455,
-0.005761722102761269,
-0.01661115325987339,
-0.06390510499477386,
-0.0019078910117968917,
0.010288478806614876,
-0.06258317083120346,
-0.06463564932346344,
-0.045363232493400574,
-0.023847006261348724,
0.03231782466173172,
0.056947555392980576,
0.045571960508823395,
-0.017785239964723587,
-0.012271380983293056,
0.07639390975236893,
0.018367934972047806,
0.02014211006462574,
0.0812641978263855,
0.013967284001410007,
-0.015445763245224953,
-0.005209466442465782,
-0.03184819221496582,
0.00036119474680162966,
0.00554429879412055,
0.009479663334786892,
0.007435882929712534,
-0.01399337500333786,
0.002404703525826335,
-0.03642278164625168,
0.026108210906386375,
-0.06613152474164963,
0.01507179532200098,
-0.04814625531435013,
0.06063506007194519,
-0.018941933289170265,
-0.02115095593035221,
0.014680433087050915,
-0.0332396999001503,
0.006013933103531599,
0.022664222866296768,
-0.027273600921034813,
0.018020058050751686,
0.04685910791158676,
-0.02322082780301571,
-0.04581547528505325,
0.08237740397453308,
-0.011993078514933586,
-0.02821286953985691,
0.020803077146410942,
0.006805354729294777,
0.052390359342098236,
-0.03287442773580551,
0.012210502289235592,
-0.018802782520651817,
0.007074960041791201,
0.023081675171852112,
-0.046372078359127045,
0.005196420941501856,
-0.01807224005460739,
0.010166721418499947,
0.02139447070658207,
-0.0687406063079834,
-0.016759000718593597,
-0.024751488119363785,
-0.04741571098566055,
0.003059148322790861,
-0.06630546599626541,
0.023533916100859642,
-0.03038710542023182,
-0.033170126378536224,
-0.029291290789842606,
0.00217532180249691,
0.03024795465171337,
0.021881498396396637,
-0.01604585163295269,
-0.06609673798084259,
-0.03311794251203537,
-0.03435290977358818,
0.00699233915656805,
-0.026264755055308342,
-0.02149883285164833,
-0.0026525664143264294,
0.027673659846186638,
0.011984381824731827,
-0.014384737238287926,
-0.017350392416119576,
-0.03310054913163185,
0.005057270172983408,
0.017237333580851555,
-0.019829021766781807,
-0.00009410359780304134,
0.05903482064604759,
-0.06053069606423378,
0.015463157556951046,
-0.029152140021324158,
0.09149179607629776,
-0.013523739762604237,
-0.020646532997488976,
0.028821656480431557,
0.0292391087859869,
0.0332396999001503,
0.029099958017468452,
-0.025429850444197655,
0.05698234587907791,
-0.0059052216820418835,
0.012723621912300587,
0.022229375317692757,
0.020524775609374046,
0.053433991968631744,
0.022333739325404167,
0.06380074471235275,
-0.014558675698935986,
-0.04372821003198624,
0.03431812301278114,
-0.023186039179563522,
-0.018280966207385063,
0.0382317453622818,
-0.07201065123081207,
0.015324006788432598,
0.046267714351415634,
-0.014184707775712013,
-0.020211685448884964,
-0.014123829081654549,
-0.013923799619078636,
0.03403981775045395,
0.021098773926496506,
-0.03833610564470291,
0.0129236513748765,
0.032265644520521164,
0.0009789492469280958,
-0.03174382820725441,
0.01786351203918457,
0.041467003524303436,
-0.04884200915694237,
-0.012306168675422668,
0.0234469473361969,
0.00300261820666492,
0.06317456811666489,
0.02057695761322975,
-0.055451683700084686,
-0.009253542870283127,
-0.06404425948858261,
0.0038310016971081495,
0.05673883110284805,
0.000332929688738659,
0.009253542870283127,
-0.018020058050751686,
-0.022281557321548462,
-0.045467596501111984,
-0.04960734024643898,
0.06881017982959747,
0.0055877831764519215,
-0.05259908735752106,
-0.030300134792923927,
-0.014367342926561832,
0.046719957143068314,
0.022211981937289238,
0.006805354729294777,
-0.07729839533567429,
-0.024073127657175064,
0.028491172939538956,
-0.033744122833013535,
-0.05722585693001747,
-0.021359682083129883,
-0.01495873462408781,
-0.06828836351633072,
0.04588504880666733,
0.06345286965370178,
0.015619702637195587,
-0.005683449562638998,
-0.03708374872803688,
-0.002140534110367298,
-0.02002035267651081,
0.03344842791557312,
-0.007740275468677282,
0.0008006619173102081,
0.04891158640384674,
-0.03414418175816536,
0.05346878245472908,
0.041710518300533295,
0.055590834468603134,
0.07277598232030869,
0.014071647077798843,
0.005609525833278894,
-0.01109729427844286,
0.042267125099897385,
-0.0327700674533844,
-0.06727951765060425,
0.03094370849430561,
0.023168645799160004,
-0.09608378261327744,
0.00030792600591666996,
0.018298359587788582,
-0.054651565849781036,
-0.04678953066468239,
-0.010297175496816635,
0.05746937170624733,
-0.014436918310821056,
0.01810702681541443,
-0.017828725278377533,
0.010940749198198318,
-0.04310202971100807,
-0.029065169394016266,
0.006096554454416037,
0.02889123186469078,
0.017585210502147675,
0.0018274442991241813,
0.015976276248693466,
0.005766070447862148,
-0.0183157529681921,
0.01336719561368227,
0.04494578018784523,
0.03049146756529808,
0.03673586994409561,
0.02936086617410183,
0.008179470896720886,
-0.045119717717170715,
-0.020768290385603905,
0.07023648172616959,
-0.011175566352903843,
0.053086116909980774,
0.008135986514389515,
0.023638280108571053,
0.04553717374801636,
-0.04724177345633507,
0.007488064467906952,
0.022733798250555992,
0.03844046965241432,
-0.036561932414770126,
0.0001483915257267654,
-0.06213093176484108,
-0.06220050901174545,
0.08265570551156998,
0.058895669877529144,
0.021794529631733894,
0.00003879650103044696,
-0.027134450152516365,
0.012906257063150406,
0.021411864086985588,
-0.039414528757333755,
-0.012297471985220909,
0.0423714853823185,
0.028995594009757042,
0.05997409299015999,
-0.026421301066875458,
0.016071943566203117,
-0.04776358976960182,
0.09121349453926086,
-0.019707264378666878,
0.019933383911848068,
-0.005392102058976889,
0.01750693842768669,
0.05099885165691376,
-0.06334850192070007,
-0.04518929496407509,
-0.012358350679278374,
-0.02342955395579338,
-0.01854187436401844,
0.007335868198424578,
0.02629954367876053,
0.015784943476319313,
-0.0221771951764822,
0.08008141070604324,
-0.06922763586044312,
-0.004665907938033342,
-0.05019873008131981,
-0.004670256283134222,
0.007309777196496725,
-0.02593427151441574,
-0.08933495730161667,
-0.025221122428774834,
-0.07249768078327179,
-0.00017774368461687118,
0.0022981660440564156,
-0.03036971017718315,
0.001417601015418768,
0.026142999529838562,
-0.013932496309280396,
-0.0466155931353569,
0.03318751975893974,
0.059695787727832794,
-0.05503423139452934,
-0.05997409299015999,
0.06087857112288475,
-0.011210354045033455,
-0.028699899092316628,
0.04619814082980156,
-0.028386808931827545,
-0.005835645832121372,
0.023359978571534157,
-0.04449354112148285,
0.029517410323023796,
0.05893046036362648,
-0.0013512868899852037,
-0.032839640974998474,
0.002824330935254693,
0.04939861223101616,
0.01572406478226185,
0.02809111215174198,
-0.028926018625497818,
-0.021081380546092987,
-0.05124236270785332,
-0.026995299383997917,
-0.006070463452488184,
-0.07242810726165771,
-0.05767809972167015,
-0.002066610148176551,
0.03694459795951843,
0.01695903018116951,
-0.04324118047952652,
0.008844787254929543,
-0.02570815198123455,
-0.026716995984315872,
-0.015280521474778652,
-0.032944004982709885,
0.04877243563532829,
-0.017585210502147675,
0.003709244541823864,
-0.01922023482620716,
0.006061766296625137,
-0.03118722327053547,
-0.017724361270666122,
-0.017350392416119576,
0.06174826622009277,
0.04473705589771271,
0.016098033636808395,
-0.0414322167634964,
0.03440508991479874,
0.014219495467841625,
-0.02593427151441574,
-0.05788682773709297,
-0.022003255784511566,
0.015158765017986298,
-0.024073127657175064,
-0.013280225917696953,
-0.015306612476706505,
-0.017446059733629227,
0.006266144569963217,
-0.05552125722169876,
0.03489211946725845,
0.03158728405833244,
-0.01843751035630703,
0.010010176338255405,
0.05813033878803253,
-0.0022525072563439608,
-0.00808815285563469,
-0.054895080626010895,
0.0009381822892464697,
0.018976720049977303,
0.08105546981096268,
0.02922171540558338,
-0.0031135042663663626,
-0.030648013576865196,
0.009131785482168198,
0.058304280042648315,
0.006409644149243832,
0.038196954876184464,
-0.029047776013612747,
-0.011401686817407608,
0.006196569185703993,
-0.01695903018116951,
-0.040319010615348816,
-0.0036157523281872272,
0.022107619792222977,
-0.024421004578471184,
0.026421301066875458,
0.02002035267651081,
-0.04699825868010521,
-0.02276858687400818,
-0.013393285684287548,
0.02422967180609703,
-0.04164094477891922,
-0.023968763649463654,
0.015037007629871368,
-0.07576773315668106,
0.011810443364083767,
-0.029152140021324158,
-0.01741127111017704,
0.051485877484083176,
-0.041467003524303436,
-0.03604011610150337,
-0.032474368810653687,
-0.032926611602306366,
-0.021881498396396637,
0.046928681433200836,
-0.015550127252936363,
0.05844343081116676,
-0.04334554448723793,
0.08147292584180832,
0.06425298750400543,
0.024281853809952736,
-0.005013785324990749,
0.06727951765060425,
0.04665037989616394,
-0.05962621420621872,
0.01707209087908268,
0.07980310916900635,
-0.007422837428748608,
-0.009401391260325909,
-0.022785980254411697,
0.021655378863215446,
0.015332703478634357,
0.0033331019803881645,
-0.05298175290226936,
-0.026595238596200943,
0.022020649164915085,
-0.025969060137867928,
0.002385135507211089,
0.06425298750400543,
0.013680284842848778,
0.004931164439767599,
-0.040319010615348816,
-0.012193108908832073,
0.03572702407836914,
-0.015037007629871368,
0.051138002425432205,
0.05392102152109146,
0.023760037496685982,
-0.011645201593637466,
0.019829021766781807,
-0.04289330169558525,
-0.0037048959638923407,
0.0008778472547419369,
0.020542168989777565,
0.03137855604290962,
-0.05499944090843201,
-0.015132674016058445,
0.0398319810628891,
0.010131933726370335,
0.007635912392288446,
0.007335868198424578,
-0.0008789343992248178,
-0.004259326029568911,
0.041710518300533295,
0.06679248809814453,
-0.01922023482620716,
-0.04108433797955513,
-0.025290697813034058,
0.03150031343102455,
0.02139447070658207,
-0.007731578778475523,
-0.030300134792923927,
0.009331815876066685,
0.019168052822351456,
-0.054686352610588074,
-0.017550423741340637,
-0.013123680837452412,
0.020281260833144188,
-0.00021185199148021638,
0.005748676601797342,
0.009653602726757526,
0.04324118047952652,
0.039414528757333755
]
|
32,786 | traittypes.traittypes | make_dynamic_default | null | def make_dynamic_default(self):
if self.default_value is None or self.default_value is Undefined:
return self.default_value
else:
return self.default_value.copy()
| (self) | [
0.06577377766370773,
-0.04307309165596962,
0.02511455863714218,
0.007905008271336555,
-0.018968595191836357,
0.004840587265789509,
0.06015852466225624,
0.00039856735384091735,
0.04824323579668999,
-0.03362303599715233,
0.0062700798735022545,
0.061219945549964905,
-0.05183836445212364,
-0.018146852031350136,
0.019995776936411858,
0.036636095494031906,
0.01799277402460575,
0.04156656190752983,
0.027614029124379158,
0.03146595507860184,
0.04457962512969971,
-0.053276415914297104,
-0.03405102714896202,
0.017016952857375145,
0.007720971945673227,
-0.014894113875925541,
-0.009270302020013332,
-0.020868878811597824,
0.022221334278583527,
0.020612085238099098,
-0.007836529985070229,
-0.045161694288253784,
-0.02287188172340393,
0.06108298897743225,
0.04214863106608391,
-0.06293191015720367,
-0.06957434117794037,
0.09648647159337997,
-0.09696581959724426,
-0.05361881107091904,
0.04759268835186958,
-0.020766161382198334,
-0.02184469997882843,
-0.04399755597114563,
-0.035198044031858444,
0.010708354413509369,
0.03930676728487015,
0.03497548773884773,
0.018574843183159828,
-0.03814262896776199,
0.054919905960559845,
0.014757156372070312,
-0.001703407266177237,
0.012822633609175682,
-0.03483853116631508,
0.021108554676175117,
-0.009518537670373917,
0.04817475378513336,
-0.07053304463624954,
0.054200880229473114,
-0.008046245202422142,
0.0006157731986604631,
-0.030541494488716125,
-0.09299405664205551,
0.0023218553978949785,
0.036122508347034454,
0.0018275249749422073,
0.00046463857870548964,
0.028898006305098534,
0.03199666738510132,
-0.029822466894984245,
-0.023539548739790916,
-0.02814473956823349,
0.009124784730374813,
0.07012217491865158,
-0.03639642149209976,
-0.023316992446780205,
-0.05769329145550728,
0.032664332538843155,
-0.03191106766462326,
-0.016897115856409073,
-0.007669612765312195,
-0.05687154829502106,
-0.009621255099773407,
-0.01311366818845272,
-0.012642877176404,
-0.01838652789592743,
0.02905208244919777,
0.08826902508735657,
-0.019242510199546814,
0.019584903493523598,
-0.022683564573526382,
0.01164137665182352,
0.06043244153261185,
0.019961537793278694,
0.00028702200506813824,
0.027271635830402374,
-0.02365938574075699,
0.05961069464683533,
-0.019875938072800636,
-0.02215285412967205,
-0.03146595507860184,
-0.03146595507860184,
-0.039169806987047195,
0.02857273258268833,
-0.006813629064708948,
0.06046668067574501,
-0.005782168824225664,
0.014363404363393784,
-0.011367461644113064,
-0.05022911727428436,
-0.06324006617069244,
-0.050571508705616,
-0.0038005670066922903,
-0.02287188172340393,
0.0013000250328332186,
-0.027271635830402374,
0.01717103086411953,
0.04228558763861656,
0.06936890631914139,
-0.08005158603191376,
-0.03619098663330078,
-0.05526230111718178,
-0.01941370777785778,
0.04868834465742111,
0.015673059970140457,
0.014397643506526947,
-0.014200767502188683,
0.04868834465742111,
0.0515986904501915,
0.03259585425257683,
0.010477239266037941,
-0.016837196424603462,
-0.020303931087255478,
-0.032065145671367645,
-0.014560280367732048,
-0.0016948474803939462,
0.10367672890424728,
0.019858818501234055,
0.042319826781749725,
0.015972653403878212,
0.004806347656995058,
0.04053938016295433,
-0.013781335204839706,
0.026090379804372787,
-0.014902673661708832,
0.050537269562482834,
0.08190050721168518,
-0.09032338857650757,
0.019893057644367218,
0.04156656190752983,
0.07998310774564743,
-0.01224056538194418,
0.04197743535041809,
-0.018746040761470795,
-0.008692513220012188,
-0.004660830367356539,
-0.0591655857861042,
-0.029805347323417664,
-0.02711755968630314,
0.007190261967480183,
-0.025080319494009018,
0.03721816465258598,
-0.04971552640199661,
0.00787504855543375,
0.0398203544318676,
0.04348396509885788,
-0.008439998142421246,
0.06002156808972359,
0.049030739814043045,
-0.05334489792585373,
-0.030832529067993164,
-0.02936023660004139,
0.018677562475204468,
0.052899785339832306,
0.09436362981796265,
-0.021194152534008026,
-0.013396142981946468,
0.051153577864170074,
0.0626237615942955,
-0.04310733452439308,
-0.0009629815467633307,
-0.02906920202076435,
-0.03242465853691101,
0.044648103415966034,
0.01819821074604988,
0.028127619996666908,
-0.009355900809168816,
0.025987660512328148,
0.02711755968630314,
0.005362736992537975,
0.02600478008389473,
0.015698738396167755,
0.021194152534008026,
0.009064866229891777,
-0.024772165343165398,
0.03146595507860184,
-0.035711634904146194,
0.017633261159062386,
0.06341126561164856,
-0.021707743406295776,
-0.05433783680200577,
0.017701739445328712,
0.029497193172574043,
-0.029531434178352356,
0.030216220766305923,
-0.023436829447746277,
0.022889001294970512,
-0.09463754296302795,
-0.03721816465258598,
-0.08203746378421783,
0.002026541158556938,
-0.041600801050662994,
0.011872491799294949,
-0.0019174031913280487,
-0.07881896942853928,
-0.020868878811597824,
-0.010451558977365494,
-0.040607862174510956,
0.0422513484954834,
0.035403478890657425,
-0.050571508705616,
0.029206158593297005,
0.014851314947009087,
0.04166927933692932,
0.006411316804587841,
-0.025559669360518456,
-0.05235195532441139,
-0.033468957990407944,
0.006449836306273937,
-0.000478013331303373,
-0.024840643629431725,
-0.014089489355683327,
-0.010400200262665749,
0.08073636889457703,
-0.010665555484592915,
0.04646278917789459,
-0.02674092724919319,
-0.01787293702363968,
0.04848290979862213,
-0.03343471884727478,
0.005337057635188103,
0.03375999256968498,
0.03574587404727936,
0.02641565352678299,
0.029942305758595467,
-0.015989772975444794,
0.055330779403448105,
-0.020149853080511093,
-0.03923828527331352,
0.036841534078121185,
-0.010990829207003117,
-0.015013951808214188,
0.02347107045352459,
0.062041688710451126,
0.05789873003959656,
0.007669612765312195,
0.018215330317616463,
0.013738536275923252,
0.004613751545548439,
-0.00037529529072344303,
-0.008649714291095734,
-0.03477005288004875,
0.008996387012302876,
-0.0540296845138073,
-0.016914235427975655,
-0.03742360323667526,
0.021382469683885574,
-0.022426769137382507,
0.012206325307488441,
0.047798123210668564,
0.024018898606300354,
-0.015767216682434082,
-0.0633770227432251,
-0.007939247414469719,
-0.002713467925786972,
-0.03619098663330078,
0.008512756787240505,
-0.027168918401002884,
-0.05841231718659401,
-0.020971598103642464,
-0.004643710795789957,
0.02437841147184372,
0.0006312878686003387,
-0.05933678150177002,
0.018780279904603958,
-0.012993830256164074,
-0.046702463179826736,
-0.013190707191824913,
-0.03708120808005333,
-0.004733589012175798,
0.045161694288253784,
-0.014526041224598885,
0.0079563669860363,
-0.017342226579785347,
-0.03401678800582886,
-0.04050514101982117,
0.019465066492557526,
0.020594965666532516,
0.027802346274256706,
-0.031055083498358727,
0.0017397865885868669,
-0.009304541163146496,
0.029343117028474808,
-0.03910132870078087,
-0.011547218076884747,
0.0022020176984369755,
-0.025046078488230705,
0.055022623389959335,
0.03353743627667427,
-0.03595130890607834,
-0.00021974703122396022,
0.003462453605607152,
0.043449725955724716,
0.02427569404244423,
-0.04379212111234665,
0.029137680307030678,
-0.036430660635232925,
0.044237229973077774,
0.052591629326343536,
-0.026569729670882225,
-0.030336057767271996,
-0.1016908511519432,
0.021091435104608536,
-0.016315046697854996,
-0.021605025976896286,
-0.01311366818845272,
0.03047301433980465,
0.0059191263280808926,
0.05214652046561241,
-0.01432060543447733,
-0.027682509273290634,
-0.02674092724919319,
0.04663398489356041,
0.03189394623041153,
-0.02376210317015648,
0.01172697450965643,
-0.018643321469426155,
-0.02328275330364704,
-0.05108509957790375,
-0.03749208152294159,
-0.007575454656034708,
-0.046873658895492554,
-0.006471235770732164,
0.05067422613501549,
0.011512978933751583,
0.06145961955189705,
-0.03564315661787987,
0.007725251838564873,
-0.06837596744298935,
-0.06765694171190262,
0.0015022511361166835,
-0.012925351969897747,
-0.007481296546757221,
0.06769118458032608,
-0.016212329268455505,
0.003625090466812253,
-0.01809549331665039,
0.0006318228552117944,
0.007601134013384581,
0.04796931892633438,
-0.01566449925303459,
0.003973903600126505,
0.03233905881643295,
0.031842589378356934,
0.019790340214967728,
-0.010537157766520977,
0.026175977662205696,
-0.00785364955663681,
-0.05591284856200218,
-0.005696570500731468,
-0.02722027711570263,
0.01010916568338871,
-0.0609460286796093,
0.03858773782849312,
0.028915125876665115,
-0.07560046762228012,
-0.006573953665792942,
0.022118614986538887,
-0.053790006786584854,
0.004119420889765024,
0.005923406220972538,
-0.05344761535525322,
0.034684453159570694,
0.0071217832155525684,
-0.01509099081158638,
0.02316291630268097,
0.02460096776485443,
-0.019550664350390434,
-0.03345183655619621,
-0.007066144607961178,
0.00602184422314167,
0.005435495637357235,
-0.021502306684851646,
0.02915479987859726,
-0.039991553872823715,
0.017410706728696823,
-0.00010579422087175772,
-0.021690623834729195,
0.016075370833277702,
0.0154933026060462,
-0.003986743278801441,
0.024241454899311066,
0.04971552640199661,
-0.06443843990564346,
-0.053790006786584854,
0.02966839075088501,
0.05283130705356598,
-0.0022726363968104124,
0.021177032962441444,
-0.048517148941755295,
-0.009124784730374813,
-0.03567739576101303,
-0.03471869230270386,
0.031859707087278366,
-0.0166146419942379,
0.047387249767780304,
0.019037075340747833,
0.03536923974752426,
-0.039272528141736984,
-0.03862197697162628,
0.019773220643401146,
0.016580400988459587,
0.08018854260444641,
-0.006706631276756525,
0.0318254679441452,
0.0030687011312693357,
0.02906920202076435,
-0.05242043361067772,
-0.012848312966525555,
0.039272528141736984,
-0.0037149686831980944,
-0.003582291305065155,
0.0022854760754853487,
0.06368517875671387,
-0.027682509273290634,
0.035403478890657425,
-0.021793341264128685,
-0.02013273350894451,
0.00849135685712099,
0.023299872875213623,
-0.006060363724827766,
-0.008238841779530048,
0.06484931707382202,
0.002225557342171669,
-0.010973709635436535,
-0.016648881137371063,
0.014851314947009087,
-0.015202268026769161,
-0.048208996653556824,
-0.04321005195379257,
-0.021279752254486084,
0.06022700294852257,
-0.009201823733747005,
-0.030318938195705414,
0.003334056120365858,
-0.08594074845314026,
-0.06293191015720367,
0.03413662314414978,
-0.026381414383649826,
0.015604580752551556,
0.034307822585105896,
0.007669612765312195,
0.0017472765175625682,
-0.04625735059380531,
0.05255739018321037,
-0.013798454776406288,
-0.02489200234413147,
-0.04416875168681145,
0.002764826873317361,
0.015827136114239693,
-0.012463120743632317,
-0.002784086624160409,
-0.06615041196346283,
-0.009304541163146496,
-0.0540296845138073,
-0.01799277402460575,
0.0001321424642810598,
-0.018318047747015953,
-0.00924462266266346,
-0.015133789740502834,
0.048311714082956314,
0.016315046697854996,
-0.0048876660875976086,
-0.004416875075548887,
0.013841254636645317,
-0.019670503214001656,
0.002338975202292204,
0.020372409373521805,
0.03136323764920235,
-0.006150241941213608,
0.053892724215984344,
-0.002841865411028266,
-0.023950420320034027,
-0.04095025360584259,
0.004737868905067444,
0.046497028321027756,
-0.0021934579126536846,
0.06118570640683174,
-0.008850869722664356,
-0.02032105065882206,
-0.010442999191582203,
-0.040094271302223206,
0.037355124950408936,
-0.009783891960978508,
-0.08772119879722595,
-0.06252104043960571,
0.024224335327744484,
-0.039067089557647705,
0.007027625106275082,
0.0546802319586277,
0.02254660800099373,
-0.02367650531232357,
-0.016734478995203972,
0.013473181053996086,
-0.018112612888216972,
0.017735980451107025,
-0.03817686811089516,
0.009415819309651852,
-0.03199666738510132,
0.02050936594605446,
0.002148518804460764,
-0.04461386427283287,
-0.04937313124537468,
-0.03090100735425949,
0.046702463179826736,
-0.028692569583654404,
-0.00021412964269984514,
0.02318003587424755,
0.027151798829436302,
-0.010759713128209114,
-0.06022700294852257,
-0.01188105158507824,
0.15065310895442963,
0.0005066352896392345,
0.011316102929413319,
0.013396142981946468,
0.027305876836180687,
-0.09319949150085449,
-0.05283130705356598,
-0.006997665856033564,
-0.014705797657370567,
0.008358679711818695,
0.020663443952798843,
0.03221921995282173,
-0.010948030278086662,
-0.025936301797628403,
0.10703218728303909,
0.009270302020013332,
-0.022991718724370003,
-0.06306886672973633,
-0.013361903838813305,
0.012933911755681038,
-0.003603690769523382,
-0.021776221692562103,
-0.02843577414751053,
-0.01819821074604988,
0.026381414383649826,
0.05139325186610222,
0.02814473956823349,
0.058275360614061356,
-0.012822633609175682,
0.07245045155286789,
0.007031904999166727,
-0.005405536387115717,
0.0009223222732543945,
-0.09470602124929428,
0.011898172087967396,
0.02600478008389473,
0.016434883698821068,
-0.029017843306064606,
-0.03148307651281357,
0.07354611158370972,
0.02600478008389473,
0.05444055423140526,
0.03230481967329979,
0.010494358837604523,
-0.01235184259712696,
-0.017701739445328712,
0.025628147646784782,
0.003759907791391015,
0.02915479987859726,
0.037355124950408936,
-0.04683941975235939,
-0.011110667139291763,
-0.053790006786584854,
-0.004596631973981857,
0.06180201470851898,
-0.029086321592330933,
-0.02448113076388836,
-0.06662975996732712,
0.06827324628829956,
-0.08306464552879333,
0.02549119107425213,
-0.017941415309906006,
0.023299872875213623,
-0.004716469440609217,
-0.03381134942173958,
0.05098238214850426,
-0.019345229491591454,
-0.037149686366319656,
0.03273281082510948,
-0.021416708827018738,
0.0747787281870842,
0.03269857168197632,
0.015313546173274517,
-0.005499694496393204,
-0.020577844232320786,
0.024241454899311066,
-0.03687577322125435,
-0.003924684599041939,
-0.017838697880506516,
-0.01001500803977251,
0.021365350112318993,
-0.03168851137161255,
-0.000724376121070236,
-0.02285476215183735,
0.012608638033270836,
-0.03079828806221485,
-0.019156912341713905,
-0.06563682109117508,
0.033297762274742126,
-0.03649913892149925,
0.008653993718326092,
-0.0008763131918385625,
0.012454560957849026,
-0.011367461644113064,
0.015527541749179363,
-0.016374966129660606,
0.030336057767271996,
0.006505475379526615,
0.042114391922950745,
0.025080319494009018,
0.0014658718137070537,
0.0029510033782571554,
0.050537269562482834,
0.016871435567736626,
0.02338547073304653,
0.05375576764345169,
0.017470624297857285,
0.005576733034104109,
-0.010751153342425823,
0.021810460835695267,
0.0540296845138073,
-0.018061254173517227,
-0.0036079706624150276,
0.010674115270376205,
0.009518537670373917,
-0.030558614060282707,
-0.01888299733400345,
-0.0878581553697586,
-0.02124551311135292,
0.011110667139291763,
-0.014055250212550163,
0.019773220643401146,
-0.028213217854499817,
0.025730866938829422,
-0.008157523348927498,
0.02783658541738987,
-0.041087210178375244,
-0.07847657054662704,
-0.01687999628484249,
-0.007134622894227505,
-0.030113501474261284,
0.05447479337453842,
0.02011561393737793,
-0.018472125753760338,
-0.05526230111718178,
0.011418821290135384,
-0.04909921810030937,
0.009013506583869457,
-0.04142960533499718,
-0.009167583659291267,
-0.04050514101982117,
-0.01478283666074276,
-0.07642221450805664,
0.02316291630268097,
0.06827324628829956,
0.024737924337387085,
-0.008016286417841911,
0.11305831372737885,
-0.029428714886307716,
-0.043347008526325226,
0.053173698484897614,
-0.025730866938829422,
-0.0077423714101314545,
0.004879106301814318,
-0.03790295124053955,
0.02571374736726284,
-0.005456895101815462,
-0.027682509273290634,
-0.038656219840049744,
0.01443188264966011,
0.01031460240483284,
-0.02460096776485443,
-0.0328526496887207,
-0.04694214090704918,
0.054919905960559845,
-0.03108932264149189,
0.04091601446270943,
0.011975210160017014,
-0.0017997054383158684,
-0.050742704421281815,
-0.004814907442778349,
0.027408594265580177,
0.004600911866873503,
-0.021416708827018738,
0.010656995698809624,
0.01209504809230566,
-0.019465066492557526,
0.019567783921957016,
0.05697426572442055,
-0.010734033770859241,
0.005581012926995754,
-0.049030739814043045,
0.004172919783741236,
-0.06615041196346283,
0.0706700012087822,
-0.07265588641166687,
0.056049805134534836,
0.01941370777785778,
-0.012754155322909355,
0.005041743163019419,
-0.027408594265580177,
0.030404536053538322,
0.030301818624138832,
0.004412595182657242,
-0.05598132684826851,
0.012077928520739079,
0.05789873003959656,
0.02864121086895466,
0.04481929913163185,
0.05526230111718178,
-0.005628092214465141,
0.020406648516654968,
-0.03293824940919876,
0.06577377766370773,
0.0034217943903058767,
-0.07566894590854645,
0.009758212603628635,
-0.018865877762436867,
0.0002937093668151647,
0.011564337648451328,
0.04023122787475586,
0.015125229954719543,
-0.013978212140500546,
0.016152409836649895,
0.014799956232309341,
-0.004844867158681154,
0.0640275701880455,
-0.01010916568338871,
-0.00470362976193428,
0.014414763078093529,
0.029000723734498024,
0.032869767397642136,
-0.04355244338512421,
-0.006650992203503847,
0.021279752254486084,
0.023248514160513878,
0.02674092724919319,
-0.0418747179210186,
-0.04026546701788902,
-0.02419009618461132,
0.04848290979862213,
-0.00693774688988924,
0.014748596586287022,
0.02966839075088501,
0.019841698929667473
]
|
32,787 | traittypes.traittypes | set | null | def set(self, obj, value):
new_value = self._validate(obj, value)
old_value = obj._trait_values.get(self.name, self.default_value)
obj._trait_values[self.name] = new_value
if ((old_value is None and new_value is not None) or
(old_value is Undefined and new_value is not Undefined) or
not old_value.equals(new_value)):
obj._notify_trait(self.name, old_value, new_value)
| (self, obj, value) | [
0.05178724229335785,
0.0008234973647631705,
-0.0008868433069437742,
-0.009342150762677193,
-0.03782689943909645,
-0.03125213831663132,
0.012250556610524654,
0.0287138931453228,
-0.03285617008805275,
0.0041510877199471,
0.008971990086138248,
0.010990247130393982,
0.018842943012714386,
-0.018754808232188225,
-0.038743484765291214,
0.028678640723228455,
0.0167629923671484,
0.017115525901317596,
0.04089394211769104,
0.018701927736401558,
0.01383695937693119,
-0.041316986083984375,
-0.005415803752839565,
0.02323199063539505,
0.01631351001560688,
-0.01580233685672283,
-0.025611594319343567,
0.015097268857061863,
-0.0020656289998441935,
0.016745364293456078,
-0.03044131025671959,
-0.030194537714123726,
0.009588925167918205,
-0.016419271007180214,
0.0527743399143219,
-0.03410766273736954,
-0.026140395551919937,
0.032450754195451736,
-0.03758012503385544,
0.023478765040636063,
-0.02827322669327259,
0.037932656705379486,
-0.008443188853561878,
0.021099159494042397,
-0.003957194276154041,
0.03366699814796448,
0.013431545346975327,
0.1135159432888031,
0.04286813363432884,
-0.012867490760982037,
-0.015881655737757683,
-0.054995302110910416,
0.018226006999611855,
0.005001576151698828,
-0.043855227530002594,
0.04410200193524361,
-0.0287138931453228,
0.05030659958720207,
0.027779679745435715,
0.056264426559209824,
0.002399434568360448,
0.004007870797067881,
-0.015088454820215702,
-0.12507906556129456,
0.0003764952998608351,
-0.026739703491330147,
0.022368282079696655,
0.02391943149268627,
0.01180988922715187,
0.040118370205163956,
-0.04360845685005188,
-0.016119616106152534,
0.03899025917053223,
-0.0021218140609562397,
0.020323585718870163,
-0.01274410355836153,
-0.04759208858013153,
0.046111445873975754,
0.026210902258753777,
-0.025311941280961037,
0.06299782544374466,
0.021169666200876236,
-0.0005712152342312038,
-0.021680841222405434,
-0.07494872808456421,
0.05150521546602249,
-0.0002597183920443058,
-0.011237021535634995,
0.07649987936019897,
-0.001688858144916594,
0.021768974140286446,
-0.017802966758608818,
0.04787411540746689,
0.0014464911073446274,
-0.023179110139608383,
0.02376079186797142,
0.05661695823073387,
-0.05030659958720207,
-0.03616998717188835,
0.00002606135058158543,
-0.012682410888373852,
-0.013546118512749672,
0.00048666217480786145,
0.024007564410567284,
-0.003996854182332754,
-0.04029463604092598,
0.03444257006049156,
-0.025364821776747704,
-0.012012596242129803,
-0.017423992976546288,
0.0071872868575155735,
0.0021339324302971363,
-0.040188875049352646,
0.026598690077662468,
-0.00868114922195673,
-0.029225068166851997,
-0.05760405585169792,
-0.05894368514418602,
-0.017723646014928818,
0.007301860488951206,
-0.038602471351623535,
-0.00417312141507864,
0.018983956426382065,
0.03708657622337341,
0.019283609464764595,
0.012946810573339462,
0.035605933517217636,
0.06127040833234787,
0.04910798743367195,
0.003036199137568474,
-0.01387221273034811,
-0.06440795958042145,
-0.027550531551241875,
0.01826126128435135,
0.007244573440402746,
0.022438788786530495,
-0.008623862639069557,
-0.02873152121901512,
0.008394715376198292,
-0.044701311737298965,
-0.0010625595459714532,
-0.003659743582829833,
0.009386217221617699,
-0.0365225225687027,
0.06289206445217133,
0.040329888463020325,
-0.03345547616481781,
0.05901418998837471,
-0.05721626803278923,
-0.018314141780138016,
-0.029295574873685837,
-0.024183832108974457,
-0.03343784809112549,
-0.005406990181654692,
-0.08115332573652267,
0.017186032608151436,
-0.038390953093767166,
-0.04639347270131111,
0.049284253269433975,
0.04639347270131111,
0.0092099504545331,
0.007914388552308083,
-0.020253079012036324,
0.03331446275115013,
-0.015731830149888992,
0.047028034925460815,
0.00129225745331496,
-0.012902744114398956,
0.009183510206639767,
0.060706354677677155,
-0.03044131025671959,
-0.050941161811351776,
-0.02111678570508957,
0.09384454786777496,
0.056123413145542145,
0.04445453733205795,
-0.00999433919787407,
-0.01752093993127346,
0.030353177338838577,
0.017794152721762657,
0.0022396924905478954,
-0.005508343689143658,
-0.05150521546602249,
0.020041557028889656,
-0.013731199316680431,
0.011254647746682167,
-0.010928553529083729,
0.02346113696694374,
0.024642126634716988,
0.04240984097123146,
0.03990684822201729,
-0.0011699722381308675,
0.00984451174736023,
-0.008452002890408039,
-0.02000630460679531,
0.001707586576230824,
0.015582002699375153,
-0.09525468945503235,
-0.022121507674455643,
0.010179419070482254,
0.01499150786548853,
-0.044842325150966644,
0.045758914202451706,
0.01984766311943531,
0.009791632182896137,
-0.0005018101073801517,
0.060776859521865845,
0.0368398018181324,
0.026810210198163986,
-0.05171673744916916,
-0.046499233692884445,
-0.0194069966673851,
-0.06102363392710686,
-0.013316972181200981,
0.04794462397694588,
-0.09384454786777496,
0.031904324889183044,
-0.02028833143413067,
-0.021980494260787964,
0.04984830692410469,
0.045300617814064026,
0.041916292160749435,
-0.0030119623988866806,
-0.014348133467137814,
0.02120492048561573,
0.013484424911439419,
-0.01124583464115858,
-0.07720494270324707,
0.005248350091278553,
0.019301235675811768,
-0.012638343498110771,
0.026140395551919937,
0.01485049445182085,
-0.005631730426102877,
-0.006001891102641821,
0.08792197704315186,
0.016410456970334053,
-0.026792583987116814,
-0.09187036007642746,
0.07946116477251053,
0.017617886886000633,
-0.03909602016210556,
0.009650617837905884,
0.0653950572013855,
-0.044313523918390274,
0.04339693486690521,
-0.0176707673817873,
0.032732781022787094,
-0.04801512882113457,
-0.012973250821232796,
0.023179110139608383,
-0.02841424010694027,
-0.06134091690182686,
-0.020940519869327545,
-0.007015426643192768,
-0.024765513837337494,
-0.0008240482420660555,
-0.031181631609797478,
0.04142274335026741,
0.015194214880466461,
-0.0353415347635746,
-0.009597738273441792,
-0.00014239067968446761,
0.07586531341075897,
-0.017230099067091942,
-0.021927613765001297,
0.006997799966484308,
0.08714640140533447,
-0.01700095273554325,
0.003752283751964569,
0.04900222644209862,
-0.05728677287697792,
0.006649672519415617,
0.030018270015716553,
0.021081533282995224,
-0.023549271747469902,
0.00872080959379673,
-0.0001596042566234246,
0.0000625196989858523,
-0.03994210064411163,
0.019530383870005608,
-0.024236712604761124,
0.06402017176151276,
-0.009060123935341835,
-0.05171673744916916,
-0.021592706441879272,
-0.019671397283673286,
0.01615487039089203,
-0.022297775372862816,
-0.015053201466798782,
-0.0034085630904883146,
-0.013449171558022499,
-0.03393139690160751,
0.04233933240175247,
-0.006777466274797916,
0.0003908169746864587,
-0.09236390888690948,
0.00020849080465268344,
0.03997735679149628,
-0.0038470271974802017,
0.03669878840446472,
-0.0009468842763453722,
-0.06959021091461182,
0.0007821848266758025,
0.016648417338728905,
-0.05189300328493118,
0.051223188638687134,
0.003410766366869211,
0.004239221103489399,
0.030952485278248787,
0.06535980105400085,
-0.0005155809922143817,
-0.06994274258613586,
0.060917872935533524,
0.08848603069782257,
0.02638716995716095,
0.00977400504052639,
-0.07262200117111206,
0.0007232455536723137,
0.040329888463020325,
-0.028326107189059258,
-0.03227448835968971,
-0.06289206445217133,
-0.02797357179224491,
-0.0021559656597673893,
-0.051399458199739456,
0.023549271747469902,
0.02030595764517784,
-0.011527861468493938,
0.014788800850510597,
-0.07061255723237991,
-0.02857287973165512,
0.063420869410038,
0.05023609474301338,
0.0033204294741153717,
-0.012488516978919506,
0.0013209008611738682,
0.00558325694873929,
0.030282670632004738,
0.033649370074272156,
0.0035451699513942003,
0.025523461401462555,
-0.009077750146389008,
-0.030388429760932922,
0.046569742262363434,
0.015846403315663338,
-0.030194537714123726,
-0.003373309737071395,
0.06119990348815918,
0.04674600809812546,
-0.10244637727737427,
0.0023751978296786547,
0.028132213279604912,
-0.05344415456056595,
-0.05799184367060661,
-0.04089394211769104,
0.03178093954920769,
-0.06821532547473907,
-0.06088262051343918,
-0.10427955538034439,
-0.0005114497034810483,
-0.003022979013621807,
-0.007046273443847895,
-0.000024030148779274896,
-0.04420776292681694,
0.043855227530002594,
-0.054537009447813034,
-0.010214672423899174,
0.03832044452428818,
-0.017935167998075485,
0.029066428542137146,
0.021680841222405434,
-0.006367645226418972,
0.035976093262434006,
0.0434674434363842,
0.012814611196517944,
-0.016948072239756584,
0.03824993968009949,
-0.0018265667604282498,
-0.013740012422204018,
0.07727545499801636,
-0.003022979013621807,
-0.021839480847120285,
0.05104692280292511,
0.005199876613914967,
0.01033805962651968,
0.025593968108296394,
0.003377716289833188,
0.002006138674914837,
-0.02450111322104931,
0.03340259566903114,
0.04963678494095802,
0.012003782205283642,
-0.04427827149629593,
0.006821532733738422,
0.002630784874781966,
0.0026043448597192764,
-0.0014200509758666158,
0.03141077980399132,
-0.006279511842876673,
0.027409518137574196,
0.012973250821232796,
0.0017648732755333185,
0.05763930827379227,
0.0047548022121191025,
0.05922571197152138,
0.014824054203927517,
0.032732781022787094,
0.008628269657492638,
0.004490401595830917,
-0.014515587128698826,
0.004944289103150368,
0.015185401774942875,
-0.06528929620981216,
0.0001827392989071086,
-0.02081713266670704,
0.018173128366470337,
-0.053937699645757675,
0.03955431282520294,
-0.0010509919375181198,
-0.005812404211610556,
0.03648727014660835,
-0.028326107189059258,
0.03015928342938423,
-0.0175121258944273,
-0.02841424010694027,
0.04406674951314926,
-0.03509476035833359,
0.03884924575686455,
0.005411396734416485,
0.00822726171463728,
-0.01485049445182085,
0.007244573440402746,
0.020728999748826027,
0.013449171558022499,
-0.07614734023809433,
-0.009121817536652088,
-0.042057305574417114,
-0.04752158373594284,
-0.026105143129825592,
-0.010470259934663773,
-0.03089960478246212,
0.0021570674143731594,
0.04040039703249931,
-0.040188875049352646,
0.04022412747144699,
-0.029683362692594528,
0.017908727750182152,
-0.003961600828915834,
0.004144477657973766,
0.03239787369966507,
0.00880013033747673,
-0.0255587138235569,
0.04998932033777237,
-0.01804974116384983,
-0.02451873943209648,
-0.07551278173923492,
-0.03585270792245865,
0.0706830695271492,
-0.05058863013982773,
-0.04720430076122284,
-0.0068832263350486755,
-0.04568840563297272,
-0.005949011072516441,
-0.05429023504257202,
0.0670519694685936,
-0.005089709535241127,
0.02518855407834053,
0.02361977845430374,
0.016357578337192535,
0.024342471733689308,
-0.047098543494939804,
0.03463646396994591,
-0.022650308907032013,
-0.049425266683101654,
0.002218760782852769,
0.005653764121234417,
0.028590507805347443,
-0.05312687158584595,
-0.006513065658509731,
0.044313523918390274,
0.05164622887969017,
0.04459555074572563,
-0.025699729099869728,
-0.005975451320409775,
-0.002109695691615343,
-0.001952157006599009,
-0.00033187770168296993,
-0.0018783451523631811,
0.04142274335026741,
-0.019459877163171768,
-0.00030020473059266806,
-0.06141142174601555,
-0.007914388552308083,
0.00868555624037981,
0.0046754819341003895,
0.025206180289387703,
-0.019230728968977928,
-0.025682101026177406,
-0.012796984054148197,
-0.013881025835871696,
0.019671397283673286,
-0.05189300328493118,
-0.023514017462730408,
-0.02804407849907875,
-0.050941161811351776,
-0.01180107519030571,
-0.014973881654441357,
-0.03162229806184769,
-0.0071652536280453205,
0.042057305574417114,
0.00456972187384963,
0.026351915672421455,
0.007090339902788401,
0.061763957142829895,
-0.016727738082408905,
0.009544857777655125,
0.015749456360936165,
-0.04501859098672867,
-0.052809592336416245,
-0.008002521470189095,
-0.04893171787261963,
0.04216306656599045,
-0.027779679745435715,
0.00984451174736023,
-0.035218145698308945,
0.007429653778672218,
-0.04833241179585457,
0.044172510504722595,
-0.035905588418245316,
0.01938937045633793,
-0.011774635873734951,
-0.0034856798592954874,
0.07974319159984589,
0.049954067915678024,
0.0022826576605439186,
0.008249295875430107,
-0.00413346104323864,
0.007716087624430656,
-0.001633774721994996,
-0.030881978571414948,
0.020394092425704002,
-0.003252126043662429,
0.050941161811351776,
0.01563488319516182,
-0.05756880342960358,
-0.03601134940981865,
-0.01863142102956772,
0.03909602016210556,
-0.018137874081730843,
-0.04667549952864647,
-0.00714321993291378,
0.005173436366021633,
0.02765629254281521,
-0.09659431874752045,
0.03375513106584549,
0.035976093262434006,
0.019230728968977928,
0.05199876427650452,
0.034618839621543884,
-0.014903374947607517,
0.01850803568959236,
0.12578412890434265,
0.024853646755218506,
0.04216306656599045,
-0.00512936944141984,
-0.024765513837337494,
-0.01812024787068367,
0.0713176280260086,
-0.0020006303675472736,
0.016648417338728905,
0.0152647215873003,
-0.0534089021384716,
0.011977342888712883,
0.024183832108974457,
0.05471327528357506,
-0.004243628121912479,
0.019583264365792274,
-0.063103586435318,
-0.005556817166507244,
-0.09320998936891556,
0.031216885894536972,
0.020411718636751175,
-0.07198744267225266,
0.027691544964909554,
-0.01931886374950409,
-0.0027343418914824724,
0.07889711111783981,
-0.04121122509241104,
-0.018913449719548225,
-0.08058927208185196,
0.0061913784593343735,
-0.04653448611497879,
-0.02171609364449978,
0.03276803344488144,
0.012946810573339462,
-0.012841050513088703,
-0.0949021503329277,
0.031005365774035454,
-0.006548319011926651,
0.006896446458995342,
0.01342273224145174,
-0.035746946930885315,
0.02397231198847294,
0.015582002699375153,
0.017538566142320633,
-0.024183832108974457,
-0.005790370982140303,
0.010003152303397655,
-0.034777477383613586,
0.004917849320918322,
0.03624049574136734,
0.0112810879945755,
0.052139777690172195,
-0.030617577955126762,
-0.04040039703249931,
-0.0032367026433348656,
0.034178171306848526,
-0.04653448611497879,
-0.0009187917457893491,
-0.026263782754540443,
-0.013502052053809166,
-0.04508909955620766,
-0.026880716904997826,
-0.006059178151190281,
-0.04738057032227516,
-0.016216563060879707,
-0.026598690077662468,
0.0030163689516484737,
-0.044771816581487656,
-0.017626699060201645,
0.004364811349660158,
-0.0033843263518065214,
-0.027568157762289047,
0.010082472115755081,
-0.021627960726618767,
-0.03488323837518692,
0.02247404307126999,
0.01917785033583641,
0.011492608115077019,
-0.010399753227829933,
-0.0011314137373119593,
0.10364499688148499,
0.05746304243803024,
-0.03248600661754608,
0.08383258432149887,
-0.03322632983326912,
0.00467988895252347,
-0.018067367374897003,
0.022509295493364334,
-0.0067245857790112495,
-0.016498591750860214,
-0.025823114439845085,
-0.012100729160010815,
0.07741646468639374,
0.026299037039279938,
0.041916292160749435,
-0.005001576151698828,
0.023055722936987877,
0.02106390707194805,
-0.07174067199230194,
-0.007090339902788401,
0.012488516978919506,
-0.026263782754540443,
0.09306897222995758,
0.06599436700344086,
-0.05231604352593422,
-0.03174568712711334,
-0.0428328812122345,
-0.020182570442557335,
-0.008522509597241879,
-0.007482534274458885,
-0.048755452036857605,
0.003364496398717165,
0.0046314154751598835,
-0.06264529377222061,
0.0045300619676709175,
-0.01083160750567913,
-0.009800445288419724,
-0.019424622878432274,
-0.02938370779156685,
0.016057923436164856,
-0.02247404307126999,
0.017952794209122658,
-0.02083475887775421,
0.026334289461374283,
0.015987416729331017,
-0.03373750299215317,
-0.012047849595546722,
-0.06165819615125656,
-0.020341211929917336,
-0.02735663764178753,
-0.025294315069913864,
0.00031728058820590377,
-0.032574139535427094,
-0.05524207651615143,
-0.04872019961476326,
0.0384967140853405,
-0.02751527912914753,
0.035887960344552994,
0.061622943729162216,
0.010011965408921242,
-0.01270885020494461,
0.015335229225456715,
0.012911557219922543,
-0.00261095492169261,
-0.011210581287741661,
-0.019653771072626114,
0.06261003762483597,
-0.05157572403550148,
0.02765629254281521,
0.07523075491189957,
-0.017274165526032448,
-0.061975475400686264,
-0.00025847903452813625,
0.006477812305092812,
-0.043855227530002594,
0.009192324243485928,
-0.002514007966965437,
-0.0161724966019392,
0.0052439430728554726,
0.008500476367771626,
0.0009006141917780042,
-0.09997864067554474,
0.0350242517888546,
-0.0006059178267605603,
0.056722719222307205,
0.02420145832002163,
0.021821854636073112,
0.008782503195106983,
0.04551213979721069,
0.027462398633360863,
-0.02742714434862137,
0.013775265775620937,
-0.012673596851527691,
-0.03888449817895889,
-0.002474348060786724,
-0.01397797279059887,
-0.0102939922362566,
0.060107044875621796,
0.03712182864546776,
-0.014859307557344437,
0.06962546706199646,
-0.042973894625902176,
0.01394271943718195,
0.011272274889051914,
-0.04547688737511635,
0.026722077280282974,
0.023408256471157074,
0.07417315244674683,
0.032062966376543045,
-0.024007564410567284,
0.021152039989829063,
0.045300617814064026,
0.11640672385692596,
-0.0478036105632782,
-0.01243563648313284,
0.0015423361910507083,
0.0414932519197464,
0.03313819691538811,
-0.0683915987610817,
0.00625747861340642,
-0.00987976510077715,
-0.031305018812417984,
-0.0050368295051157475,
0.05005982890725136,
-0.02548820711672306,
0.025170927867293358
]
|
32,792 | traittypes.traittypes | validate | null | def validate(self, obj, value):
if value is None and not self.allow_none:
self.error(obj, value)
if value is None or value is Undefined:
return super(PandasType, self).validate(obj, value)
try:
value = self.klass(value)
except (ValueError, TypeError) as e:
raise TraitError(e)
return super(PandasType, self).validate(obj, value)
| (self, obj, value) | [
0.06648970395326614,
-0.0016635472420603037,
0.04182136058807373,
0.019014453515410423,
-0.027121257036924362,
-0.025538168847560883,
0.020301800221204758,
0.0013003938365727663,
-0.005471222102642059,
-0.038098495453596115,
0.02706906758248806,
0.02600787580013275,
0.05340747907757759,
-0.04867561161518097,
0.008441686630249023,
0.05184178799390793,
-0.010142202489078045,
0.06753349304199219,
0.06179262697696686,
0.050345681607723236,
-0.010524926707148552,
-0.019258005544543266,
-0.035471610724925995,
0.03966418653726578,
-0.0016341905575245619,
0.05716513842344284,
0.01950155757367611,
-0.010524926707148552,
-0.018683919683098793,
0.03962939232587814,
-0.0007012993446551263,
0.00807201024144888,
0.009942141361534595,
0.04036004841327667,
0.01877090148627758,
-0.04958023130893707,
-0.0612359382212162,
0.001078043831512332,
-0.07313518971204758,
0.029869915917515755,
-0.06419335305690765,
0.029330622404813766,
-0.035802148282527924,
-0.015187208540737629,
-0.013160507194697857,
-0.039420634508132935,
-0.0059626754373312,
0.06882084161043167,
-0.06610697507858276,
-0.01830119453370571,
-0.0019766855984926224,
0.002252856269478798,
0.01864912547171116,
-0.023694131523370743,
-0.02607746236026287,
0.05848727747797966,
0.012073221616446972,
0.058591656386852264,
0.02245897613465786,
0.033436212688684464,
-0.025242427363991737,
0.033557988703250885,
0.008950537070631981,
-0.067742258310318,
0.00787194911390543,
-0.037367839366197586,
0.015778692439198494,
-0.03054838255047798,
-0.02699948102235794,
0.032305434346199036,
-0.03531504422426224,
-0.02640799805521965,
-0.0022724273148924112,
0.09637701511383057,
0.051006752997636795,
-0.05396416783332825,
-0.06621135771274567,
0.020928077399730682,
0.02910446748137474,
-0.024529168382287025,
0.024129046127200127,
0.03604570031166077,
-0.026790723204612732,
-0.018875282257795334,
-0.014795784838497639,
0.007402241695672274,
-0.06461086869239807,
0.03747221827507019,
0.05135468393564224,
0.05490358546376228,
-0.027956292033195496,
-0.040012117475271225,
0.011647005565464497,
0.013282283209264278,
-0.007441384252160788,
0.05319872125983238,
0.03590652719140053,
-0.0494062677025795,
-0.031331226229667664,
0.006097498815506697,
0.028043275699019432,
0.005745218135416508,
0.04011649638414383,
0.035610783845186234,
0.018997058272361755,
-0.005710424855351448,
0.05664324015378952,
-0.03576735407114029,
-0.009107106365263462,
0.0272082407027483,
-0.03583693876862526,
-0.021189026534557343,
-0.020058248192071915,
-0.0036989462096244097,
-0.010881556198000908,
-0.07452692091464996,
-0.051145926117897034,
-0.014152112416923046,
-0.06005296856164932,
0.010916349478065968,
-0.00749357370659709,
0.05177219957113266,
0.011116409674286842,
0.005953976884484291,
0.07153470814228058,
0.022511165589094162,
0.01349974051117897,
-0.030809329822659492,
0.05392937734723091,
0.04095153138041496,
0.008776570670306683,
-0.01976250670850277,
-0.020701922476291656,
-0.0018810044275596738,
-0.008933139964938164,
0.07550112903118134,
0.04617050290107727,
0.0040142592042684555,
-0.026512376964092255,
-0.03411468118429184,
0.04300432652235031,
0.02167613059282303,
0.0594266913831234,
-0.06826414912939072,
0.061409901827573776,
0.06179262697696686,
-0.03004388138651848,
0.05013692378997803,
-0.04749264568090439,
0.019727714359760284,
-0.03235762566328049,
-0.002405076287686825,
0.03162696957588196,
0.02877393178641796,
-0.0221980269998312,
-0.019136229529976845,
0.011359961703419685,
-0.06958629190921783,
0.03392331674695015,
-0.00007060562347760424,
-0.012334169819951057,
-0.010681496001780033,
-0.005766964051872492,
-0.02659936062991619,
0.017074735835194588,
0.07974588871002197,
0.006380192935466766,
-0.0204931627959013,
0.0008665667846798897,
0.029295828193426132,
0.0026073113549500704,
-0.024790115654468536,
0.011551324278116226,
0.058382898569107056,
0.002763880416750908,
0.05876562371850014,
-0.011307772248983383,
0.028686948120594025,
0.00090570910833776,
0.03576735407114029,
0.016613727435469627,
0.030130865052342415,
-0.038168080151081085,
0.01515241526067257,
0.03903790935873985,
0.037889737635850906,
-0.025120651349425316,
-0.01129037607461214,
0.008767873048782349,
0.05017171800136566,
0.0037707071751356125,
0.02706906758248806,
0.02567734196782112,
-0.0007170650060288608,
0.014708802103996277,
-0.02338099479675293,
0.04122987762093544,
-0.009698589332401752,
-0.01030746940523386,
0.03966418653726578,
0.028930500149726868,
-0.02576432377099991,
0.02905227616429329,
-0.01737917587161064,
-0.06360187381505966,
0.00591048551723361,
-0.0026638503186404705,
0.03792452812194824,
-0.019449368119239807,
-0.05796538293361664,
-0.04512671008706093,
-0.048049334436655045,
-0.04836247116327286,
0.019727714359760284,
0.042969536036252975,
-0.08030258119106293,
0.02753877453505993,
-0.09046217799186707,
0.008485178463160992,
0.045683398842811584,
0.1099463403224945,
0.016718106344342232,
0.009115803986787796,
-0.005075450055301189,
0.08183348178863525,
-0.010872857645154,
-0.01501324214041233,
-0.07236974686384201,
0.02752137929201126,
-0.009107106365263462,
-0.046518437564373016,
-0.012064523063600063,
-0.04168218746781349,
0.0022169756703078747,
-0.0002476293302606791,
0.07017777860164642,
0.07452692091464996,
-0.013134412467479706,
-0.060818418860435486,
0.01261251512914896,
-0.024685736745595932,
-0.024389995262026787,
-0.019379781559109688,
0.025781720876693726,
-0.016613727435469627,
0.020075645297765732,
0.019971266388893127,
0.0694471225142479,
-0.03472356125712395,
-0.013160507194697857,
0.01817941851913929,
0.0037076445296406746,
-0.010029124096035957,
-0.017213908955454826,
0.02134559489786625,
-0.026425395160913467,
-0.00029519808595068753,
-0.05935710668563843,
0.09895170480012894,
-0.013377964496612549,
-0.024529168382287025,
0.01613532193005085,
0.03733304515480995,
0.0771711990237236,
-0.06683763116598129,
-0.03009607084095478,
0.018492557108402252,
0.035802148282527924,
0.03220105543732643,
0.04822330176830292,
-0.054555654525756836,
0.003922927193343639,
0.01797066070139408,
0.020980266854166985,
-0.006649840157479048,
0.001553731388412416,
-0.00955071859061718,
-0.0113251693546772,
0.035871732980012894,
-0.012473342940211296,
0.013143111020326614,
-0.03896832466125488,
0.0359761118888855,
-0.028095465153455734,
-0.010751081630587578,
-0.013203999027609825,
-0.011873161420226097,
-0.030913710594177246,
-0.05406855046749115,
0.009272373281419277,
-0.03611528500914574,
-0.030652761459350586,
0.0002019633393501863,
0.002235459629446268,
-0.034480009227991104,
0.0034901874605566263,
0.013934655115008354,
-0.04352622479200363,
0.01988428272306919,
-0.024946685880422592,
-0.033557988703250885,
0.0009894301183521748,
0.007615349721163511,
0.02811286225914955,
0.026912499219179153,
-0.03917708247900009,
0.025398995727300644,
-0.005049355328083038,
-0.023085251450538635,
0.02198926731944084,
0.007541414350271225,
0.050484854727983475,
-0.06314955651760101,
0.0238507017493248,
0.06426294147968292,
0.04331746697425842,
0.012951748445630074,
-0.0313660204410553,
-0.008833110332489014,
0.056086551398038864,
-0.04707512632012367,
-0.0478057824075222,
-0.005123290698975325,
-0.0401860848069191,
-0.0553211010992527,
0.003361887764185667,
0.01712692528963089,
0.01527419127523899,
-0.03583693876862526,
0.033871129155159,
0.002219150308519602,
-0.016709407791495323,
0.07640574872493744,
0.029487190768122673,
0.03851601108908653,
-0.03030483052134514,
-0.0064671761356294155,
0.004373063333332539,
0.02101505920290947,
0.06662887334823608,
0.021328197792172432,
0.004388285335153341,
0.043769776821136475,
-0.023415787145495415,
0.014395664446055889,
-0.011055521667003632,
-0.024790115654468536,
-0.0008529757033102214,
0.07424857467412949,
0.055425480008125305,
-0.06394980102777481,
0.029991691932082176,
-0.027817120775580406,
-0.03973377123475075,
-0.01770971156656742,
-0.044291675090789795,
0.018405573442578316,
0.030130865052342415,
-0.04255201667547226,
-0.06210576370358467,
0.08586948364973068,
-0.05493837594985962,
0.012168902903795242,
-0.011612212285399437,
-0.009863857179880142,
0.04905833676457405,
-0.04484836384654045,
-0.03973377123475075,
0.014378267340362072,
-0.005227670073509216,
-0.011490436270833015,
0.0209454745054245,
-0.024616150185465813,
-0.08531279116868973,
0.020301800221204758,
0.06342790275812149,
0.003470616415143013,
0.03127903863787651,
-0.012786481529474258,
-0.0036445821169763803,
0.05017171800136566,
-0.04234325885772705,
-0.031522590667009354,
-0.027121257036924362,
-0.01844036765396595,
-0.01817941851913929,
-0.015300286002457142,
0.02226761355996132,
-0.045613814145326614,
-0.02997429482638836,
-0.018127229064702988,
0.014352172613143921,
0.028947897255420685,
-0.03550640493631363,
-0.0033749351277947426,
0.001341710682027042,
0.010194391943514347,
-0.00708040501922369,
-0.00556690338999033,
-0.012438549660146236,
-0.011429548263549805,
-0.016109226271510124,
-0.00481015257537365,
0.07598823308944702,
0.01744876243174076,
0.03209667652845383,
0.023137442767620087,
0.00009119609603658319,
0.0003003627061843872,
0.028826121240854263,
0.06993422657251358,
-0.039942532777786255,
0.033297039568424225,
-0.020771509036421776,
0.008976631797850132,
-0.001513501862064004,
0.007415289059281349,
-0.02364194206893444,
0.02614704892039299,
-0.031522590667009354,
0.013838973827660084,
-0.013299680314958096,
-0.017831487581133842,
0.0494062677025795,
0.004059925209730864,
0.0009964974597096443,
0.0063367015682160854,
-0.02522503025829792,
0.031331226229667664,
-0.002450742293149233,
0.008880950510501862,
0.004140384495258331,
-0.04338705167174339,
-0.04383936524391174,
0.030861521139740944,
-0.04084715247154236,
-0.0619318000972271,
-0.010072615928947926,
0.00200060592032969,
0.04220408573746681,
0.01969292014837265,
0.004075147211551666,
0.04272598400712013,
0.0612359382212162,
0.02331140823662281,
-0.0034640925005078316,
0.046414054930210114,
0.023067856207489967,
-0.06826414912939072,
-0.01198623888194561,
0.014752293936908245,
0.0026529773604124784,
0.036393631249666214,
0.006162736099213362,
-0.05375541001558304,
-0.004510061349719763,
-0.06475004553794861,
-0.04036004841327667,
0.055286310613155365,
-0.027086464688181877,
-0.020388783887028694,
0.023137442767620087,
-0.060366109013557434,
-0.04801454022526741,
-0.06697680801153183,
0.08941838145256042,
-0.00955071859061718,
0.00426650932058692,
0.017622727900743484,
0.034480009227991104,
-0.002181095303967595,
-0.04157780855894089,
0.03181833028793335,
-0.02877393178641796,
-0.032044488936662674,
0.03708949312567711,
0.018075039610266685,
0.002072366653010249,
-0.00892444234341383,
-0.005840899422764778,
0.018022850155830383,
0.04822330176830292,
0.03284472972154617,
0.005953976884484291,
-0.0001970705488929525,
-0.035662975162267685,
-0.01047273725271225,
0.018353383988142014,
-0.01498714741319418,
0.05024130269885063,
0.0059800720773637295,
0.004118638578802347,
-0.020980266854166985,
0.03425385057926178,
0.004636186640709639,
-0.014413060620427132,
0.024529168382287025,
-0.03321005776524544,
-0.0013210522010922432,
-0.027643155306577682,
0.022024061530828476,
0.048118919134140015,
-0.06106197088956833,
-0.00823292788118124,
0.020580146461725235,
-0.09463735669851303,
0.011907953768968582,
0.02404206432402134,
-0.034149471670389175,
-0.04550943523645401,
-0.06137510761618614,
0.06982984393835068,
0.008654794655740261,
0.04011649638414383,
0.014352172613143921,
0.008480829186737537,
0.02233720012009144,
-0.011403453536331654,
-0.05118071660399437,
-0.004020783118903637,
0.0015417712274938822,
-0.042656395584344864,
0.006132292095571756,
-0.03371455892920494,
0.009315865114331245,
0.028008483350276947,
-0.02943500131368637,
-0.03555859625339508,
0.020980266854166985,
-0.03550640493631363,
0.04116029292345047,
-0.030913710594177246,
0.017622727900743484,
0.04543984681367874,
0.03952501341700554,
-0.011012030765414238,
0.005092846695333719,
0.020440973341464996,
-0.042656395584344864,
0.002376806689426303,
0.006280162837356329,
0.02626882493495941,
0.007297862321138382,
0.025642547756433487,
0.014317379333078861,
-0.04710992053151131,
0.0007980677764862776,
0.011455642990767956,
-0.008411242626607418,
0.027625758200883865,
-0.02378111518919468,
-0.014665311202406883,
0.059496279805898666,
0.09415025264024734,
-0.06388021260499954,
0.03300129994750023,
0.017074735835194588,
0.07250891625881195,
0.0655502900481224,
-0.0045448546297848225,
0.008902695961296558,
-0.02252856269478798,
0.08044175058603287,
-0.03837684169411659,
-0.051006752997636795,
-0.030513588339090347,
-0.019379781559109688,
0.024859702214598656,
0.024007270112633705,
0.009307166561484337,
-0.014473948627710342,
-0.004214319866150618,
-0.0520157516002655,
-0.002252856269478798,
0.05274640768766403,
0.04328267276287079,
-0.06116634979844093,
0.033418815582990646,
-0.10361398756504059,
-0.034027695655822754,
-0.06137510761618614,
-0.017440063878893852,
0.007985026575624943,
-0.06255807727575302,
-0.016161415725946426,
-0.04766660928726196,
-0.035523802042007446,
-0.0018320765811949968,
-0.04157780855894089,
-0.022111043334007263,
-0.030809329822659492,
0.00041289679938927293,
-0.056156136095523834,
-0.02567734196782112,
0.05229409784078598,
0.044883158057928085,
-0.05504275858402252,
-0.07000380754470825,
0.029069673269987106,
-0.010229185223579407,
-0.03670676797628403,
0.041786570101976395,
-0.01334317121654749,
0.0003873455571010709,
0.03653280436992645,
-0.00354890082962811,
0.006036610808223486,
0.04825809225440025,
0.022180629894137383,
-0.06722036004066467,
-0.0011307772947475314,
0.05493837594985962,
0.02172832004725933,
0.022946080192923546,
-0.032305434346199036,
-0.05058923363685608,
-0.05104154348373413,
0.0007360925083048642,
-0.027956292033195496,
-0.01725739985704422,
0.011464341543614864,
-0.010081314481794834,
-0.00217239698395133,
0.007163038942962885,
-0.019136229529976845,
-0.02153695747256279,
-0.0009078836301341653,
-0.03213147073984146,
-0.046205297112464905,
-0.10417068004608154,
0.00722827622666955,
0.03785494342446327,
-0.0034836637787520885,
-0.051006752997636795,
-0.044952742755413055,
-0.0021517386194318533,
-0.016718106344342232,
-0.01425649132579565,
0.03413207456469536,
0.03494971618056297,
-0.016239700838923454,
-0.03425385057926178,
0.00679771089926362,
0.05643448233604431,
-0.020388783887028694,
-0.0012688625138252974,
-0.035662975162267685,
-0.013899861834943295,
0.011907953768968582,
0.027156051248311996,
0.005375540815293789,
0.025329411029815674,
-0.056991174817085266,
-0.0685424953699112,
0.09860377758741379,
0.02957417443394661,
0.023815907537937164,
-0.02813025936484337,
-0.00422954186797142,
-0.003074844367802143,
-0.038829151540994644,
-0.04213450103998184,
-0.0003479314618743956,
-0.017570538446307182,
0.07863251119852066,
0.02990470826625824,
-0.029956897720694542,
-0.013969448395073414,
0.03148779645562172,
-0.023015666753053665,
-0.040081705898046494,
0.022841699421405792,
-0.06127072870731354,
0.04025566950440407,
-0.044222086668014526,
-0.031244244426488876,
-0.03089631348848343,
-0.025781720876693726,
-0.023207027465105057,
-0.023868098855018616,
0.017474858090281487,
0.003927276469767094,
-0.06572425365447998,
0.0368807353079319,
-0.02832162007689476,
-0.05518192797899246,
0.011751385405659676,
-0.030322225764393806,
0.007776268292218447,
-0.09449818730354309,
-0.009637701325118542,
-0.016370175406336784,
-0.005875692702829838,
0.003988164477050304,
-0.050345681607723236,
-0.09011425077915192,
-0.030809329822659492,
0.054625239223241806,
0.0034184264950454235,
0.07751912623643875,
-0.0028051973786205053,
-0.006497620139271021,
-0.005162433255463839,
0.04756223037838936,
0.05730431154370308,
0.012264584191143513,
-0.03449740260839462,
0.020440973341464996,
0.067742258310318,
-0.034340836107730865,
-0.006497620139271021,
0.05184178799390793,
-0.021780509501695633,
-0.05156344175338745,
-0.05302475392818451,
0.012621213681995869,
0.014056431129574776,
0.043769776821136475,
0.02141518145799637,
-0.043108709156513214,
0.027312619611620903,
0.01438696589320898,
-0.004562251269817352,
0.019866885617375374,
0.044883158057928085,
0.0226503387093544,
-0.039872944355010986,
-0.033018697053194046,
0.00016445197979919612,
-0.010150900110602379,
0.07633616030216217,
0.021310802549123764,
-0.017109530046582222,
0.009959538467228413,
0.003205318469554186,
-0.022111043334007263,
-0.017353082075715065,
0.02331140823662281,
-0.0036728514824062586,
0.029887313023209572,
-0.0040338304825127125,
0.0037076445296406746,
0.039942532777786255,
-0.04394374415278435,
0.0486060231924057,
0.039281461387872696,
-0.000060378341004252434,
0.02456396073102951,
0.041890949010849,
0.007784966379404068,
0.027312619611620903,
-0.06127072870731354,
0.016979055479168892,
0.06419335305690765,
0.059496279805898666,
-0.032166264951229095,
-0.018736109137535095,
0.01824900507926941,
0.005258114077150822,
0.014526138082146645,
-0.04505712538957596,
0.02167613059282303,
-0.022371992468833923,
0.0046796780079603195,
-0.015135018154978752,
0.013795481994748116,
-0.02331140823662281,
0.04397853463888168
]
|
32,793 | bqplot.traits | Date |
A datetime trait type.
Converts the passed date into a string format that can be used to
construct a JavaScript datetime.
| class Date(TraitType):
"""
A datetime trait type.
Converts the passed date into a string format that can be used to
construct a JavaScript datetime.
"""
def validate(self, obj, value):
try:
if isinstance(value, dt.datetime):
return value
if isinstance(value, dt.date):
return dt.datetime(value.year, value.month, value.day)
if np.issubdtype(np.dtype(value), np.datetime64):
# TODO: Fix this. Right now, we have to limit the precision
# of time to microseconds because np.datetime64.astype(datetime)
# returns date values only for precision <= 'us'
value_truncated = np.datetime64(value, 'us')
return value_truncated.astype(dt.datetime)
except Exception:
self.error(obj, value)
self.error(obj, value)
def __init__(self, default_value=dt.datetime.today(), **kwargs):
super(Date, self).__init__(default_value=default_value, **kwargs)
self.tag(**date_serialization)
| (default_value: Any = datetime.datetime(2024, 5, 12, 8, 41, 20, 704540), **kwargs) | [
0.023703107610344887,
0.0011717407032847404,
0.015668313950300217,
0.01902780868113041,
-0.007465545553714037,
-0.020343611016869545,
-0.06170273572206497,
-0.0011921543627977371,
-0.0026945953723043203,
-0.02286323346197605,
0.0549464151263237,
0.07215449959039688,
-0.004267025738954544,
0.0025942770298570395,
0.009471911005675793,
0.0022466627415269613,
0.012047524563968182,
0.06640602648258209,
0.004353346303105354,
-0.004731289576739073,
-0.01127297431230545,
-0.05722340568900108,
-0.03426685556769371,
0.04359878599643707,
0.01160892378538847,
0.05561831593513489,
0.018187936395406723,
-0.005001915618777275,
-0.018635869026184082,
0.008202767930924892,
-0.026409367099404335,
0.018467893823981285,
0.021575426682829857,
0.04218033328652382,
0.05453580990433693,
-0.06752586364746094,
-0.03859687224030495,
0.01249545719474554,
-0.11392422765493393,
0.06274791061878204,
-0.02769717387855053,
-0.020156973972916603,
-0.058044616132974625,
-0.04960855096578598,
-0.029750199988484383,
-0.03363228216767311,
-0.034472156316041946,
0.08876533806324005,
-0.05744737386703491,
0.0011221648892387748,
0.03159792348742485,
-0.054199863225221634,
0.03141128271818161,
0.02556949481368065,
-0.09048241376876831,
0.081299789249897,
0.04038860276341438,
0.12654100358486176,
-0.018458561971783638,
0.05196019634604454,
-0.048488717526197433,
0.013652616180479527,
0.036543846130371094,
-0.03436017408967018,
-0.030814040452241898,
0.002195337088778615,
-0.023777762427926064,
-0.05636487156152725,
0.031205980107188225,
0.017740003764629364,
-0.015612322837114334,
0.00745621370151639,
0.055916935205459595,
0.09929175674915314,
0.03561065346002579,
0.009630554355680943,
-0.06909362226724625,
0.032157838344573975,
0.0247669480741024,
-0.013969901949167252,
0.04684630036354065,
-0.0002868110896088183,
-0.03783165290951729,
-0.03348297253251076,
-0.0071062664501369,
-0.014604473486542702,
-0.017254741862416267,
0.06539817899465561,
-0.0173107348382473,
0.036543846130371094,
-0.005482510197907686,
-0.015463011339306831,
0.00042606101487763226,
0.047144919633865356,
-0.03316568583250046,
0.03548000752925873,
0.017805326730012894,
0.0031401950400322676,
-0.04475594684481621,
0.015854952856898308,
0.013316666707396507,
-0.017264073714613914,
-0.05405054986476898,
-0.004435000941157341,
-0.0268386360257864,
0.01565898209810257,
0.029339594766497612,
0.009364593774080276,
-0.016377540305256844,
-0.020754216238856316,
-0.0600229874253273,
0.009103300049901009,
-0.04456930607557297,
-0.028686359524726868,
0.010125146247446537,
-0.004428001586347818,
-0.015192385762929916,
-0.019988998770713806,
0.021892713382840157,
0.013018045574426651,
-0.01645219698548317,
0.02833174541592598,
0.021836720407009125,
0.04255361109972,
0.014063221402466297,
-0.004059390630573034,
0.033240340650081635,
0.009611889719963074,
-0.0072649093344807625,
0.008118781261146069,
-0.03378159552812576,
0.05069105327129364,
0.013633952476084232,
0.0387461818754673,
-0.00007939432543935254,
0.003387491451576352,
-0.042292315512895584,
0.0021171821281313896,
-0.05308002978563309,
0.05729806423187256,
0.021444780752062798,
-0.003744437824934721,
0.029264939948916435,
-0.023105863481760025,
0.026446696370840073,
0.005071904975920916,
0.019205115735530853,
0.03045942634344101,
-0.06267325580120087,
0.015621654689311981,
0.004577312618494034,
-0.0039030807092785835,
0.0005205468623898923,
0.012439465150237083,
0.034416165202856064,
-0.07226648181676865,
-0.001412621233612299,
-0.06991483271121979,
0.0020180302672088146,
-0.00659767584875226,
-0.023815089836716652,
-0.01416587270796299,
-0.02887299843132496,
-0.005300537217408419,
0.02045559510588646,
0.06364377588033676,
0.04964587837457657,
-0.06334515661001205,
-0.01690012961626053,
0.028630368411540985,
-0.004899264313280582,
-0.00862270500510931,
0.04285223037004471,
0.04729423299431801,
0.0022711590863764286,
0.041023172438144684,
0.010713057592511177,
0.04486792907118797,
-0.0020623570308089256,
0.037626348435878754,
0.05028045177459717,
0.005459180101752281,
-0.08450997620820999,
0.04968320578336716,
-0.0003933992702513933,
0.03389357775449753,
-0.02064223401248455,
-0.0486007034778595,
0.022825906053185463,
0.07491675019264221,
0.05554366111755371,
0.07883616536855698,
0.003161191940307617,
-0.012822074815630913,
0.007890149019658566,
-0.006970953196287155,
-0.01908380165696144,
-0.02801446057856083,
-0.052482787519693375,
0.04837673529982567,
0.0031121992506086826,
0.015127061866223812,
0.010255793109536171,
-0.08682429790496826,
-0.00018838838150259107,
-0.00561315705999732,
-0.005650484934449196,
0.016209565103054047,
-0.057820651680231094,
-0.06741387397050858,
-0.012700759805738926,
-0.05345330759882927,
-0.033147022128105164,
0.02435634285211563,
0.0016517519252374768,
-0.10578678548336029,
-0.009798528626561165,
-0.042665593326091766,
-0.053751930594444275,
-0.012654099613428116,
0.09137827903032303,
0.055282365530729294,
-0.009882516227662563,
-0.012318150140345097,
0.05166157707571983,
-0.008930658921599388,
0.017609355971217155,
-0.0495338961482048,
-0.012066188268363476,
-0.04647302255034447,
-0.00851072184741497,
-0.03643186390399933,
0.0027085933834314346,
-0.007759501691907644,
-0.02232198230922222,
0.05606624856591225,
0.03945541009306908,
-0.047816820442676544,
-0.002969887340441346,
0.02375909872353077,
-0.0020075319334864616,
-0.016433533281087875,
0.008403404615819454,
-0.021071502938866615,
0.006588343996554613,
-0.006467028986662626,
-0.010097150690853596,
0.06913094967603683,
-0.052893392741680145,
-0.021295469254255295,
-0.0054358504712581635,
-0.03217650204896927,
0.0016692493809387088,
-0.006154409144073725,
-0.006928959395736456,
-0.0019912009593099356,
0.07764167338609695,
-0.004138711839914322,
0.04412137344479561,
-0.01797330193221569,
0.013316666707396507,
-0.008249428123235703,
-0.00790881272405386,
0.05169890448451042,
-0.0530427023768425,
-0.06774982810020447,
0.0003499474551063031,
0.037682343274354935,
0.010199801996350288,
0.026987947523593903,
-0.005417186766862869,
-0.00019013811834156513,
-0.034098878502845764,
-0.052706751972436905,
-0.008324083872139454,
-0.035144057124853134,
-0.010666398331522942,
-0.03706643357872963,
0.0017695676069706678,
0.01610691472887993,
-0.04893665015697479,
-0.05337865278124809,
0.028369072824716568,
-0.003499474609270692,
-0.041396450251340866,
-0.04553982987999916,
0.017870649695396423,
0.011011679656803608,
-0.022695258259773254,
0.02077287994325161,
-0.044382669031620026,
-0.02041826769709587,
0.007600858807563782,
0.019447745755314827,
-0.07249044626951218,
0.00520721822977066,
-0.011804894544184208,
-0.0336696095764637,
0.008911995217204094,
-0.06054557487368584,
0.010321117006242275,
0.05009381100535393,
0.028257090598344803,
0.01410054974257946,
-0.01513639371842146,
-0.0511389896273613,
-0.03456547483801842,
-0.03322167694568634,
-0.046696987003088,
0.01753470115363598,
0.0061917370185256,
-0.009901179932057858,
-0.08824274688959122,
-0.0444573238492012,
-0.02290056087076664,
0.026446696370840073,
-0.012430133298039436,
-0.002822909504175186,
0.046920955181121826,
0.06883233040571213,
0.008030127733945847,
-0.006952289491891861,
0.006275724153965712,
-0.029078301042318344,
0.0022011694964021444,
-0.02566281333565712,
0.009975835680961609,
0.00959322601556778,
-0.01398856658488512,
0.06498757749795914,
0.005902447272092104,
0.009490574710071087,
0.02928360365331173,
0.037085097283124924,
0.03290439397096634,
-0.006849638186395168,
0.0017719005700200796,
-0.06614473462104797,
-0.01538835559040308,
0.02820109948515892,
-0.027398552745580673,
0.001165908295661211,
0.007017612922936678,
-0.018187936395406723,
-0.002149843843653798,
-0.02769717387855053,
-0.016125578433275223,
0.032251156866550446,
0.053154684603214264,
0.025812124833464622,
-0.007936808280646801,
0.03404288738965988,
0.007460879627615213,
0.009476576931774616,
-0.04020196199417114,
-0.08189703524112701,
0.04199369624257088,
-0.022116679698228836,
-0.03305370360612869,
0.008641368709504604,
0.008375409059226513,
0.00315186008810997,
0.03729040175676346,
-0.026950620114803314,
0.0581192746758461,
0.022396637126803398,
0.03413620591163635,
-0.047592852264642715,
0.06431567668914795,
-0.019429082050919533,
-0.018215931951999664,
0.006644335575401783,
-0.020623570308089256,
-0.0701761320233345,
0.029115628451108932,
-0.014156540855765343,
0.013409986160695553,
0.04811544343829155,
-0.0765218436717987,
-0.03941808268427849,
0.016974784433841705,
-0.04766751080751419,
-0.006308386102318764,
0.02553216554224491,
0.003359495662152767,
-0.0015595991862937808,
0.048899322748184204,
0.019858350977301598,
-0.036917123943567276,
-0.026017427444458008,
0.002395973540842533,
-0.062486618757247925,
0.002442633267492056,
0.02874235063791275,
-0.048190098255872726,
-0.03204585611820221,
-0.0025009578093886375,
0.04580112174153328,
0.012859402224421501,
0.04367344081401825,
-0.010507755912840366,
-0.01702144369482994,
0.003301170887425542,
0.03281107172369957,
-0.012066188268363476,
0.0682724118232727,
0.03919411450624466,
-0.031019343063235283,
-0.02598009817302227,
0.04833940789103508,
0.029750199988484383,
-0.024561645463109016,
-0.0222286619246006,
-0.016032259911298752,
0.050579071044921875,
0.014007230289280415,
-0.0016622503753751516,
-0.030478090047836304,
0.023516468703746796,
0.009807860478758812,
0.01759069226682186,
0.034509483724832535,
-0.029003644362092018,
0.01959705725312233,
0.004488659556955099,
-0.019895678386092186,
0.026558678597211838,
0.03792497143149376,
-0.03882083669304848,
0.04744354262948036,
0.06371843069791794,
0.029302267357707024,
-0.10653333365917206,
-0.05371459946036339,
0.02426302433013916,
-0.011030343361198902,
-0.034098878502845764,
-0.04475594684481621,
0.006830974481999874,
0.04665965959429741,
-0.050579071044921875,
0.059313759207725525,
0.04871268570423126,
0.003455147845670581,
0.006322383880615234,
-0.015173721127212048,
0.005608491133898497,
0.06886965781450272,
-0.06610740721225739,
-0.03833557665348053,
0.040761880576610565,
0.041209813207387924,
0.0258867796510458,
-0.0457264669239521,
-0.008599375374615192,
-0.038858164101839066,
0.01513639371842146,
-0.05042976140975952,
0.032475125044584274,
0.0022711590863764286,
0.022116679698228836,
0.00043714270577766,
-0.026857299730181694,
-0.04274024814367294,
-0.020436931401491165,
-0.0005502923741005361,
-0.035106729716062546,
-0.018001297488808632,
-0.06327050179243088,
0.026577342301607132,
0.024113712832331657,
0.021762065589427948,
0.05979901924729347,
-0.04486792907118797,
-0.02530819922685623,
0.03348297253251076,
-0.025140225887298584,
0.013913910835981369,
0.002741255098953843,
-0.0024729620199650526,
-0.016246894374489784,
-0.020810209214687347,
-0.001540935249067843,
-0.009798528626561165,
-0.01563098654150963,
0.01518305391073227,
0.01877584680914879,
0.003273175098001957,
0.010395772755146027,
0.07140794396400452,
-0.038092948496341705,
0.07476744055747986,
-0.014249860309064388,
0.004411670845001936,
0.04748087003827095,
0.0024589640088379383,
0.006107749417424202,
-0.017730670049786568,
0.031038006767630577,
0.04393473640084267,
-0.0327177532017231,
0.020623570308089256,
-0.03014214150607586,
0.016153573989868164,
0.04591310769319534,
-0.03146727383136749,
0.024654963985085487,
0.03997799754142761,
-0.02394573763012886,
-0.06360644847154617,
-0.03721574693918228,
0.01762801967561245,
0.016284221783280373,
0.01803862489759922,
0.012075520120561123,
-0.020399603992700577,
0.028947653248906136,
0.009504572488367558,
-0.02864903211593628,
-0.07316234707832336,
-0.01797330193221569,
0.016116246581077576,
0.03408021479845047,
-0.05767134204506874,
-0.015145725570619106,
0.03615190461277962,
-0.02665199711918831,
0.016694827005267143,
0.011618255637586117,
0.019970335066318512,
0.03870885446667671,
-0.027454543858766556,
0.000392232759622857,
0.03290439397096634,
-0.008576045744121075,
0.05326666682958603,
-0.009308602660894394,
0.021780729293823242,
0.0650995597243309,
-0.03042209893465042,
-0.052258819341659546,
0.01692812517285347,
0.032568443566560745,
0.05386391282081604,
0.01593893952667713,
0.02318052016198635,
0.04400939121842384,
0.0686083659529686,
-0.01260744035243988,
0.0075588650070130825,
-0.05072838440537453,
0.0015934273833408952,
0.05729806423187256,
0.06524886935949326,
-0.03268042579293251,
-0.02045559510588646,
0.018122611567378044,
0.004682296887040138,
0.002169674262404442,
-0.03770100697875023,
-0.012486125342547894,
0.02484160289168358,
0.03997799754142761,
0.02530819922685623,
-0.10578678548336029,
0.04624905437231064,
0.023796426132321358,
0.04707026481628418,
-0.060321610420942307,
0.04255361109972,
0.024337679147720337,
-0.007960137911140919,
-0.011814226396381855,
-0.02489759400486946,
0.04281490296125412,
0.07103466987609863,
-0.05707409605383873,
0.005809127818793058,
-0.050317779183387756,
0.015257708728313446,
-0.004936592187732458,
0.024505654349923134,
0.018411902710795403,
-0.10280056297779083,
0.010871700942516327,
0.004292688798159361,
-0.030086148530244827,
0.03118731640279293,
0.011674246750772,
-0.05337865278124809,
0.005841789301484823,
0.006700327154248953,
-0.030590074136853218,
0.021612754091620445,
0.01972770504653454,
0.0009693544707261026,
-0.03010481223464012,
-0.007824825122952461,
0.030851367861032486,
-0.04393473640084267,
-0.008062789216637611,
0.0028649030718952417,
-0.04785414785146713,
0.0037421048618853092,
-0.009658549912273884,
-0.027361225336790085,
-0.023833755403757095,
0.034957416355609894,
0.03458413854241371,
-0.04729423299431801,
0.001988867996260524,
0.04023928940296173,
0.003359495662152767,
-0.00015018577687442303,
0.026782644912600517,
-0.03359495475888252,
-0.10220331698656082,
0.02271392196416855,
-0.020380940288305283,
-0.03633854538202286,
-0.0036137907300144434,
0.015472343191504478,
0.03296038508415222,
-0.01908380165696144,
0.008916661143302917,
-0.04621172696352005,
-0.01063840277493,
-0.024225695058703423,
0.008888665586709976,
-0.04583844915032387,
0.06468895077705383,
-0.02137012407183647,
0.012486125342547894,
-0.05046708881855011,
-0.05707409605383873,
0.011021011509001255,
-0.03148593753576279,
0.016844136640429497,
0.04628638178110123,
0.058455221354961395,
0.009975835680961609,
0.004381342325359583,
0.013074036687612534,
0.02013831026852131,
-0.03979135677218437,
0.0004231447819620371,
-0.02820109948515892,
-0.07689511775970459,
0.014221864752471447,
0.02611074596643448,
0.009210617281496525,
0.03613324090838432,
0.02045559510588646,
-0.03187787905335426,
0.012644767761230469,
0.03191520646214485,
-0.011207650415599346,
-0.0074048880487680435,
0.019933007657527924,
0.02168741077184677,
-0.00021346795256249607,
0.026875965297222137,
-0.0009652717271819711,
-0.033426981419324875,
0.03223249316215515,
-0.026372039690613747,
0.0003861087025143206,
-0.011926209554076195,
0.030851367861032486,
0.010311785154044628,
-0.0562155582010746,
-0.007983467541635036,
0.03743971139192581,
0.0055991592817008495,
0.025420183315873146,
-0.0024193034041672945,
0.0349387526512146,
0.05065372586250305,
-0.010582410730421543,
-0.0037910973187536,
0.07913478463888168,
-0.017674678936600685,
-0.06569679826498032,
0.05640219897031784,
-0.06405438482761383,
-0.0587538443505764,
0.04042593017220497,
-0.015304368920624256,
-0.00962122157216072,
-0.034472156316041946,
0.07364761084318161,
-0.01405388955026865,
-0.0009051974047906697,
-0.03852221742272377,
0.045875776559114456,
-0.06901896744966507,
-0.05106433108448982,
0.07779098302125931,
-0.041433777660131454,
0.03611457720398903,
0.00948124285787344,
-0.008454730734229088,
0.014063221402466297,
0.04602508991956711,
0.04785414785146713,
0.015537667088210583,
-0.008380074985325336,
0.03290439397096634,
0.1101914569735527,
-0.04878734052181244,
0.0498698465526104,
0.052445460110902786,
0.01346597820520401,
-0.01753470115363598,
-0.029488906264305115,
0.012364810332655907,
-0.016536183655261993,
0.03572263568639755,
-0.01063840277493,
0.015789629891514778,
0.006023762281984091,
0.008174772374331951,
0.002395973540842533,
0.0151643892750144,
-0.014231196604669094,
0.048675358295440674,
-0.03241913020610809,
-0.0124674616381526,
0.04176972806453705,
-0.03559198975563049,
-0.011916877701878548,
0.040127307176589966,
0.013633952476084232,
-0.019634384661912918,
0.0009355262154713273,
-0.012682096101343632,
-0.031523264944553375,
-0.0027202581986784935,
0.04240429773926735,
0.009173288941383362,
-0.09540967643260956,
0.03755169361829758,
0.013148692436516285,
0.01715209148824215,
0.023889746516942978,
-0.011310301721096039,
-0.02013831026852131,
0.0026502686087042093,
-0.012952721677720547,
0.0025826122146099806,
0.015509671531617641,
-0.025177553296089172,
-0.09824658185243607,
-0.0406498946249485,
0.11168456077575684,
-0.028387736529111862,
-0.02765984646975994,
0.00942991767078638,
0.005118564702570438,
-0.02950756996870041,
-0.0460624173283577,
-0.01416587270796299,
-0.04218033328652382,
-0.00012940765009261668,
-0.024319015443325043,
0.009873184375464916,
-0.03997799754142761,
0.031523264944553375
]
|
32,795 | bqplot.traits | __init__ | null | def __init__(self, default_value=dt.datetime.today(), **kwargs):
super(Date, self).__init__(default_value=default_value, **kwargs)
self.tag(**date_serialization)
| (self, default_value=datetime.datetime(2024, 5, 12, 8, 41, 20, 704540), **kwargs) | [
0.04061194509267807,
0.001501148333773017,
0.03158131241798401,
-0.0036908176261931658,
-0.03553545102477074,
-0.022464344277977943,
-0.04782954230904579,
0.009073799476027489,
0.029733745381236076,
-0.008970198221504688,
0.02683289162814617,
0.09786926209926605,
-0.01602376066148281,
-0.002609472954645753,
0.007498187478631735,
0.006725490093231201,
0.0012194806477054954,
0.04302932322025299,
-0.029112134128808975,
-0.007649273611605167,
0.002587889088317752,
-0.042304109781980515,
-0.048105813562870026,
0.07687260955572128,
0.06392237544059753,
0.06395690888166428,
-0.0388161800801754,
-0.0002970460627693683,
0.00418508518487215,
-0.01208688784390688,
-0.0032677766866981983,
-0.0008838537032715976,
-0.014711469411849976,
0.05221535637974739,
0.04803674668073654,
-0.05159374698996544,
-0.0680319145321846,
0.039334189146757126,
-0.11845150589942932,
0.06627067923545837,
0.07873744517564774,
-0.017249716445803642,
-0.048520222306251526,
-0.023517630994319916,
-0.019753428176045418,
0.010247954167425632,
0.008586007170379162,
0.029146667569875717,
-0.009289637207984924,
-0.01980523020029068,
0.03543185070157051,
0.010247954167425632,
0.02636668272316456,
-0.02823151834309101,
-0.11713921278715134,
0.06537279486656189,
0.03417136147618294,
0.12839728593826294,
-0.008150015957653522,
0.08992645144462585,
-0.028283318504691124,
0.04876196011900902,
0.0250371266156435,
-0.0375729538500309,
-0.051524676382541656,
0.014063958078622818,
0.0030519391875714064,
-0.024104708805680275,
0.02303415536880493,
0.06837725639343262,
0.05055772513151169,
0.01649860292673111,
0.02460545115172863,
0.07079463452100754,
0.017698658630251884,
-0.006229064427316189,
-0.08937390893697739,
0.05988189950585365,
-0.034085024148225784,
-0.03301447257399559,
-0.001328478567302227,
-0.03418862819671631,
-0.05995096638798714,
-0.006164312828332186,
-0.02562420256435871,
-0.0005328482948243618,
-0.013036572374403477,
0.018648341298103333,
0.022274408489465714,
0.028248785063624382,
-0.015324447304010391,
0.019459890201687813,
-0.019321754574775696,
0.04220050573348999,
0.005249163135886192,
-0.017836794257164,
0.0340159572660923,
0.022550679743289948,
0.001434238743968308,
0.021255657076835632,
0.006276548374444246,
-0.0730738714337349,
-0.08225990831851959,
-0.08405567705631256,
-0.039506856352090836,
-0.008331319317221642,
-0.012363160029053688,
-0.007265083026140928,
0.006216113921254873,
-0.03874710947275162,
-0.03515557944774628,
-0.014685569331049919,
-0.00106407783459872,
-0.0011763132642954588,
-0.038885246962308884,
-0.0017655490664765239,
-0.005706737749278545,
0.0189936812967062,
0.01339054573327303,
-0.0011353041045367718,
-0.008301102556288242,
-0.010765964165329933,
-0.02721276506781578,
0.05915668606758118,
-0.011732915416359901,
-0.012855269014835358,
0.006496702320873737,
-0.0020590878557413816,
0.032496463507413864,
-0.018941881135106087,
0.04285665228962898,
0.033687885850667953,
0.035069242119789124,
-0.03474117070436478,
0.009643610566854477,
-0.06409504264593124,
0.006259281653910875,
0.06036537513136864,
-0.09690231084823608,
0.08046413958072662,
0.04226957634091377,
-0.004340487997978926,
0.056946512311697006,
-0.00834426935762167,
-0.005888041108846664,
0.028904929757118225,
0.007813310250639915,
0.057947997003793716,
-0.05162828043103218,
0.027299100533127785,
0.04921090230345726,
0.01509134378284216,
0.0013781210873275995,
0.02762717381119728,
0.03726214915513992,
-0.10028664022684097,
0.004226094111800194,
-0.037124015390872955,
-0.010515592992305756,
-0.017733192071318626,
0.03574265539646149,
-0.0019964948296546936,
0.01200055330991745,
-0.02641848474740982,
-0.0010317022679373622,
0.05535794794559479,
-0.02638395130634308,
-0.03399869054555893,
0.03943778946995735,
0.02441551350057125,
0.0030130886007100344,
-0.04406534135341644,
-0.018700143322348595,
0.0367441400885582,
0.005978692788630724,
0.016887109726667404,
0.01190558448433876,
0.02519252896308899,
0.0004629709874279797,
0.03919605165719986,
0.016369100660085678,
0.028680458664894104,
-0.027834376320242882,
0.024570917710661888,
-0.00831405259668827,
0.009557275101542473,
-0.016032394021749496,
-0.03142590820789337,
0.023293159902095795,
0.030044550076127052,
0.07279760390520096,
0.050488658249378204,
-0.02260248176753521,
-0.032669130712747574,
0.014141659252345562,
0.019131816923618317,
0.014711469411849976,
-0.06330075860023499,
-0.00040091777918860316,
0.07749421894550323,
0.02819698303937912,
0.02358669973909855,
0.0011676797876134515,
-0.07894464582204819,
0.010144352912902832,
0.01360638253390789,
-0.005387298762798309,
0.011715647764503956,
-0.06561453640460968,
-0.047864075750112534,
0.025278862565755844,
-0.044099874794483185,
-0.02583140693604946,
0.03377421945333481,
-0.012484028935432434,
-0.06882619857788086,
-0.0016425218200311065,
-0.03726214915513992,
-0.05086853355169296,
-0.023673033341765404,
0.09199848771095276,
0.018527472391724586,
-0.02141105942428112,
-0.04534309729933739,
0.049072764813899994,
-0.007208965718746185,
0.055875957012176514,
-0.09407052397727966,
-0.01819940097630024,
-0.024104708805680275,
-0.015264012850821018,
-0.06616707891225815,
-0.014374763704836369,
-0.022757884114980698,
-0.006013226695358753,
0.023966573178768158,
0.041302625089883804,
-0.04102635383605957,
-0.0859895795583725,
-0.03760749101638794,
0.040128469467163086,
-0.0033627450466156006,
0.017241083085536957,
0.0020223953761160374,
0.036122530698776245,
-0.02938840538263321,
-0.02422557771205902,
0.08170736581087112,
-0.08909763395786285,
-0.0511448048055172,
0.04641365259885788,
-0.003358428133651614,
-0.022671548649668694,
0.014452464878559113,
0.019149083644151688,
-0.00454985024407506,
0.0909624695777893,
0.008249301463365555,
0.05656663700938225,
-0.02039230801165104,
-0.014340229332447052,
-0.05097213387489319,
-0.04344372823834419,
0.029129400849342346,
-0.017051145434379578,
-0.016809407621622086,
-0.002103334292769432,
-0.011327140964567661,
-0.03822910040616989,
0.005888041108846664,
0.0688607320189476,
-0.04896916449069977,
0.004614601377397776,
-0.00509375985711813,
-0.03902338072657585,
-0.0396449938416481,
-0.02040957473218441,
-0.08232897520065308,
-0.06216114014387131,
0.004161342978477478,
0.0060520777478814125,
-0.0051023936830461025,
0.05442553013563156,
0.02859412506222725,
-0.018734676763415337,
-0.03234105929732323,
-0.006872259546071291,
0.025641469284892082,
-0.02802431397140026,
-0.03213385492563248,
0.0021357100922614336,
0.019960632547736168,
0.028490522876381874,
0.015479850582778454,
-0.023137757554650307,
-0.020081501454114914,
0.0349656417965889,
0.03244466334581375,
0.009021998383104801,
-0.06309355795383453,
0.010049384087324142,
-0.020547710359096527,
0.05193908512592316,
-0.00040577410254627466,
-0.051282938569784164,
-0.0019781487062573433,
0.03059709444642067,
0.011223538778722286,
-0.016075560823082924,
-0.018510205671191216,
0.019114550203084946,
0.04876196011900902,
-0.04755327105522156,
-0.020944850519299507,
-0.07410988956689835,
-0.012993404641747475,
-0.0002797790803015232,
-0.04140622541308403,
0.03144317492842674,
0.05079946294426918,
-0.0032872019801288843,
-0.010973167605698109,
-0.03816003352403641,
-0.01119763869792223,
0.04420347884297371,
0.008253618143498898,
-0.011568878777325153,
-0.005995959974825382,
-0.018751943483948708,
0.07714888453483582,
0.026124944910407066,
0.02422557771205902,
0.05224988982081413,
0.04520496353507042,
-0.014953207224607468,
-0.011853784322738647,
-0.03639880195260048,
-0.0218081995844841,
-0.03857444226741791,
-0.022274408489465714,
-0.028093380853533745,
-0.006103878375142813,
-0.05397658795118332,
-0.01440929714590311,
0.012665332295000553,
-0.009643610566854477,
0.013727251440286636,
-0.000009780127584235743,
0.06661602109670639,
-0.0028512105345726013,
-0.04596471041440964,
0.04541216418147087,
0.011171738617122173,
0.005797389429062605,
0.04185516759753227,
-0.07894464582204819,
0.03242739289999008,
0.01921815238893032,
-0.003846220439299941,
-0.0021303140092641115,
-0.010058017447590828,
0.0022317576222121716,
0.014124392531812191,
-0.02420831099152565,
0.08522982895374298,
0.004593017511069775,
0.027558105066418648,
0.012190490029752254,
0.019943365827202797,
-0.042304109781980515,
-0.004392289090901613,
-0.022533413022756577,
-0.028266051784157753,
-0.028041580691933632,
0.04796767979860306,
-0.06278274953365326,
-0.008132749237120152,
0.027886178344488144,
-0.02037503942847252,
-0.022049937397241592,
-0.012155956588685513,
-0.006276548374444246,
0.046689923852682114,
0.026073144748806953,
0.015117243863642216,
-0.002467020181939006,
0.07162344455718994,
0.028283318504691124,
0.03139137476682663,
-0.006531236227601767,
0.0035828989930450916,
-0.03165037930011749,
-0.03588079288601875,
0.03646786883473396,
-0.02481265552341938,
-0.06254101544618607,
0.03588079288601875,
-0.015358981676399708,
-0.0233794953674078,
-0.007303934078663588,
0.014486999250948429,
-0.003880754578858614,
-0.011301240883767605,
-0.01188831776380539,
0.027834376320242882,
-0.0012184014776721597,
0.006949960719794035,
-0.041682496666908264,
-0.028041580691933632,
0.004782954230904579,
0.01668853871524334,
-0.08150015771389008,
-0.03465483710169792,
-0.01800946332514286,
0.029751012101769447,
0.0073427846655249596,
0.03080429881811142,
-0.014944573864340782,
0.00535276485607028,
-0.05639396607875824,
-0.007813310250639915,
0.07410988956689835,
-0.031512245535850525,
0.03826363384723663,
0.002077433979138732,
0.019149083644151688,
0.018872812390327454,
-0.003617432899773121,
0.019632559269666672,
0.014478365890681744,
0.05746452137827873,
0.014357496984302998,
-0.07438616454601288,
0.014495632611215115,
0.06944780796766281,
-0.021065719425678253,
-0.02042684145271778,
-0.07866837829351425,
-0.029043065384030342,
0.027074629440903664,
-0.04123355448246002,
-0.015540285035967827,
0.08937390893697739,
-0.0024929207284003496,
-0.024760853499174118,
0.0019619609229266644,
-0.009306903928518295,
0.09006458520889282,
-0.01627413183450699,
-0.03605346009135246,
0.038712576031684875,
0.02001243270933628,
0.018527472391724586,
-0.02778257615864277,
-0.02263701520860195,
-0.05825880169868469,
-0.008184550330042839,
-0.02602134458720684,
0.04458335041999817,
-0.01128397323191166,
0.020513176918029785,
-0.009367338381707668,
-0.03040715679526329,
-0.04202783852815628,
-0.023465830832719803,
0.026504818350076675,
-0.05366578325629234,
-0.04416894167661667,
-0.0584314726293087,
-0.01751735433936119,
0.03816003352403641,
0.02740270271897316,
0.0038095281925052404,
-0.02819698303937912,
-0.060503508895635605,
-0.001465535257011652,
-0.009600442834198475,
-0.04313292354345322,
-0.03639880195260048,
-0.037296682596206665,
0.005197362042963505,
0.007619056385010481,
0.013882654719054699,
0.019874297082424164,
-0.01693027652800083,
0.0061513627879321575,
0.0250371266156435,
-0.0036886592861264944,
0.01360638253390789,
0.06751390546560287,
-0.03601892665028572,
0.05173188075423241,
-0.03299720585346222,
0.002944020554423332,
0.024570917710661888,
0.0032828852999955416,
-0.005883724428713322,
0.014055324718356133,
0.010826398618519306,
-0.0024195360019803047,
-0.052698832005262375,
-0.012950237840414047,
0.013157441280782223,
0.017836794257164,
0.017871327698230743,
-0.009911248460412025,
-0.02401837334036827,
0.028887663036584854,
0.00941050611436367,
-0.051282938569784164,
0.01662810519337654,
-0.03323894366621971,
0.020858515053987503,
0.0261940136551857,
0.013062472455203533,
-0.024156508967280388,
-0.022447077557444572,
0.01562662050127983,
-0.019442623481154442,
-0.03581172227859497,
0.02983734756708145,
0.0692751333117485,
0.031149636954069138,
-0.060296304523944855,
-0.016015127301216125,
-0.001073790481314063,
-0.021514661610126495,
-0.022153539583086967,
0.018855545669794083,
0.05366578325629234,
0.02420831099152565,
-0.07590565830469131,
-0.04302932322025299,
0.027972511947155,
-0.009160134941339493,
0.06616707891225815,
-0.048520222306251526,
0.014167559333145618,
-0.00021759096125606447,
-0.04202783852815628,
-0.00880616158246994,
0.01289843674749136,
0.04164796322584152,
0.002307300688698888,
0.006807507947087288,
0.007498187478631735,
-0.003392962273210287,
0.09165314584970474,
0.01982249692082405,
0.010489691980183125,
-0.05124840512871742,
-0.05981282889842987,
-0.012259557843208313,
0.041889701038599014,
0.0049383570440113544,
-0.020150570198893547,
-0.0009378130198456347,
-0.004852022510021925,
0.027851643040776253,
-0.010662361979484558,
0.025658737868070602,
0.07901371270418167,
0.03420589491724968,
0.03260006383061409,
-0.02558966912329197,
0.032703667879104614,
0.02097938396036625,
-0.021100252866744995,
-0.04220050573348999,
0.016852576285600662,
-0.01646406762301922,
-0.05204268917441368,
-0.005482267122715712,
0.020530443638563156,
0.038919780403375626,
0.0768035426735878,
-0.057499054819345474,
0.011327140964567661,
-0.05193908512592316,
0.0035224645398557186,
0.01389992143958807,
-0.006004593335092068,
0.01459060050547123,
-0.11527437716722488,
0.004141917452216148,
0.0323583260178566,
-0.03816003352403641,
0.0440308079123497,
0.01883827894926071,
-0.01329557690769434,
-0.005452049896121025,
-0.017940396443009377,
-0.0484166219830513,
0.020703112706542015,
-0.025071660056710243,
-0.027368169277906418,
0.049901582300662994,
-0.08198363333940506,
-0.014081224799156189,
-0.054321929812431335,
0.012009186670184135,
0.03213385492563248,
-0.03420589491724968,
0.06996581703424454,
-0.04275305196642876,
-0.02042684145271778,
0.0073600513860583305,
0.07777049392461777,
-0.009721311740577221,
-0.0016371258534491062,
0.016809407621622086,
0.03234105929732323,
0.021929068490862846,
0.05559968575835228,
0.020513176918029785,
-0.010291121900081635,
-0.05283696949481964,
0.04434161260724068,
-0.010049384087324142,
-0.045308563858270645,
-0.047864075750112534,
0.011499810963869095,
-0.021082986146211624,
0.03225472569465637,
-0.05104120075702667,
-0.006833408493548632,
0.004133284091949463,
-0.013779052533209324,
0.007118314038962126,
-0.03001001663506031,
0.07894464582204819,
-0.004912456963211298,
0.016187796369194984,
-0.01309700682759285,
-0.029854614287614822,
0.016602205112576485,
0.011836516670882702,
0.0008385278633795679,
0.031149636954069138,
0.021652797237038612,
0.014469731599092484,
-0.012829368934035301,
0.03767655789852142,
0.008132749237120152,
-0.028525056317448616,
-0.008426288142800331,
-0.02660842053592205,
-0.05822426825761795,
-0.008327002637088299,
0.02061677724123001,
0.022084470838308334,
-0.05245709419250488,
0.0026785407681018114,
0.0037210348527878523,
-0.02322409301996231,
0.010645095258951187,
0.0006458931020461023,
-0.001360854133963585,
0.04220050573348999,
-0.013882654719054699,
-0.035708121955394745,
0.003997306805104017,
-0.01541941612958908,
0.012863902375102043,
-0.010731429792940617,
-0.03753842040896416,
-0.02061677724123001,
-0.031149636954069138,
-0.000841225846670568,
0.05860413983464241,
-0.02683289162814617,
0.008901129476726055,
0.04724246636033058,
-0.01010118518024683,
-0.0019554859027266502,
-0.03133957460522652,
0.04627551510930061,
0.046897128224372864,
0.05079946294426918,
0.005175778176635504,
0.07031115889549255,
0.005236212629824877,
-0.01842387020587921,
0.040093936026096344,
-0.035103775560855865,
0.014340229332447052,
-0.025313397869467735,
-0.00823203381150961,
0.03957592695951462,
-0.013761785812675953,
0.030251754447817802,
-0.060089100152254105,
-0.03836723789572716,
-0.03356701508164406,
0.02603861130774021,
-0.04306385666131973,
-0.06143592670559883,
-0.007593155838549137,
-0.038332704454660416,
-0.01767275668680668,
0.045930176973342896,
0.036502402275800705,
0.017560521140694618,
0.06475118547677994,
0.013235142454504967,
-0.02823151834309101,
-0.028904929757118225,
0.025123460218310356,
0.07652726769447327,
0.0005681916954927146,
0.054321929812431335,
0.02441551350057125,
-0.019736161455512047,
-0.03234105929732323,
-0.002103334292769432,
0.03156404569745064,
-0.0002003239787882194,
0.032289259135723114,
-0.039265118539333344,
0.025952275842428207,
0.008577373810112476,
-0.03399869054555893,
0.00790827814489603,
-0.0005085666198283434,
0.03860897570848465,
0.02223987504839897,
0.006747073493897915,
-0.00843923818320036,
0.022498879581689835,
-0.0007764746551401913,
0.020098768174648285,
0.059502024203538895,
0.024847188964486122,
-0.05287150293588638,
0.025278862565755844,
-0.023845704272389412,
-0.016187796369194984,
0.0233794953674078,
0.04081914946436882,
0.020133301615715027,
-0.05756812170147896,
0.021497394889593124,
0.0021724023390561342,
0.02842145413160324,
0.023500364273786545,
-0.029854614287614822,
-0.009522741660475731,
-0.02976827882230282,
-0.033687885850667953,
0.05307870730757713,
-0.013735884800553322,
0.0052405293099582195,
-0.06046897545456886,
-0.004409555811434984,
0.04475602135062218,
-0.032513730227947235,
-0.0038656459655612707,
0.0036433334462344646,
0.040681011974811554,
-0.005024692043662071,
-0.016524503007531166,
-0.05825880169868469,
-0.005525434855371714,
-0.018544739112257957,
0.04765687510371208,
0.04655178636312485,
0.009177401661872864,
0.02279241755604744
]
|
32,815 | bqplot.traits | validate | null | def validate(self, obj, value):
try:
if isinstance(value, dt.datetime):
return value
if isinstance(value, dt.date):
return dt.datetime(value.year, value.month, value.day)
if np.issubdtype(np.dtype(value), np.datetime64):
# TODO: Fix this. Right now, we have to limit the precision
# of time to microseconds because np.datetime64.astype(datetime)
# returns date values only for precision <= 'us'
value_truncated = np.datetime64(value, 'us')
return value_truncated.astype(dt.datetime)
except Exception:
self.error(obj, value)
self.error(obj, value)
| (self, obj, value) | [
0.07315468788146973,
0.04191385582089424,
-0.004731985740363598,
0.02970287948846817,
-0.01722322218120098,
-0.05551455169916153,
-0.002312720287591219,
0.006499242037534714,
0.036095574498176575,
-0.020215746015310287,
0.02138310857117176,
0.055292196571826935,
0.01598174311220646,
-0.06492756307125092,
0.032612018287181854,
0.044322699308395386,
-0.04309974983334541,
0.08175240457057953,
0.038319122046232224,
0.04502682387828827,
0.010348757728934288,
-0.029628761112689972,
-0.045175060629844666,
0.02366224303841591,
0.009746546857059002,
0.0479544922709465,
0.023495478555560112,
0.001702403067611158,
-0.023921657353639603,
-0.004051024094223976,
0.010422875173389912,
0.05366159602999687,
0.04991862550377846,
0.016787778586149216,
0.02229105681180954,
-0.06244460493326187,
-0.04250680282711983,
-0.00730527751147747,
-0.08345711976289749,
0.026571383699774742,
-0.05199393630027771,
-0.0022490250412374735,
-0.055255137383937836,
0.0025014900602400303,
-0.02314341627061367,
-0.037781767547130585,
-0.014156580902636051,
0.07534117996692657,
-0.08115945756435394,
0.011960828676819801,
-0.0284613985568285,
0.012794658541679382,
0.036077044904232025,
0.0011488324962556362,
-0.06607639789581299,
0.028665224090218544,
-0.01928926818072796,
0.09835488349199295,
-0.011293765157461166,
0.003930582199245691,
-0.030907301232218742,
0.02053074911236763,
0.02016015723347664,
-0.011154793202877045,
0.013609959743916988,
-0.016204096376895905,
0.006786450278013945,
-0.033482909202575684,
-0.021142223849892616,
0.04313680902123451,
-0.044322699308395386,
-0.010015225037932396,
0.015611151233315468,
0.034798506647348404,
0.013118926435709,
-0.004252533428370953,
-0.022105760872364044,
0.030369943007826805,
0.02666403166949749,
-0.043507397174835205,
0.023365771397948265,
0.03724440932273865,
-0.0037244409322738647,
0.0018992795376107097,
-0.005873869638890028,
0.001055605709552765,
-0.04506388306617737,
0.06222224980592728,
-0.004118193872272968,
0.0371517613530159,
0.01205347664654255,
-0.04624977335333824,
-0.012118330225348473,
0.024292249232530594,
-0.06292637437582016,
0.054921604692935944,
-0.008926614187657833,
0.003177819075062871,
-0.03463174030184746,
0.006879097782075405,
0.05203099548816681,
-0.02973993867635727,
-0.04443387687206268,
0.023476948961615562,
0.012201713398098946,
0.005586661398410797,
0.057923395186662674,
-0.03533586487174034,
0.010200520977377892,
0.006230563391000032,
-0.021976053714752197,
0.031611423939466476,
-0.04591624066233635,
-0.011877445504069328,
0.0004047550028190017,
-0.02445901557803154,
-0.028998756781220436,
-0.0119978878647089,
-0.045138001441955566,
-0.005327247548848391,
-0.02968434989452362,
0.022124290466308594,
0.020641926676034927,
0.0050261421129107475,
0.0393197201192379,
0.002821125090122223,
0.01224803738296032,
-0.007328439503908157,
0.024570191279053688,
0.011627296917140484,
-0.032574959099292755,
0.0013781357556581497,
-0.010543317534029484,
-0.012331419624388218,
-0.008384624496102333,
0.00015315836935769767,
0.007110717240720987,
-0.000556176237296313,
-0.02099398709833622,
-0.016204096376895905,
0.011238176375627518,
0.015991007909178734,
0.037188820540905,
-0.06948583573102951,
0.06948583573102951,
-0.0073423366993665695,
-0.013730401173233986,
0.07230232656002045,
-0.03850441798567772,
0.07022701948881149,
-0.03405732661485672,
0.025237256661057472,
0.03465026989579201,
0.030759064480662346,
-0.027275508269667625,
-0.08590302616357803,
0.0261637344956398,
-0.10376551747322083,
0.03229701891541481,
0.016741454601287842,
-0.04206209257245064,
0.024181071668863297,
-0.012970689684152603,
-0.05162334442138672,
0.04313680902123451,
0.08182652294635773,
0.015157177112996578,
-0.006712331902235746,
0.010839791037142277,
0.01701013371348381,
-0.000831513840239495,
0.00482231704518199,
0.04888097196817398,
0.03444644436240196,
-0.011960828676819801,
0.007018069736659527,
0.002240918343886733,
0.029999352991580963,
0.01923367939889431,
0.055662788450717926,
-0.0001380307221552357,
0.07144997268915176,
-0.03320496529340744,
0.07056055217981339,
-0.011877445504069328,
0.044767409563064575,
-0.04069090634584427,
-0.00980213563889265,
-0.01704719290137291,
0.045249179005622864,
0.023847538977861404,
0.08605126291513443,
0.022013112902641296,
-0.007166306022554636,
-0.019400445744395256,
-0.022958120331168175,
0.0002154060930479318,
0.009139703586697578,
0.008500434458255768,
0.05125275254249573,
-0.003124546492472291,
-0.015222030691802502,
0.010598906315863132,
-0.06159224733710289,
-0.023717831820249557,
-0.036132633686065674,
-0.0217907577753067,
0.0262749120593071,
-0.046101536601781845,
-0.01375819556415081,
-0.020401041954755783,
-0.028665224090218544,
-0.06652110815048218,
0.017501166090369225,
0.014434524811804295,
-0.06618757545948029,
0.01224803738296032,
-0.07056055217981339,
-0.017482636496424675,
0.022550471127033234,
0.015138647519052029,
0.015323943458497524,
-0.00699490774422884,
-0.05855339765548706,
0.09338896721601486,
-0.003763816086575389,
-0.009635369293391705,
-0.031129654496908188,
0.028757872059941292,
-0.07396999001502991,
-0.004877905827015638,
-0.028554046526551247,
-0.04461917281150818,
-0.011886710301041603,
0.024811076000332832,
0.06266696006059647,
0.08575478941202164,
-0.040802083909511566,
0.004516579210758209,
-0.00048784847604110837,
0.021661052480340004,
-0.03287143260240555,
0.006851303391158581,
0.026738150045275688,
0.015777917578816414,
0.017158368602395058,
-0.019974861294031143,
0.04102443903684616,
-0.037299998104572296,
-0.011766268871724606,
-0.018622204661369324,
0.026571383699774742,
0.02540402300655842,
0.0063139465637505054,
0.01268348190933466,
-0.016018802300095558,
0.03572498634457588,
-0.07085702568292618,
0.06270401924848557,
-0.010858320631086826,
-0.015268354676663876,
0.038319122046232224,
0.013498782180249691,
0.05210511386394501,
-0.08553243428468704,
-0.036892347037792206,
-0.011340088210999966,
0.05636691302061081,
0.043470341712236404,
0.0437668114900589,
-0.044804468750953674,
0.008236387744545937,
-0.0393197201192379,
-0.021623993292450905,
-0.0240328349173069,
0.011627296917140484,
0.0007018069736659527,
-0.022105760872364044,
-0.0038842582143843174,
0.026812268421053886,
-0.02790551260113716,
-0.03713323175907135,
0.017482636496424675,
-0.01353584136813879,
-0.0654834508895874,
-0.06244460493326187,
0.017102781683206558,
0.006892994977533817,
-0.04639801010489464,
0.004669448360800743,
-0.055292196571826935,
-0.017167633399367332,
0.008486537262797356,
-0.021698111668229103,
-0.05907222628593445,
0.020771633833646774,
-0.008064989931881428,
-0.07619353383779526,
-0.002557078842073679,
0.0012078954605385661,
-0.023384300991892815,
0.07989944517612457,
-0.04291445389389992,
0.04417446255683899,
0.039356779307127,
0.01665807142853737,
-0.00029184052255004644,
-0.03794853016734123,
-0.04617565497756004,
0.015879830345511436,
0.010052284225821495,
-0.019548682495951653,
-0.012859512120485306,
-0.025144608691334724,
0.04065384715795517,
0.02447754517197609,
-0.014675408601760864,
-0.012285095639526844,
-0.00910264439880848,
0.05540337413549423,
-0.0028790298383682966,
0.0032241428270936012,
0.01221097819507122,
-0.009570515714585781,
-0.007578588556498289,
-0.05818280950188637,
0.0196413304656744,
0.021568404510617256,
-0.04232150688767433,
0.05292041227221489,
-0.009264778345823288,
-0.022068701684474945,
0.04195091500878334,
0.051326870918273926,
0.10784202069044113,
0.004092715680599213,
0.014156580902636051,
-0.02751639112830162,
0.021234871819615364,
0.0611104778945446,
-0.009144335985183716,
0.05280923470854759,
0.022105760872364044,
-0.0164635106921196,
0.02136457897722721,
-0.02268017642199993,
-0.012590833939611912,
0.006679905112832785,
0.03064788691699505,
0.0240328349173069,
-0.058405160903930664,
0.07059761136770248,
-0.02538549341261387,
0.018603675067424774,
-0.013962021097540855,
-0.012146124616265297,
0.0008714682189747691,
0.002929986221715808,
-0.01857588067650795,
-0.004444777499884367,
0.0058553400449454784,
-0.0003549568064045161,
0.05106745660305023,
-0.062333427369594574,
0.02490372397005558,
0.045656826347112656,
-0.03618822246789932,
-0.06896700710058212,
0.02136457897722721,
-0.019029853865504265,
-0.035965871065855026,
0.0523645281791687,
0.0046972427517175674,
-0.0833088830113411,
0.06322284787893295,
0.028720812872052193,
0.0009038949501700699,
0.026497265323996544,
-0.033797912299633026,
0.04906626418232918,
0.046583306044340134,
-0.022958120331168175,
0.002978626172989607,
-0.012025682255625725,
0.029424935579299927,
0.0011111943749710917,
0.007717560511082411,
0.020753104239702225,
-0.04020913690328598,
-0.055662788450717926,
-0.012340684421360493,
-0.020401041954755783,
0.022050172090530396,
0.012183183804154396,
0.0046578673645854,
0.00064332305919379,
0.00983919482678175,
0.018353525549173355,
0.0013167565921321511,
-0.02755345031619072,
-0.02091986872255802,
0.04980744794011116,
-0.007384028285741806,
0.060554590076208115,
0.007059760857373476,
0.026997564360499382,
0.01089537888765335,
0.02366224303841591,
-0.04035737365484238,
0.0328158438205719,
0.028257573023438454,
-0.05169746279716492,
0.06203695386648178,
-0.012118330225348473,
0.033834971487522125,
0.04980744794011116,
-0.03961619362235069,
-0.019363386556506157,
0.012553774751722813,
-0.03802264854311943,
0.026867857202887535,
-0.013962021097540855,
-0.05721927061676979,
0.025978438556194305,
0.007939915172755718,
-0.015129382722079754,
0.049214500933885574,
-0.0020996304228901863,
0.007393293082714081,
-0.0008749425178393722,
0.04487858712673187,
-0.005920193158090115,
-0.104580819606781,
-0.03752235323190689,
0.04035737365484238,
-0.029424935579299927,
-0.04939979687333107,
0.00610548909753561,
0.009885518811643124,
0.050400394946336746,
-0.04317386820912361,
0.030684946104884148,
0.06255578249692917,
0.04028325527906418,
0.0033399525564163923,
0.010747143067419529,
0.023421360179781914,
0.020456630736589432,
-0.04276621714234352,
-0.008398521691560745,
0.04754684120416641,
-0.024607250466942787,
0.03309378772974014,
-0.03620675206184387,
-0.004178415052592754,
-0.0327417254447937,
-0.05495866388082504,
-0.03742970526218414,
0.01353584136813879,
0.003546093823388219,
-0.010784202255308628,
-0.007161673624068499,
-0.025051960721611977,
-0.07493352890014648,
-0.04906626418232918,
0.07163526862859726,
-0.04050561040639877,
0.004331283736974001,
-0.0042965407483279705,
-0.0004507893754635006,
0.0065316688269376755,
-0.05447689816355705,
0.06707699596881866,
-0.00958904530853033,
-0.018019994720816612,
0.026923445984721184,
0.004685661755502224,
0.021735170856118202,
0.033797912299633026,
0.00003908578219125047,
0.028924638405442238,
0.03529880568385124,
0.015342473052442074,
0.006832773797214031,
-0.02316194586455822,
-0.0007290222565643489,
-0.026330500841140747,
0.013665547594428062,
-0.03576204553246498,
0.031240832060575485,
-0.005498645827174187,
0.014063933864235878,
-0.02051221951842308,
-0.004794522654265165,
0.011784798465669155,
-0.02016015723347664,
-0.0006606944953091443,
-0.010432139970362186,
0.0175104308873415,
0.008102048188447952,
-0.005359674338251352,
0.023884598165750504,
-0.06681758165359497,
0.016037331894040108,
0.01625042036175728,
-0.00492886221036315,
-0.023439889773726463,
-0.01722322218120098,
-0.0098577244207263,
-0.06622463464736938,
-0.055699847638607025,
0.04458211362361908,
0.009088747203350067,
0.06715111434459686,
0.03368673473596573,
-0.006716964300721884,
0.03320496529340744,
-0.010876849293708801,
-0.0438409298658371,
-0.03633645921945572,
-0.005494013428688049,
0.0011604134924709797,
0.021568404510617256,
-0.039097364991903305,
0.00100986089091748,
-0.0011274076532572508,
-0.05558867007493973,
-0.0240328349173069,
0.01925220899283886,
-0.021901935338974,
0.06255578249692917,
-0.05288335308432579,
0.04662036523222923,
0.029054345563054085,
0.02701609395444393,
-0.024292249232530594,
-0.017139839008450508,
-0.0370035246014595,
-0.019974861294031143,
-0.011960828676819801,
-0.027256978675723076,
-0.01928926818072796,
0.04332210496068001,
0.04495270550251007,
-0.0009363216813653708,
0.00893124658614397,
0.034761447459459305,
0.06077694520354271,
-0.0569598563015461,
0.008833966217935085,
-0.014323347248136997,
-0.036947935819625854,
0.1093243807554245,
0.10280197858810425,
-0.04662036523222923,
0.01395275630056858,
0.010543317534029484,
0.032612018287181854,
0.017501166090369225,
-0.059665173292160034,
-0.008769112639129162,
-0.025422552600502968,
0.05110451579093933,
0.03969031199812889,
-0.09902194887399673,
-0.01136788260191679,
-0.004391504917293787,
0.030444061383605003,
-0.013850843533873558,
0.033408790826797485,
-0.015722328796982765,
-0.009450074285268784,
-0.04687977954745293,
-0.025885790586471558,
0.03854147717356682,
0.08871951699256897,
-0.07141291350126266,
-0.002962412778288126,
-0.07237644493579865,
-0.013480252586305141,
-0.009653898887336254,
-0.027164330706000328,
0.04836214333772659,
-0.08153004944324493,
0.001441831118427217,
-0.05073392763733864,
-0.01704719290137291,
-0.018473967909812927,
-0.005762692075222731,
-0.06477932631969452,
0.037374116480350494,
0.03578057512640953,
-0.08619949966669083,
0.028516987338662148,
0.05340218171477318,
-0.019863685593008995,
-0.05418042466044426,
-0.019141031429171562,
0.0019919273909181356,
-0.003434916492551565,
0.008898819796741009,
0.027460802346467972,
-0.016148509457707405,
0.04547153040766716,
-0.01551850326359272,
-0.02058633789420128,
0.012387008406221867,
-0.031611423939466476,
0.061406951397657394,
-0.04632389172911644,
0.011238176375627518,
0.05625573545694351,
0.009218454360961914,
0.010422875173389912,
0.03529880568385124,
-0.04624977335333824,
-0.0874595046043396,
0.01658395305275917,
-0.042173270136117935,
-0.01809411123394966,
0.04943685606122017,
0.0018517975695431232,
0.031648483127355576,
-0.01857588067650795,
0.01395275630056858,
-0.053587477654218674,
0.01683410257101059,
-0.037355586886405945,
-0.009737282060086727,
-0.0919807180762291,
0.054810427129268646,
0.018872354179620743,
-0.010737878270447254,
-0.029999352991580963,
-0.087237149477005,
0.015796447172760963,
-0.036947935819625854,
-0.0006317420629784465,
0.0305552389472723,
0.044396817684173584,
0.00980213563889265,
-0.011479060165584087,
0.024811076000332832,
0.039505016058683395,
-0.016259685158729553,
-0.017640138044953346,
-0.03500233218073845,
-0.05892398953437805,
-0.006439020857214928,
0.05506984144449234,
0.029628761112689972,
0.018279407173395157,
-0.009941107593476772,
-0.025607846677303314,
0.03898618742823601,
0.015379532240331173,
0.016204096376895905,
-0.0284243393689394,
0.01159950252622366,
0.020345453172922134,
-0.03972737118601799,
-0.016945280134677887,
-0.018677793443202972,
-0.03240819275379181,
0.038615595549345016,
-0.008491169661283493,
-0.02707168273627758,
0.007624912541359663,
0.006337108556181192,
0.012711276300251484,
-0.06085106357932091,
-0.0063139465637505054,
0.02053074911236763,
0.0654834508895874,
0.028665224090218544,
-0.03335320204496384,
0.002132057212293148,
0.032074663788080215,
0.0017313554417341948,
-0.016713660210371017,
0.05651514604687691,
-0.006971745751798153,
-0.05721927061676979,
0.03368673473596573,
-0.02368077263236046,
-0.08968305587768555,
-0.007597118150442839,
-0.01067302469164133,
0.026904916390776634,
-0.036873817443847656,
0.02221693843603134,
0.003059693146497011,
-0.037374116480350494,
-0.03576204553246498,
-0.039505016058683395,
-0.06440874189138412,
-0.040060900151729584,
0.12362920492887497,
-0.0028257574886083603,
0.06589110195636749,
-0.001095560030080378,
0.002114685717970133,
0.02012309804558754,
0.05269806087017059,
0.06696581840515137,
-0.02714580111205578,
-0.02797963097691536,
0.010663759894669056,
0.04020913690328598,
-0.042580921202898026,
0.019029853865504265,
0.0698934867978096,
-0.008356830105185509,
-0.040802083909511566,
-0.01752896048128605,
-0.0035345128271728754,
-0.017074987292289734,
0.01923367939889431,
0.006040635518729687,
-0.011914504691958427,
0.00677718548104167,
0.029146991670131683,
-0.0197154488414526,
0.01722322218120098,
-0.001484680688008666,
0.054921604692935944,
-0.025978438556194305,
-0.02534843422472477,
0.028924638405442238,
-0.007272851187735796,
0.029943764209747314,
0.03663293272256851,
0.029072875156998634,
0.0028234412893652916,
0.012785393744707108,
0.04676860198378563,
-0.03177819028496742,
0.010098608210682869,
0.007370131090283394,
0.006443653255701065,
-0.025033431127667427,
0.012637157924473286,
0.023717831820249557,
-0.04313680902123451,
-0.020456630736589432,
-0.03802264854311943,
-0.006591889541596174,
0.019011324271559715,
0.0049149650149047375,
0.0039514279924333096,
0.03507645055651665,
-0.07033819705247879,
-0.048139788210392,
-0.005526440218091011,
0.10131961852312088,
0.006679905112832785,
-0.034705858677625656,
0.019474564120173454,
0.014795850962400436,
0.024366367608308792,
-0.011506854556500912,
0.006763288285583258,
-0.023495478555560112,
0.002082258928567171,
-0.028535516932606697,
0.00017603079322725534,
-0.051400989294052124,
0.022198408842086792
]
|
32,816 | bqplot.scales | DateColorScale | A date color scale.
A mapping from dates to a numerical domain.
Attributes
----------
min: Date or None (default: None)
if not None, min is the minimal value of the domain
max: Date or None (default: None)
if not None, max is the maximal value of the domain
mid: Date or None (default: None)
if not None, mid is the value corresponding to the mid color.
rtype: string (class-level attribute)
This attribute should not be modified by the user.
The range type of a color scale is 'Color'.
dtype: type (class-level attribute)
the associated data type / domain type
| class DateColorScale(ColorScale):
"""A date color scale.
A mapping from dates to a numerical domain.
Attributes
----------
min: Date or None (default: None)
if not None, min is the minimal value of the domain
max: Date or None (default: None)
if not None, max is the maximal value of the domain
mid: Date or None (default: None)
if not None, mid is the value corresponding to the mid color.
rtype: string (class-level attribute)
This attribute should not be modified by the user.
The range type of a color scale is 'Color'.
dtype: type (class-level attribute)
the associated data type / domain type
"""
dtype = np.datetime64
domain_class = Type(Date)
min = Date(default_value=None, allow_none=True).tag(sync=True)
mid = Date(default_value=None, allow_none=True).tag(sync=True)
max = Date(default_value=None, allow_none=True).tag(sync=True)
_view_name = Unicode('DateColorScale').tag(sync=True)
_model_name = Unicode('DateColorScaleModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.022922895848751068,
-0.05340981483459473,
-0.03259987384080887,
0.06377927213907242,
-0.006476472597569227,
-0.018696986138820648,
-0.06537730246782303,
-0.042507678270339966,
0.020561357960104942,
-0.018590450286865234,
0.011683396995067596,
0.026118962094187737,
0.07006486505270004,
0.024059275165200233,
0.035849206149578094,
0.0014226932544261217,
-0.038636885583400726,
0.039524681866168976,
0.034979164600372314,
-0.015785014256834984,
-0.00029075323254801333,
-0.03597349673509598,
0.0183241106569767,
0.01550091989338398,
0.01969131827354431,
0.06548383831977844,
0.019052105024456978,
0.018040016293525696,
-0.026562858372926712,
-0.042010512202978134,
-0.05472375079989433,
0.028427230194211006,
-0.007506316062062979,
0.03966673091053963,
0.03220924362540245,
-0.058878637850284576,
0.0005876100622117519,
0.003722085151821375,
-0.09055519849061966,
0.0432889387011528,
-0.012659972533583641,
-0.011292766779661179,
-0.011931979097425938,
-0.029634634032845497,
0.0450645312666893,
-0.005930477753281593,
0.0021895270328968763,
0.0161756444722414,
-0.03536979481577873,
-0.05603769049048424,
0.020046435296535492,
-0.03171207755804062,
-0.0065253013744950294,
0.014586489647626877,
-0.017214367166161537,
0.0710591971874237,
-0.010724577121436596,
0.13679161667823792,
-0.024751754477620125,
0.0460943728685379,
-0.01020077709108591,
0.000023911539756227285,
0.013822984881699085,
-0.026900222525000572,
-0.028622545301914215,
0.03096632845699787,
0.001701239263638854,
-0.007799288723617792,
0.011212864890694618,
0.012189440429210663,
-0.006578569300472736,
-0.0021296008490025997,
0.057174067944288254,
0.03481936454772949,
-0.007666119374334812,
-0.0030273846350610256,
-0.035653892904520035,
0.036719247698783875,
0.006627398077398539,
-0.043750591576099396,
0.04417673498392105,
0.015864916145801544,
0.005459946114569902,
-0.041832953691482544,
0.03700334206223488,
-0.06818273663520813,
-0.02098749950528145,
0.027610458433628082,
-0.03835279121994972,
0.02198183164000511,
-0.03728743642568588,
-0.009002252481877804,
-0.014861706644296646,
0.03242231532931328,
0.037074364721775055,
0.010609162971377373,
0.013316941447556019,
0.05490130931138992,
-0.014639757573604584,
0.0018466159235686064,
0.011106329038739204,
-0.058878637850284576,
-0.033008258789777756,
-0.008314210921525955,
-0.03245782479643822,
-0.02695349045097828,
-0.04598783701658249,
0.027361875399947166,
-0.06420541554689407,
0.011337156407535076,
-0.009650344029068947,
0.07833912968635559,
0.008846888318657875,
-0.009952194057404995,
-0.04087413102388382,
-0.0014326809905469418,
-0.01583828218281269,
0.026456324383616447,
0.0004300262371543795,
-0.007186709437519312,
-0.051350127905607224,
0.03080652467906475,
-0.005917160771787167,
0.07013589143753052,
-0.014364540576934814,
0.014364540576934814,
0.01522570289671421,
0.036719247698783875,
-0.05408453941345215,
0.012420267798006535,
-0.03639964014291763,
0.020685648545622826,
-0.0013638767413794994,
-0.008314210921525955,
0.07833912968635559,
-0.036168813705444336,
0.006960321217775345,
0.05738713964819908,
-0.0647025778889656,
0.11726010590791702,
0.02924400381743908,
0.039524681866168976,
0.023206990212202072,
-0.01866147480905056,
0.0028076551388949156,
0.005499897059053183,
0.03785562515258789,
0.034943655133247375,
-0.038814444094896317,
0.07500101625919342,
-0.025568528100848198,
0.030025264248251915,
0.042365629225969315,
0.008647133596241474,
0.034428734332323074,
-0.04769240692257881,
-0.01595369540154934,
-0.03261762857437134,
-0.004598783794790506,
0.02290513925254345,
-0.05372941866517067,
0.003449087729677558,
0.0025413164403289557,
-0.06910604983568192,
-0.0034468683879822493,
0.009543808177113533,
0.005522091872990131,
-0.0806829109787941,
-0.02132486179471016,
0.03306152671575546,
-0.022922895848751068,
-0.05692548677325249,
0.0216444693505764,
0.04549067094922066,
-0.00858942698687315,
0.030557941645383835,
0.014062690548598766,
0.010271800681948662,
-0.016441984102129936,
0.015785014256834984,
0.05756469815969467,
0.004152666311711073,
-0.042330119758844376,
0.021218325942754745,
-0.016441984102129936,
0.020827695727348328,
-0.05614422634243965,
-0.007608412764966488,
-0.012100661173462868,
-0.0008683755295351148,
0.06530628353357315,
0.020685648545622826,
0.0034557462204247713,
-0.03082428127527237,
0.004079422913491726,
-0.0089045949280262,
-0.04492248222231865,
-0.028427230194211006,
0.02555077150464058,
0.03906302899122238,
0.02521340921521187,
-0.00292528816498816,
0.01745407097041607,
-0.05284162238240242,
0.011044183745980263,
-0.006720616482198238,
0.022780848667025566,
-0.012677728198468685,
-0.04577476531267166,
-0.03657719865441322,
-0.020525846630334854,
-0.030593452975153923,
-0.02539096772670746,
0.038814444094896317,
0.027024513110518456,
-0.07706069946289062,
-0.0294038075953722,
-0.017134465277194977,
-0.0366482213139534,
0.013077236711978912,
0.05848800763487816,
-0.01162125077098608,
0.033327866345644,
-0.01753397285938263,
0.027716994285583496,
-0.03554735705256462,
0.033611960709095,
-0.03192514926195145,
0.021910807117819786,
-0.03874342143535614,
-0.018608206883072853,
-0.08544149994850159,
-0.008380794897675514,
0.0020386017858982086,
0.042010512202978134,
0.036896806210279465,
0.041158225387334824,
0.06981628388166428,
-0.0010043192887678742,
0.048615712672472,
-0.02590589039027691,
0.04098066687583923,
-0.0006558593595400453,
0.011869833804666996,
0.06005052849650383,
-0.057174067944288254,
0.03629310429096222,
0.03874342143535614,
-0.06896400451660156,
-0.029829949140548706,
-0.050817448645830154,
-0.07450384646654129,
0.012056270614266396,
0.03451751172542572,
0.009410638362169266,
-0.016681687906384468,
-0.0401994064450264,
-0.02679368667304516,
0.006187938619405031,
-0.051882803440093994,
-0.013352453708648682,
-0.016042474657297134,
0.008092261850833893,
0.06328210234642029,
0.019602537155151367,
-0.008132211863994598,
0.006001501809805632,
0.024201322346925735,
-0.006076964084059,
0.052202410995960236,
0.063672736287117,
0.030522430315613747,
-0.04598783701658249,
0.009961072355508804,
0.005060437601059675,
-0.022052854299545288,
-0.0034468683879822493,
-0.08331078290939331,
0.03668373450636864,
-0.006622958928346634,
-0.022230414673686028,
-0.060512181371450424,
-0.016495252028107643,
0.01293518953025341,
0.038459327071905136,
-0.06512872129678726,
-0.01557194348424673,
-0.025266677141189575,
-0.011115207336843014,
0.021182814612984657,
-0.03304377198219299,
-0.005841698497533798,
0.006511984393000603,
-0.009685855358839035,
-0.007080174051225185,
-0.006147988140583038,
0.055895641446113586,
0.005921599920839071,
-0.014320150949060917,
-0.029545854777097702,
0.042862795293331146,
-0.04424775764346123,
0.09204670041799545,
0.022816359996795654,
-0.05550501123070717,
-0.023491084575653076,
0.017409682273864746,
-0.021893052384257317,
0.016282180324196815,
0.03098408319056034,
-0.0054777017794549465,
0.06786313652992249,
-0.0628204494714737,
0.012109538540244102,
-0.05000067502260208,
-0.015181313268840313,
-0.0002272203128086403,
-0.024414392188191414,
0.034943655133247375,
0.07294132560491562,
-0.06388580799102783,
-0.03647066280245781,
-0.030398137867450714,
-0.0150747774168849,
0.06164856255054474,
0.04644949361681938,
-0.0041970559395849705,
0.020046435296535492,
0.026687150821089745,
0.061186905950307846,
-0.01453322172164917,
0.0017256536521017551,
0.03817523270845413,
0.0468401238322258,
0.0011069707106798887,
-0.08160621672868729,
0.016344325616955757,
-0.01621115766465664,
-0.005127022508531809,
-0.04296933114528656,
-0.023721911013126373,
-0.018084406852722168,
-0.06562589108943939,
-0.012917432934045792,
0.030522430315613747,
-0.03304377198219299,
0.021946320310235023,
-0.03710987791419029,
0.013370209373533726,
0.022248169407248497,
0.04666256159543991,
0.025089118629693985,
-0.032848455011844635,
0.037607043981552124,
0.005744040943682194,
-0.026456324383616447,
0.04794098809361458,
-0.06349517405033112,
0.03931161016225815,
-0.02006419189274311,
0.019478246569633484,
-0.0032582117710262537,
0.02185753919184208,
-0.046023350208997726,
0.01727651245892048,
0.03228026628494263,
-0.04744382202625275,
-0.0338427871465683,
0.06672675162553787,
0.013166015967726707,
0.0054688239470124245,
0.002198405098170042,
-0.006840468849986792,
-0.027521679177880287,
-0.021591201424598694,
-0.048331618309020996,
-0.015944818034768105,
0.0028365084435790777,
-0.011496959254145622,
-0.04502901807427406,
-0.010591407306492329,
-0.012455779127776623,
-0.012571192346513271,
0.024414392188191414,
-0.006969199515879154,
-0.0069558825343847275,
0.06044115871191025,
0.005921599920839071,
0.013769717887043953,
-0.0035334285348653793,
-0.008886839263141155,
-0.03627534955739975,
0.002365976572036743,
-0.008833571337163448,
-0.06775660067796707,
-0.02414805442094803,
0.05841698497533798,
0.04989413917064667,
0.012686606496572495,
-0.03588471934199333,
-0.06360170990228653,
-0.00039063027361407876,
0.044318780303001404,
-0.0004619313986040652,
-0.013512256555259228,
-0.004261421039700508,
0.04346649721264839,
0.010715698823332787,
-0.00779041089117527,
0.05337430164217949,
0.018182063475251198,
-0.015589699149131775,
-0.04417673498392105,
-0.007195587269961834,
-0.004918390419334173,
-0.06559037417173386,
0.020863208919763565,
-0.09346717596054077,
0.01416034810245037,
0.00519804609939456,
-0.001601362251676619,
0.033008258789777756,
0.009996583685278893,
0.030185068026185036,
0.016592908650636673,
-0.045171067118644714,
0.06040564551949501,
0.04222358390688896,
-0.006014818791300058,
0.031232666224241257,
0.027859041467308998,
-0.009543808177113533,
-0.07372258603572845,
-0.03341664373874664,
0.01741855964064598,
-0.03201392665505409,
0.002767704427242279,
0.02448541671037674,
-0.01338796503841877,
-0.005007170140743256,
-0.03632861748337746,
-0.016140133142471313,
0.0430048443377018,
-0.042330119758844376,
0.013290307484567165,
-0.04911287873983383,
-0.032138217240571976,
0.013965032994747162,
-0.03190739080309868,
-0.050107210874557495,
0.008110017515718937,
0.06037013605237007,
-0.002383732469752431,
-0.015642967075109482,
0.02500033751130104,
-0.052379969507455826,
-0.05372941866517067,
-0.05720958113670349,
0.03668373450636864,
-0.0065963249653577805,
-0.003957351204007864,
-0.01629105769097805,
-0.048544690012931824,
-0.059553362429142,
-0.02677593007683754,
0.004816293716430664,
0.019975412636995316,
-0.07841014862060547,
-0.03203168138861656,
-0.049574535340070724,
0.016184523701667786,
0.00429915264248848,
0.04389264062047005,
-0.06076076626777649,
-0.06853786110877991,
0.03526326268911362,
-0.034943655133247375,
0.007421975489705801,
-0.02444990538060665,
-0.014133714139461517,
0.02251450903713703,
-0.023810692131519318,
0.04961004480719566,
0.020490333437919617,
0.00115635443944484,
0.04847366735339165,
0.01864371821284294,
0.008824693039059639,
-0.017844701185822487,
0.04080310836434364,
-0.052379969507455826,
0.011772176250815392,
-0.0038596936501562595,
0.05110154300928116,
-0.020667893812060356,
-0.012171684764325619,
0.021253839135169983,
-0.031108375638723373,
0.022265926003456116,
0.0202417504042387,
-0.01136379037052393,
-0.044141221791505814,
-0.004643173422664404,
-0.012304853647947311,
0.06480911374092102,
-0.06523525714874268,
-0.032653141766786575,
0.028089867904782295,
0.024538684636354446,
-0.06388580799102783,
-0.025124629959464073,
0.017764799296855927,
0.029900971800088882,
-0.024556439369916916,
0.02045482210814953,
-0.03668373450636864,
-0.02148466557264328,
0.0063299862667918205,
-0.0019897730089724064,
-0.06147100031375885,
-0.013272551819682121,
0.0506753996014595,
0.04190397635102272,
0.011132963001728058,
-0.038494840264320374,
0.07187597453594208,
-0.023899471387267113,
-0.01046711578965187,
0.024343369528651237,
0.04055452719330788,
0.04982311651110649,
-0.022248169407248497,
0.025426480919122696,
0.02413029782474041,
-0.026491835713386536,
-0.003722085151821375,
-0.02993648499250412,
-0.005499897059053183,
-0.009676977060735226,
-0.027361875399947166,
-0.021893052384257317,
0.03066447749733925,
0.10000135004520416,
0.050462331622838974,
-0.0006425424362532794,
0.012020759284496307,
0.047301776707172394,
0.01745407097041607,
0.02079218439757824,
-0.016557397320866585,
0.017764799296855927,
0.049041856080293655,
0.024947069585323334,
-0.009827902540564537,
-0.008922350592911243,
0.050817448645830154,
-0.02572833001613617,
-0.01664617657661438,
0.005251314025372267,
-0.02816089242696762,
-0.012207196094095707,
0.03746499493718147,
0.10717474669218063,
0.0359024740755558,
-0.1061093881726265,
0.018430646508932114,
-0.010307312943041325,
0.0059082829393446445,
-0.028498254716396332,
0.0318363681435585,
-0.0009122104966081679,
-0.000413380068494007,
0.0020730039104819298,
0.014657513238489628,
0.06956770271062851,
0.049041856080293655,
0.007741582114249468,
-0.01974458433687687,
-0.05383595451712608,
-0.06598100811243057,
-0.033611960709095,
-0.007426414173096418,
0.03288396820425987,
-0.11832546442747116,
-0.017569484189152718,
0.004059447441250086,
-0.025976913049817085,
0.04971658065915108,
-0.005926039069890976,
-0.03629310429096222,
0.04652051627635956,
0.05234445631504059,
-0.03956019505858421,
-0.004967219196259975,
-0.020152971148490906,
-0.028675813227891922,
0.005091510713100433,
-0.020383797585964203,
0.01277538575232029,
0.030256090685725212,
-0.020543601363897324,
0.014835072681307793,
-0.024769511073827744,
0.021733248606324196,
-0.047479335218667984,
-0.060476671904325485,
0.07148534059524536,
-0.038281768560409546,
0.02308269776403904,
-0.06097383424639702,
0.0032804065849632025,
0.03027384728193283,
-0.03817523270845413,
0.04421224445104599,
0.07379361242055893,
-0.07013589143753052,
-0.08380795270204544,
0.055895641446113586,
0.009312980808317661,
0.03222699835896492,
0.0019220785470679402,
0.02959912270307541,
0.034091368317604065,
0.03009628690779209,
-0.0031228228472173214,
0.011221742257475853,
0.015785014256834984,
-0.0039018639363348484,
0.007346512749791145,
-0.05323225259780884,
0.05284162238240242,
0.03682578355073929,
-0.028302939608693123,
-0.063104547560215,
-0.01956702582538128,
-0.0074574872851371765,
0.0001571676548337564,
-0.0014393394812941551,
0.028409475460648537,
0.04073208570480347,
0.028480498120188713,
-0.002074113581329584,
0.024591952562332153,
0.026882465928792953,
-0.04066106304526329,
0.00951717421412468,
-0.010937647894024849,
-0.048722248524427414,
-0.009756878949701786,
0.0007579559460282326,
0.0019997607450932264,
0.0049849748611450195,
0.04272074997425079,
-0.02590589039027691,
0.008775864727795124,
0.02993648499250412,
-0.019229663535952568,
-0.04396366328001022,
0.01696578413248062,
-0.023988250643014908,
-0.03597349673509598,
0.04378610476851463,
0.03552959859371185,
-0.022976163774728775,
0.019815608859062195,
-0.021395886316895485,
0.03966673091053963,
0.0353875532746315,
-0.005655261222273111,
0.025621796026825905,
-0.03130368888378143,
-0.0043524205684661865,
0.013023968786001205,
-0.009987706318497658,
0.005686333868652582,
-0.00958819780498743,
0.028427230194211006,
0.02675817348062992,
0.04215255752205849,
-0.03013180010020733,
0.0682537630200386,
0.008953423239290714,
-0.06708187609910965,
0.09481662511825562,
0.01706344075500965,
0.0014926071744412184,
-0.003502355655655265,
-0.07315439730882645,
0.0257105752825737,
0.004443419631570578,
0.0496455579996109,
0.009978828020393848,
-0.006063647568225861,
-0.06324659287929535,
0.0070979297161102295,
-0.03322133049368858,
-0.10404970496892929,
0.024538684636354446,
0.007439731154590845,
-0.011576861143112183,
0.011408179998397827,
0.00836303923279047,
-0.03190739080309868,
0.08160621672868729,
0.05543398857116699,
0.006773884408175945,
0.019123127683997154,
0.03220924362540245,
0.09062622487545013,
-0.003575598821043968,
0.04723075404763222,
0.06857337057590485,
0.034783851355314255,
-0.016681687906384468,
-0.01304172445088625,
-0.023899471387267113,
0.010058729909360409,
0.0098634148016572,
-0.04804752394556999,
0.02450317144393921,
0.0010936538456007838,
0.014115957543253899,
-0.0013638767413794994,
-0.0026633883826434612,
-0.01716109924018383,
0.006693982519209385,
-0.013538890518248081,
0.01622891239821911,
-0.022993918508291245,
-0.04698216915130615,
0.000993776717223227,
0.014719659462571144,
0.029190735891461372,
0.03499692305922508,
0.0024014883674681187,
-0.00040561184869147837,
-0.0274861678481102,
0.01189646776765585,
0.017942359670996666,
0.007142319809645414,
-0.08792732656002045,
-0.021360374987125397,
-0.01882127672433853,
-0.029350539669394493,
0.00951717421412468,
0.01830635592341423,
-0.011736663989722729,
0.0313214473426342,
-0.006130232010036707,
0.0076616802252829075,
0.05000067502260208,
0.006538618355989456,
-0.07148534059524536,
-0.0039839851669967175,
0.04932595044374466,
-0.08508637547492981,
0.0025635112542659044,
-0.009579319506883621,
0.03632861748337746,
-0.02569281868636608,
0.04744382202625275,
-0.04612988606095314,
-0.03352317959070206,
-0.003153895726427436,
0.04911287873983383,
0.042685236781835556,
-0.027610458433628082,
-0.001114184153266251
]
|
32,873 | bqplot.scales | DateScale | A date scale, with customizable formatting.
An affine mapping from dates to a numerical range.
Attributes
----------
min: Date or None (default: None)
if not None, min is the minimal value of the domain
max: Date (default: None)
if not None, max is the maximal value of the domain
domain_class: type (default: Date)
traitlet type used to validate values in of the domain of the scale.
rtype: string (class-level attribute)
This attribute should not be modified by the user.
The range type of a linear scale is numerical.
dtype: type (class-level attribute)
the associated data type / domain type
| class DateScale(Scale):
"""A date scale, with customizable formatting.
An affine mapping from dates to a numerical range.
Attributes
----------
min: Date or None (default: None)
if not None, min is the minimal value of the domain
max: Date (default: None)
if not None, max is the maximal value of the domain
domain_class: type (default: Date)
traitlet type used to validate values in of the domain of the scale.
rtype: string (class-level attribute)
This attribute should not be modified by the user.
The range type of a linear scale is numerical.
dtype: type (class-level attribute)
the associated data type / domain type
"""
rtype = 'Number'
dtype = np.datetime64
domain_class = Type(Date)
min = Date(default_value=None, allow_none=True).tag(sync=True)
max = Date(default_value=None, allow_none=True).tag(sync=True)
_view_name = Unicode('DateScale').tag(sync=True)
_model_name = Unicode('DateScaleModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.031739987432956696,
-0.023979730904102325,
0.014221162535250187,
0.047135043889284134,
-0.011048956774175167,
-0.025431416928768158,
-0.06276308745145798,
-0.05699218437075615,
0.013979215174913406,
-0.02376466616988182,
0.022044146433472633,
0.0363997258245945,
0.05046854913234711,
0.019445447251200676,
0.0008367366390302777,
0.008683242835104465,
-0.02182908169925213,
0.014669214375317097,
0.012213891372084618,
0.021757394075393677,
0.0008283357019536197,
-0.03514517843723297,
0.0020050315652042627,
0.024481547996401787,
0.011165449395775795,
0.05566595122218132,
0.024069340899586678,
-0.005941166542470455,
-0.018531421199440956,
-0.05975218117237091,
-0.030413754284381866,
0.022922327741980553,
0.0076392823830246925,
0.01392544899135828,
0.034464139491319656,
-0.04885556548833847,
-0.03152492269873619,
-0.03236725926399231,
-0.09090074151754379,
0.055952705442905426,
0.007948438636958599,
-0.023979730904102325,
-0.00128254818264395,
-0.018441811203956604,
0.005573763977736235,
0.009194022044539452,
0.003826362080872059,
0.03329920768737793,
-0.033012453466653824,
-0.01741129159927368,
0.016551032662391663,
-0.014964928850531578,
0.027456611394882202,
-0.010995190590620041,
-0.08939528465270996,
0.09054230153560638,
0.02093297801911831,
0.13907526433467865,
-0.010789086110889912,
0.02139895223081112,
-0.0021080835722386837,
0.012536488473415375,
0.007406295742839575,
-0.044876862317323685,
-0.01733064278960228,
0.0319192074239254,
-0.005143634043633938,
-0.027958430349826813,
-0.0028518494218587875,
0.010941424407064915,
-0.02188284881412983,
-0.022707263007760048,
0.03688362240791321,
0.059035301208496094,
-0.0026771093253046274,
0.02500128746032715,
-0.040826477110385895,
0.05985971540212631,
0.008530905470252037,
-0.026793494820594788,
0.051328808069229126,
0.012473761104047298,
-0.007648243568837643,
-0.0363997258245945,
0.010018437169492245,
-0.07670646160840988,
-0.02098674513399601,
0.03695530816912651,
0.0004329300136305392,
0.005654413253068924,
-0.048998940736055374,
0.004709023982286453,
0.02555687166750431,
0.03507349267601967,
0.021327264606952667,
0.01636284962296486,
0.005972529761493206,
0.02181115932762623,
-0.0319192074239254,
0.0058381143026053905,
0.015412980690598488,
0.007809542119503021,
-0.0295893382281065,
0.014149474911391735,
-0.026829339563846588,
-0.012778435833752155,
-0.018585186451673508,
-0.007280841004103422,
-0.0547698475420475,
0.02738492377102375,
-0.05236829072237015,
0.07677815109491348,
-0.009462852962315083,
-0.004294576123356819,
-0.057243093848228455,
0.0052914912812411785,
-0.034912191331386566,
0.031202323734760284,
-0.0073659708723425865,
0.015547395683825016,
-0.05530750751495361,
0.050898678600788116,
-0.03480466082692146,
0.03781556710600853,
-0.017232069745659828,
0.008096295408904552,
0.04527115076780319,
0.02421271614730358,
-0.023065704852342606,
-0.005327335558831692,
-0.02098674513399601,
0.01300246175378561,
-0.006187594961374998,
0.032618168741464615,
0.06462698429822922,
-0.040360502898693085,
0.03338881582021713,
0.05373036861419678,
-0.057673223316669464,
0.11971943080425262,
0.022456353530287743,
0.021112198010087013,
0.04742179811000824,
-0.004299056716263294,
0.013065189123153687,
0.005609607789665461,
0.04659738391637802,
0.049464914947748184,
-0.04053972288966179,
0.051794782280921936,
-0.03462544083595276,
0.01957090012729168,
0.05519997701048851,
-0.012240773998200893,
0.048963095992803574,
-0.04892725124955177,
-0.016318045556545258,
-0.043980762362480164,
0.014749864116311073,
0.02139895223081112,
-0.05322854965925217,
0.007500386331230402,
-0.01829843409359455,
-0.055881015956401825,
-0.012178046628832817,
0.017527785152196884,
-0.0036381802055984735,
-0.0729786679148674,
-0.0023993172217160463,
0.049500759690999985,
-0.016246356070041656,
-0.04243946075439453,
0.00980337243527174,
0.03294076398015022,
0.004865841940045357,
0.037672191858291626,
0.04394491761922836,
0.055379197001457214,
-0.02143479697406292,
0.037636347115039825,
0.07993243634700775,
0.012491683475673199,
-0.062297116965055466,
0.019535057246685028,
-0.03910595923662186,
0.04000205919146538,
-0.07079217582941055,
-0.005636491347104311,
-0.03752881661057472,
0.022456353530287743,
0.07620464265346527,
0.02234882116317749,
0.0010389200178906322,
-0.04390907287597656,
-0.031238168478012085,
0.02145271748304367,
-0.05839010700583458,
-0.01785038225352764,
0.006165191996842623,
0.026255832985043526,
0.031668297946453094,
0.02781505323946476,
0.0409698523581028,
-0.04792361706495285,
0.0027420767582952976,
0.0031968492548912764,
-0.01738440804183483,
-0.0007605678401887417,
-0.07713659107685089,
-0.04935738071799278,
-0.014006097801029682,
-0.041758425533771515,
-0.05283426493406296,
0.02329869195818901,
0.027958430349826813,
-0.06921503692865372,
-0.014032981358468533,
-0.02276103012263775,
-0.027205701917409897,
0.002390356035903096,
0.09004048258066177,
-0.010332074016332626,
0.01871064119040966,
-0.01915869303047657,
0.04735010862350464,
-0.027564143761992455,
0.06652672588825226,
-0.023137392476201057,
0.03622050583362579,
-0.025700248777866364,
-0.02193661406636238,
-0.07706490159034729,
-0.013342981226742268,
-0.02917713113129139,
0.051364652812480927,
0.045916344970464706,
0.024481547996401787,
0.04613140970468521,
0.013092072680592537,
0.04412413761019707,
-0.016273239627480507,
0.028460247442126274,
-0.02869323454797268,
0.0023589925840497017,
0.018925705924630165,
-0.05114958807826042,
0.0227968730032444,
0.049966733902692795,
-0.06455529481172562,
-0.03528855741024017,
-0.017572589218616486,
-0.03828154131770134,
0.008002204820513725,
0.042152710258960724,
0.027743365615606308,
0.01276051439344883,
-0.023029860109090805,
-0.04010959342122078,
0.0029549014288932085,
-0.03917764499783516,
0.0022805833723396063,
-0.020843368023633957,
-0.0501459538936615,
0.039356864988803864,
0.014212201349437237,
0.004476036876440048,
-0.008495061658322811,
0.01552947424352169,
0.030467519536614418,
0.04415998235344887,
0.06527218222618103,
0.028549857437610626,
-0.05423218384385109,
-0.0055379197001457214,
0.023603366687893867,
-0.019929341971874237,
0.020771680399775505,
-0.0682830885052681,
0.024409860372543335,
0.018441811203956604,
-0.036776088178157806,
-0.05867685750126839,
-0.010170774534344673,
-0.0027712001465260983,
0.039428554475307465,
-0.07168827950954437,
-0.03247478976845741,
-0.015404019504785538,
-0.018871940672397614,
0.023639211431145668,
-0.03156076744198799,
0.00823071040213108,
0.010726358741521835,
-0.006407140288501978,
-0.02828102745115757,
-0.026184145361185074,
0.055486731231212616,
-0.027008559554815292,
-0.0022772231604903936,
-0.049966733902692795,
0.02914128638803959,
-0.005318374373018742,
0.0869578868150711,
0.03838907554745674,
-0.04408829286694527,
-0.03231349214911461,
0.00891622994095087,
-0.024786222726106644,
0.018800251185894012,
0.022689340636134148,
0.0010596424108371139,
0.0593578964471817,
-0.06964516639709473,
-0.01962466724216938,
-0.033532194793224335,
-0.0005295411683619022,
-0.005255647003650665,
0.0055424002930521965,
0.019015315920114517,
0.04881972074508667,
-0.05649036541581154,
0.008521944284439087,
-0.015672851353883743,
-0.020216096192598343,
0.03924933448433876,
0.045844655483961105,
-0.003514965996146202,
0.020807523280382156,
0.019015315920114517,
0.03335297107696533,
0.012877007946372032,
0.0003850444918498397,
0.04699166864156723,
0.031686220318078995,
-0.026775572448968887,
-0.05792413279414177,
0.03828154131770134,
0.0018963790498673916,
-0.014239084906876087,
-0.025861548259854317,
-0.008002204820513725,
-0.005327335558831692,
-0.07097139954566956,
-0.007827464491128922,
0.015896877273917198,
-0.018603108823299408,
-0.004964413587003946,
-0.03381894528865814,
0.04243946075439453,
0.01912284828722477,
0.002024073852226138,
0.03455375134944916,
-0.02147063985466957,
-0.007227074820548296,
-0.006039737723767757,
-0.06731529533863068,
0.053658679127693176,
-0.053085170686244965,
-0.002957141725346446,
-0.02966102585196495,
0.026237910613417625,
-0.03414154425263405,
-0.018871940672397614,
-0.03914180025458336,
0.03018076717853546,
0.018020641058683395,
-0.016300123184919357,
-0.03286907821893692,
0.07971736788749695,
0.04519946128129959,
0.016577914357185364,
-0.02779713086783886,
-0.02604076825082302,
-0.00526012759655714,
-0.015439863316714764,
-0.01185544952750206,
-0.011102722957730293,
-0.00007287842163350433,
-0.04527115076780319,
-0.038030631840229034,
0.009686878882348537,
-0.033030375838279724,
-0.0020173529628664255,
0.03475089371204376,
0.006787984166294336,
-0.010923502035439014,
0.08745970577001572,
-0.0074018151499331,
0.027008559554815292,
-0.024839989840984344,
0.013961292803287506,
-0.0363280363380909,
-0.0007415256695821881,
0.006989607587456703,
-0.08867840468883514,
-0.0548056922852993,
0.031166480854153633,
0.04502024129033089,
0.016228435561060905,
-0.018997395411133766,
-0.06244049221277237,
0.009579346515238285,
0.016085058450698853,
0.022994015365839005,
-0.011828566901385784,
0.022922327741980553,
0.06892827898263931,
0.00978545006364584,
-0.0011884572450071573,
0.07814022898674011,
0.021578172221779823,
-0.010860774666070938,
-0.0501817986369133,
-0.011255060322582722,
0.023531679064035416,
-0.02562856115400791,
0.028908299282193184,
-0.07849866896867752,
-0.0014673694968223572,
-0.010833891108632088,
-0.001533457194454968,
0.04408829286694527,
0.001217580633237958,
0.030359987169504166,
0.02229505591094494,
-0.06330075114965439,
0.04935738071799278,
0.008114217780530453,
-0.0036628232337534428,
0.05430387333035469,
0.021614016965031624,
-0.019714277237653732,
-0.09634905308485031,
-0.0409698523581028,
0.030933493748307228,
-0.049464914947748184,
-0.016586875542998314,
0.004231848753988743,
-0.029876090586185455,
-0.017438175156712532,
-0.032098427414894104,
-0.010430645197629929,
0.0727277621626854,
-0.033568039536476135,
0.02148856222629547,
-0.057207249104976654,
-0.031184403225779533,
0.025216352194547653,
-0.04469764232635498,
-0.07391061633825302,
0.026560507714748383,
0.04842543229460716,
0.02964310348033905,
-0.003257336327806115,
0.013683500699698925,
-0.05785244330763817,
-0.042224396020174026,
-0.09348151832818985,
0.027582066133618355,
0.014077786356210709,
-0.012482722289860249,
-0.006129348184913397,
-0.030324142426252365,
-0.03681193292140961,
-0.02550310641527176,
0.01777869462966919,
0.005322854965925217,
-0.06882075220346451,
-0.046704914420843124,
-0.038532450795173645,
0.018477654084563255,
0.0020162328146398067,
0.04960829019546509,
-0.0773516520857811,
-0.07064880430698395,
0.03053920716047287,
-0.02057453617453575,
0.008038048632442951,
-0.0016611518803983927,
-0.01388960424810648,
0.02193661406636238,
-0.0411849170923233,
0.04835374653339386,
0.0591428317129612,
-0.012339345179498196,
0.032654013484716415,
0.019319992512464523,
0.011246099136769772,
-0.03270777687430382,
0.04932153597474098,
-0.021721549332141876,
0.04150751605629921,
0.012814280577003956,
0.044984396547079086,
-0.028854534029960632,
-0.01025142427533865,
0.005977010354399681,
-0.03742128238081932,
0.006111425813287497,
0.0040100631304085255,
-0.023459989577531815,
-0.05254751071333885,
-0.013934409245848656,
0.0205028485506773,
0.0731937363743782,
-0.018603108823299408,
-0.03781556710600853,
0.041722580790519714,
0.006989607587456703,
-0.07799685001373291,
-0.05125712230801582,
0.008047009818255901,
0.020825445652008057,
0.020807523280382156,
0.004019024316221476,
-0.01695427857339382,
-0.011721033602952957,
0.021721549332141876,
-0.025646483525633812,
-0.048031147569417953,
-0.0019042199710384011,
0.020198173820972443,
0.02643505297601223,
-0.007473503239452839,
-0.013217526488006115,
0.04165089130401611,
-0.026255832985043526,
-0.014920123852789402,
0.03405193239450455,
0.04179426655173302,
0.06749451905488968,
-0.013074150308966637,
0.06272724270820618,
0.024965444579720497,
-0.047744397073984146,
0.046740759164094925,
-0.03410569950938225,
-0.014579604379832745,
0.014292851090431213,
-0.0035956152714788914,
-0.03706284239888191,
0.03145323321223259,
0.05193816125392914,
0.0502893291413784,
0.04742179811000824,
0.011989865452051163,
0.039858683943748474,
0.01829843409359455,
0.048604656010866165,
-0.009010320529341698,
-0.010081164538860321,
0.03622050583362579,
0.05046854913234711,
0.0070926593616604805,
-0.004090712405741215,
0.016551032662391663,
-0.0007784899207763374,
0.013118955306708813,
0.000019147211787640117,
-0.03587998449802399,
-0.037708036601543427,
0.011622462421655655,
0.14007890224456787,
0.05394543334841728,
-0.11140359193086624,
0.030234532430768013,
-0.00983025599271059,
0.031166480854153633,
-0.012841163203120232,
0.03596959635615349,
0.017043888568878174,
-0.022044146433472633,
0.0042654527351260185,
0.012652982026338577,
0.04731426760554314,
0.0546264722943306,
0.000008825394615996629,
-0.028101805597543716,
-0.09240619838237762,
-0.022062068805098534,
-0.03240310400724411,
0.006747659295797348,
-0.006227919366210699,
-0.09670749306678772,
-0.020395316183567047,
0.038496606051921844,
-0.04709919914603233,
0.044948551803827286,
-0.010125969536602497,
-0.046382319182157516,
0.018405966460704803,
0.0318295955657959,
-0.028191417455673218,
0.02143479697406292,
0.021578172221779823,
-0.024391938000917435,
-0.02190076932311058,
-0.03799479082226753,
0.03372933715581894,
0.00012741472164634615,
-0.030270377174019814,
0.03363972529768944,
-0.04978751018643379,
0.03372933715581894,
-0.03288700059056282,
-0.04200933128595352,
0.04824621230363846,
-0.026166222989559174,
0.019678432494401932,
-0.04821036756038666,
-0.003933894447982311,
0.03181167319417,
-0.03390855714678764,
0.01635388843715191,
0.04423166811466217,
-0.06975270062685013,
-0.07720828056335449,
0.02550310641527176,
0.021201809868216515,
-0.027098169550299644,
-0.012491683475673199,
0.02559271641075611,
0.01391648780554533,
0.019337913021445274,
-0.005515517201274633,
-0.005098829045891762,
0.03003739006817341,
-0.009283632040023804,
0.012948695570230484,
-0.052726730704307556,
0.059106986969709396,
0.016201552003622055,
-0.006626685615628958,
-0.06197451800107956,
-0.02100466564297676,
0.018405966460704803,
-0.006008374039083719,
-0.0007152025937102735,
0.03914180025458336,
0.04319218918681145,
0.00935532059520483,
-0.022097913548350334,
0.019051160663366318,
0.00307811563834548,
-0.03095141611993313,
0.0055827246978878975,
-0.0365968681871891,
-0.0593578964471817,
-0.006120386999100447,
0.011308826506137848,
0.010574021376669407,
-0.005354218650609255,
0.03688362240791321,
-0.01770700514316559,
0.02966102585196495,
0.04390907287597656,
-0.010349995456635952,
-0.04799530282616615,
0.02607661299407482,
-0.014498954638838768,
-0.037600502371788025,
0.012178046628832817,
0.018128173425793648,
-0.028478169813752174,
0.03288700059056282,
-0.014194279909133911,
-0.012966617941856384,
0.03344258293509483,
0.015798304229974747,
0.02134518511593342,
-0.024750379845499992,
-0.004556686617434025,
0.022062068805098534,
0.009758567437529564,
0.01552051305770874,
-0.008038048632442951,
0.04835374653339386,
0.011532852426171303,
0.014660253189504147,
-0.0204490814357996,
0.04333556443452835,
-0.0102424630895257,
-0.05351530387997627,
0.05616777017712593,
-0.018782328814268112,
-0.03057505190372467,
0.004245290532708168,
-0.052690885961055756,
0.016255317255854607,
0.01781453751027584,
0.06534387171268463,
-0.014982851222157478,
-0.006707334890961647,
-0.06645503640174866,
0.044984396547079086,
-0.05304932966828346,
-0.08036256581544876,
0.02324492484331131,
-0.028442325070500374,
0.004592530429363251,
0.011031034402549267,
0.016990123316645622,
-0.006770062260329723,
0.08050593733787537,
0.04641816392540932,
-0.004780712071806192,
-0.02274310775101185,
0.03369349241256714,
0.08896515518426895,
-0.018092330545186996,
0.0638742595911026,
0.06649088114500046,
0.049070630222558975,
-0.009247788228094578,
0.018074408173561096,
-0.028872454538941383,
0.02139895223081112,
0.03828154131770134,
-0.045342836529016495,
0.02684726193547249,
0.005098829045891762,
0.012366228736937046,
0.01462440937757492,
-0.03181167319417,
-0.032654013484716415,
0.02605869062244892,
-0.0363638810813427,
-0.006931360810995102,
-0.01921246014535427,
-0.05233244597911835,
-0.020162329077720642,
0.03510933741927147,
0.015404019504785538,
-0.026112455874681473,
0.01096830703318119,
-0.015798304229974747,
-0.03288700059056282,
0.006003893446177244,
0.027044404298067093,
0.0026569468900561333,
-0.062332961708307266,
-0.011120644398033619,
0.005609607789665461,
-0.04283374920487404,
0.028370637446641922,
0.017232069745659828,
-0.029320506379008293,
0.02643505297601223,
-0.015412980690598488,
0.01729479804635048,
0.04010959342122078,
-0.014113630168139935,
-0.06021815538406372,
-0.013997136615216732,
0.06577400118112564,
-0.07649139314889908,
0.016156746074557304,
-0.006389217916876078,
0.01781453751027584,
-0.03421323373913765,
0.02688310481607914,
-0.03835323080420494,
-0.01641661673784256,
0.006671490613371134,
0.017456095665693283,
0.007903632707893848,
-0.01821778528392315,
0.02012648433446884
]
|
32,987 | bqplot.scales | EquiRectangular | An elementary projection that uses the identity function.
The projection is neither equal-area nor conformal.
Attributes
----------
scale_factor: float (default: 145)
Specifies the scale value for the projection
center: tuple (default: (0, 60))
Specifies the longitude and latitude where the map is centered.
| class EquiRectangular(GeoScale):
"""An elementary projection that uses the identity function.
The projection is neither equal-area nor conformal.
Attributes
----------
scale_factor: float (default: 145)
Specifies the scale value for the projection
center: tuple (default: (0, 60))
Specifies the longitude and latitude where the map is centered.
"""
scale_factor = Float(145.0).tag(sync=True)
center = Tuple((0, 60)).tag(sync=True)
rtype = '(Number, Number)'
dtype = np.number
_view_name = Unicode('EquiRectangular').tag(sync=True)
_model_name = Unicode('EquiRectangularModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.058499790728092194,
-0.062001023441553116,
0.008383815176784992,
0.030380500480532646,
-0.029924610629677773,
-0.02253919467329979,
-0.03869593143463135,
-0.09270976483821869,
-0.028392821550369263,
-0.018518246710300446,
0.06254809349775314,
0.004071096424013376,
-0.03258700668811798,
0.07057175040245056,
-0.02004091814160347,
-0.01724175550043583,
-0.027863988652825356,
-0.049090221524238586,
-0.004946405068039894,
-0.023378033190965652,
-0.001404140843078494,
0.0027398981619626284,
0.030708741396665573,
0.041941870003938675,
-0.0033735851757228374,
-0.0003339393297210336,
0.04372895509004593,
-0.020879756659269333,
0.017797941341996193,
-0.03687237203121185,
-0.10102519392967224,
0.026751618832349777,
-0.015062601305544376,
-0.029031068086624146,
-0.006118041928857565,
-0.042926590889692307,
0.017405875027179718,
0.05430560186505318,
-0.022685080766677856,
0.0037975625600665808,
-0.07327061891555786,
0.010904885828495026,
-0.018381480127573013,
-0.03236817941069603,
0.03818533569574356,
-0.011643427424132824,
0.006204661447554827,
-0.00024632300483062863,
0.01945737935602665,
0.04671959578990936,
0.0075951251201331615,
-0.003022549906745553,
-0.01870972104370594,
0.023414503782987595,
-0.0913238599896431,
0.050002001225948334,
-0.016120266169309616,
0.09146974235773087,
0.006396134849637747,
-0.029541663825511932,
-0.05532679706811905,
-0.017533523961901665,
0.01021193340420723,
-0.05423266068100929,
-0.0015899159479886293,
0.038659460842609406,
-0.014688772149384022,
0.027809282764792442,
0.03605177253484726,
0.023815687745809555,
-0.050622012466192245,
0.017880000174045563,
0.0041440390050411224,
-0.02817399427294731,
0.06221985071897507,
0.03203994035720825,
-0.03698178753256798,
0.06838348507881165,
0.022612137719988823,
-0.025311006233096123,
0.0052609690465033054,
-0.008424844592809677,
0.06440812349319458,
-0.022648608312010765,
-0.019512087106704712,
-0.03840416297316551,
0.04106656089425087,
-0.026715146377682686,
0.048287857323884964,
-0.030015788972377777,
-0.012564324773848057,
0.01425111759454012,
0.0012593957362696528,
0.020752107724547386,
0.03375408798456192,
0.009783396497368813,
-0.011014299467206001,
0.02445393241941929,
-0.001587636535987258,
-0.054852668195962906,
0.00515155540779233,
0.009259123355150223,
-0.0935850739479065,
-0.009701336733996868,
-0.014880245551466942,
0.034793514758348465,
0.02658749744296074,
-0.027280449867248535,
-0.002123307203873992,
0.05809860676527023,
-0.006897613871842623,
0.09125091880559921,
-0.0528467558324337,
0.07188471406698227,
-0.07352592051029205,
0.015017012134194374,
-0.04551604390144348,
0.025876309722661972,
0.046537239104509354,
-0.013175217434763908,
-0.006897613871842623,
0.06448106467723846,
-0.05335735157132149,
0.027426334097981453,
0.015874085947871208,
0.024326283484697342,
0.02583983726799488,
0.036215890198946,
-0.05364912003278732,
-0.0571138821542263,
0.029979318380355835,
-0.0318211130797863,
0.007832188159227371,
-0.01599261723458767,
0.03043520823121071,
-0.0014565681340172887,
0.05744212493300438,
-0.017797941341996193,
0.006414370611310005,
0.1106535941362381,
-0.023961571976542473,
0.0299063753336668,
0.020697399973869324,
0.0283381137996912,
-0.001333477906882763,
0.03566882386803627,
0.01764293760061264,
0.008743967860937119,
-0.0028538706246763468,
-0.008520581759512424,
-0.02137211710214615,
-0.001047976897098124,
0.044057197868824005,
-0.0034032179974019527,
0.02797340229153633,
-0.06404341012239456,
0.07053527981042862,
-0.046901948750019073,
0.024180399253964424,
0.01947561465203762,
-0.027645161375403404,
0.020551515743136406,
0.0019512086873874068,
0.014579358510673046,
0.009227210655808449,
-0.04008183628320694,
0.0033599084708839655,
-0.10357818007469177,
-0.011442835442721844,
0.05029376968741417,
-0.007950719445943832,
-0.062183380126953125,
-0.059484511613845825,
-0.005798919126391411,
0.0294687207788229,
0.018372362479567528,
0.02470923215150833,
0.045625459402799606,
-0.0318211130797863,
0.015117308124899864,
0.05820801854133606,
-0.022265661507844925,
0.022448018193244934,
0.01358551811426878,
0.014460827223956585,
0.07958013564348221,
0.02892165444791317,
-0.02470923215150833,
-0.0014873407781124115,
-0.05612916126847267,
-0.001754036289639771,
-0.018454421311616898,
-0.02004091814160347,
-0.007111881859600544,
0.0069979093968868256,
-0.0017255431739613414,
0.02817399427294731,
-0.01331198401749134,
0.023432739078998566,
0.021554473787546158,
-0.10627704858779907,
-0.04026419296860695,
0.017396757379174232,
0.0026373229920864105,
-0.07338003814220428,
0.006546578835695982,
0.01925678923726082,
-0.02715280093252659,
0.03669001907110214,
0.012573442421853542,
-0.010585762560367584,
-0.006241132505238056,
-0.07042586803436279,
-0.0064326063729822636,
0.04686547815799713,
0.007234972435981035,
-0.01850912906229496,
-0.02892165444791317,
0.016238797456026077,
0.06849289685487747,
0.05361264944076538,
-0.02007739059627056,
0.05324793606996536,
-0.05992216616868973,
-0.002279449487105012,
-0.014825538732111454,
0.026551026850938797,
-0.008329108357429504,
0.009090444073081017,
-0.04624547064304352,
-0.0012103876797482371,
-0.03957124054431915,
-0.03949829936027527,
-0.05324793606996536,
-0.002258934313431382,
-0.010686058551073074,
-0.009035737253725529,
0.01126047968864441,
0.031529344618320465,
-0.0009009523782879114,
0.002181433141231537,
0.019694441929459572,
-0.050403185188770294,
0.05594680458307266,
-0.006669668946415186,
-0.048652566969394684,
-0.006054217461496592,
0.0505855418741703,
0.0016662775306031108,
-0.016603508964180946,
-0.018764426931738853,
-0.04015478119254112,
-0.03971712663769722,
0.054086774587631226,
0.07381768524646759,
-0.012737562879920006,
-0.04639135301113129,
-0.02062445878982544,
0.010366936214268208,
-0.004205584060400724,
0.0022840083111077547,
-0.044239554554224014,
0.013348455540835857,
0.0505855418741703,
0.051716148853302,
-0.005457001738250256,
-0.03741944208741188,
0.01820824109017849,
0.022830964997410774,
0.03388173505663872,
0.10540173947811127,
0.05394088849425316,
-0.008037338964641094,
0.000987571431323886,
0.0333893746137619,
0.015281428582966328,
-0.00012408752809278667,
0.0016172693576663733,
0.047886673361063004,
0.002710265340283513,
-0.04296306148171425,
-0.055436208844184875,
-0.007777481339871883,
0.04537016153335571,
0.009382213465869427,
-0.03785709664225578,
0.0017323815263807774,
0.02118976227939129,
0.03720061480998993,
-0.023651566356420517,
-0.03448351100087166,
0.0382218062877655,
-0.041723042726516724,
-0.010749883018434048,
0.04974670335650444,
-0.006149954628199339,
0.007996308617293835,
-0.0074765938334167,
0.022703316062688828,
-0.01794382557272911,
0.06495518982410431,
-0.012956390157341957,
0.010239286348223686,
-0.025146884843707085,
0.01457024086266756,
0.013612871989607811,
-0.027134565636515617,
0.01798941381275654,
0.01607467792928219,
0.00421926099807024,
-0.03202170506119728,
0.010476348921656609,
-0.07064469158649445,
-0.010084284469485283,
-0.020113861188292503,
0.04168657213449478,
0.044640738517045975,
-0.007804834749549627,
0.011844019405543804,
0.010558409616351128,
-0.040957145392894745,
-0.011570485308766365,
-0.0076543912291526794,
-0.012856094166636467,
0.020150331780314445,
-0.029632842168211937,
-0.013603754341602325,
-0.0011089520994573832,
0.023013321682810783,
0.035595882683992386,
-0.02465452440083027,
0.004643238615244627,
0.010658705607056618,
0.0149531876668334,
-0.049090221524238586,
-0.0654657855629921,
0.09103208780288696,
0.05262792855501175,
-0.002095953794196248,
-0.008224253542721272,
-0.012619031593203545,
0.0075768898241221905,
-0.02066092938184738,
0.029414014890789986,
-0.03566882386803627,
-0.017962060868740082,
-0.049673762172460556,
-0.058536261320114136,
0.05631151795387268,
-0.04639135301113129,
-0.038294751197099686,
-0.0593750961124897,
0.02332332544028759,
-0.03358996659517288,
-0.003460204228758812,
0.05452442914247513,
0.006710698828101158,
0.0035194698721170425,
0.01694086752831936,
0.009655747562646866,
0.06174572557210922,
-0.04668312519788742,
-0.06371516734361649,
-0.0149531876668334,
-0.05182556062936783,
0.0062092202715575695,
-0.050220828503370285,
0.004773166961967945,
0.08060132712125778,
0.00564391678199172,
-0.011488424614071846,
-0.05634798854589462,
-0.051169078797101974,
0.02255743183195591,
-0.03377232328057289,
0.026569262146949768,
-0.03840416297316551,
0.024180399253964424,
-0.05919274315237999,
-0.09336625039577484,
0.0042283786460757256,
-0.010102519765496254,
-0.0013494340237230062,
-0.03196699917316437,
-0.035176463425159454,
0.0033941001165658236,
0.03597882762551308,
0.025329241529107094,
0.01717793010175228,
0.00603142287582159,
-0.008648230694234371,
-0.028830476105213165,
-0.0016594391781836748,
-0.029632842168211937,
-0.061016302555799484,
0.005425089504569769,
-0.007175706792622805,
0.03242288902401924,
-0.01752440631389618,
0.007704538758844137,
-0.027863988652825356,
-0.014688772149384022,
0.027079857885837555,
0.012126671150326729,
0.0294687207788229,
-0.039826538413763046,
0.0672164037823677,
-0.015609669499099255,
0.06663286685943604,
0.005944803822785616,
0.03353526070713997,
-0.0056120045483112335,
-0.011825783178210258,
0.02370627410709858,
-0.0640798807144165,
-0.008260724134743214,
-0.00515611469745636,
-0.07305179536342621,
-0.01493495237082243,
0.0034510863479226828,
0.004483676981180906,
0.052117329090833664,
-0.036525897681713104,
0.039060644805431366,
0.011935196816921234,
-0.04128538817167282,
0.024964530020952225,
-0.013156982138752937,
0.053867947310209274,
0.059703338891267776,
-0.05919274315237999,
-0.04507838934659958,
-0.028775768354535103,
-0.040774788707494736,
0.0018087431089952588,
-0.02563924714922905,
0.0027900461573153734,
0.006801877170801163,
-0.013731403276324272,
-0.008857940323650837,
0.06798230111598969,
0.011689016595482826,
0.017588231712579727,
-0.06229279190301895,
0.015600551851093769,
-0.051971446722745895,
-0.05547267943620682,
0.0038408723194152117,
-0.023177441209554672,
0.012464028783142567,
0.08687437325716019,
0.030544621869921684,
-0.00935486052185297,
-0.0015010173665359616,
0.07425533980131149,
-0.06462694704532623,
-0.048506684601306915,
-0.038841817528009415,
-0.011123713105916977,
-0.051387906074523926,
-0.005183468107134104,
0.00008989578782347962,
-0.014141703955829144,
0.004112126771360636,
0.0129290372133255,
0.04223363846540451,
0.025511598214507103,
-0.025402184575796127,
-0.04139479994773865,
-0.07265061140060425,
0.02870282717049122,
0.0031593169551342726,
-0.022083304822444916,
-0.05357617884874344,
0.002537027234211564,
0.07206707447767258,
-0.009245446883141994,
0.07950719445943832,
0.006765405647456646,
-0.05189850181341171,
-0.033042896538972855,
-0.023578625172376633,
0.009765161201357841,
0.025529833510518074,
0.0014018613146618009,
0.05277381092309952,
0.0008633414399810135,
-0.013211688958108425,
-0.04817844182252884,
0.005498032085597515,
-0.03840416297316551,
0.03528587520122528,
-0.01764293760061264,
0.08526964485645294,
-0.03353526070713997,
0.01724175550043583,
0.035176463425159454,
-0.0393524132668972,
-0.015363489277660847,
0.017205283045768738,
0.021718593314290047,
-0.04919963702559471,
0.015409077517688274,
0.006345986854285002,
0.03663530945777893,
-0.02700691670179367,
-0.043254829943180084,
0.03355349600315094,
0.006491872016340494,
-0.00023335863079410046,
-0.0313834585249424,
-0.051752619445323944,
0.04110303148627281,
-0.016749393194913864,
0.05160673335194588,
0.03353526070713997,
0.00800542626529932,
-0.004991994239389896,
-0.04030066356062889,
-0.022685080766677856,
-0.023870393633842468,
0.03763826936483383,
0.002032129094004631,
0.06156336888670921,
0.006086129695177078,
0.022083304822444916,
-0.001364250434562564,
-0.022138012573122978,
0.052336156368255615,
0.019694441929459572,
0.032295238226652145,
-0.04537016153335571,
0.007854982279241085,
0.02815575897693634,
-0.010020459070801735,
0.07013409584760666,
-0.027517512440681458,
-0.0656481385231018,
0.05018435791134834,
-0.024417461827397346,
-0.028210464864969254,
0.02837458625435829,
0.0593750961124897,
0.0036972668021917343,
0.011989903636276722,
-0.009409567341208458,
0.04507838934659958,
-0.004969199653714895,
0.05492561310529709,
-0.015172014944255352,
0.058317434042692184,
0.0328240692615509,
0.022849200293421745,
-0.04394778236746788,
0.050002001225948334,
0.0605057030916214,
-0.03685413673520088,
-0.0025666600558906794,
-0.06331398338079453,
-0.019001489505171776,
0.011907843872904778,
0.0017209842335432768,
0.10321346670389175,
0.07994484901428223,
-0.052737340331077576,
0.01798941381275654,
-0.005064936354756355,
0.05689505487680435,
0.03550470247864723,
0.013767873868346214,
-0.01617497205734253,
0.014460827223956585,
0.023432739078998566,
0.005575533024966717,
0.02160917967557907,
-0.028046345338225365,
0.03426468372344971,
-0.03413703292608261,
-0.04529721662402153,
-0.035012342035770416,
-0.005420530680567026,
-0.015445549041032791,
0.02177330106496811,
-0.057551536709070206,
-0.02624102123081684,
0.0302528515458107,
0.007257767021656036,
0.07775657624006271,
-0.006414370611310005,
-0.035760000348091125,
0.04285364970564842,
-0.008128516376018524,
0.0266422051936388,
0.009104120545089245,
-0.0420512817800045,
-0.05518091097474098,
-0.04015478119254112,
-0.021700358018279076,
0.008848822675645351,
-0.023232148960232735,
-0.011798430234193802,
0.0310369823127985,
-0.01709587126970291,
0.004344630520790815,
-0.03566882386803627,
-0.031930528581142426,
-0.01641203463077545,
-0.002965563675388694,
-0.043473657220602036,
-0.027262214571237564,
0.03380879387259483,
-0.009482509456574917,
-0.03435586020350456,
-0.008803233504295349,
-0.012081081978976727,
-0.04785020276904106,
-0.07943425327539444,
0.07571419328451157,
-0.04168657213449478,
0.04022772237658501,
-0.04471367970108986,
0.02352391742169857,
-0.03917005658149719,
-0.023469211533665657,
-0.012445793487131596,
0.002958725206553936,
0.07578713446855545,
-0.04573487117886543,
-0.005511708557605743,
0.00464779743924737,
0.045625459402799606,
0.03234994411468506,
-0.0427442342042923,
-0.06382457911968231,
-0.01473436038941145,
-0.025311006233096123,
-0.028666354715824127,
0.05364912003278732,
-0.01617497205734253,
0.054670315235853195,
-0.027681633830070496,
-0.01756087876856327,
-0.001625247416086495,
0.00906309112906456,
0.043874841183423996,
0.02718927152454853,
-0.02850223518908024,
-0.011789312586188316,
0.007244090083986521,
-0.011707251891493797,
-0.02084328606724739,
0.03785709664225578,
0.09212622791528702,
0.0018600306939333677,
-0.0007214457145892084,
0.049673762172460556,
-0.04938198998570442,
-0.01929325982928276,
0.00603142287582159,
0.028283407911658287,
-0.055035024881362915,
-0.02640514075756073,
-0.003820357145741582,
-0.013093157671391964,
0.0269886814057827,
0.0016867925878614187,
0.004109847359359264,
0.00184521428309381,
-0.041139502078294754,
0.023596860468387604,
0.009965752251446247,
-0.019037961959838867,
0.026277491822838783,
-0.012126671150326729,
-0.033279962837696075,
0.0032413769513368607,
0.013239041902124882,
-0.01341228000819683,
-0.0161293838173151,
0.013065803796052933,
0.016630861908197403,
-0.015099072828888893,
-0.065903440117836,
0.029796961694955826,
0.031310517340898514,
-0.0023250384256243706,
-0.011224009096622467,
-0.007435563951730728,
0.011515778489410877,
0.006546578835695982,
0.07812128961086273,
-0.03603353723883629,
-0.008716613985598087,
-0.010020459070801735,
0.0505855418741703,
-0.0129290372133255,
-0.07979896664619446,
0.02102564089000225,
0.025712188333272934,
0.0033735851757228374,
0.021317411214113235,
0.0070845284499228,
-0.05882802978157997,
0.06524696201086044,
0.025365712121129036,
0.058718614280223846,
0.013740520924329758,
0.02489158697426319,
0.020752107724547386,
-0.044057197868824005,
0.014488180167973042,
0.061782196164131165,
0.039060644805431366,
-0.04084773361682892,
0.00728512043133378,
-0.018819134682416916,
0.05860920250415802,
0.06221985071897507,
-0.019202081486582756,
-0.02797340229153633,
0.007175706792622805,
0.012071964330971241,
0.008424844592809677,
-0.020296217873692513,
0.018837369978427887,
0.037711210548877716,
0.0031638757791370153,
-0.050038471817970276,
-0.07483888417482376,
-0.00048096381942741573,
-0.016722040250897408,
0.061417482793331146,
-0.010485467500984669,
0.010339582338929176,
-0.007535859476774931,
-0.0072486489079892635,
-0.0357782356441021,
-0.04639135301113129,
-0.03369937837123871,
-0.022867435589432716,
0.016184089705348015,
-0.050439655780792236,
0.03997242450714111,
-0.047339603304862976,
-0.0059083327651023865,
0.01780705899000168,
0.01591055653989315,
0.05051259696483612,
-0.02678808942437172,
0.00007027114770608023,
0.025584539398550987,
0.06871172040700912,
0.04930904880166054,
0.016667334362864494,
0.001194431446492672,
-0.06838348507881165,
0.027663398534059525,
0.0156917292624712,
-0.009683101437985897,
-0.010348699986934662,
-0.03105521760880947,
-0.015819378197193146,
-0.03523116931319237,
0.01574643701314926,
-0.001781389699317515,
0.029213422909379005,
0.0008690400863997638,
0.01233637984842062
]
|
33,044 | bqplot.figure | Figure | Main canvas for drawing a chart.
The Figure object holds the list of Marks and Axes. It also holds an
optional Interaction object that is responsible for figure-level mouse
interactions, the "interaction layer".
Besides, the Figure object has two reference scales, for positioning items
in an absolute fashion in the figure canvas.
Attributes
----------
title: string (default: '')
title of the figure
axes: List of Axes (default: [])
list containing the instances of the axes for the figure
marks: List of Marks (default: [])
list containing the marks which are to be appended to the figure
interaction: Interaction or None (default: None)
optional interaction layer for the figure
scale_x: Scale
Scale representing the x values of the figure
scale_y: Scale
Scale representing the y values of the figure
padding_x: Float (default: 0.0)
Padding to be applied in the horizontal direction of the figure
around the data points, proportion of the horizontal length
padding_y: Float (default: 0.025)
Padding to be applied in the vertical direction of the figure
around the data points, proportion of the vertical length
legend_location: {'top-right', 'top', 'top-left', 'left',
'bottom-left', 'bottom', 'bottom-right', 'right'}
location of the legend relative to the center of the figure
background_style: Dict (default: {})
CSS style to be applied to the background of the figure
legend_style: Dict (default: {})
CSS style to be applied to the SVG legend e.g, {'fill': 'white'}
legend_text: Dict (default: {})
CSS style to be applied to the legend text e.g., {'font-size': 20}
title_style: Dict (default: {})
CSS style to be applied to the title of the figure
animation_duration: nonnegative int (default: 0)
Duration of transition on change of data attributes, in milliseconds.
pixel_ratio:
Pixel ratio of the WebGL canvas (2 on retina screens). Set to 1 for better performance,
but less crisp edges. If set to None it will use the browser's window.devicePixelRatio.
Layout Attributes
fig_margin: dict (default: {top=60, bottom=60, left=60, right=60})
Dictionary containing the top, bottom, left and right margins. The user
is responsible for making sure that the width and height are greater
than the sum of the margins.
min_aspect_ratio: float
minimum width / height ratio of the figure
max_aspect_ratio: float
maximum width / height ratio of the figure
Methods
-------
save_png:
Saves the figure as a PNG file
save_svg:
Saves the figure as an SVG file
Note
----
The aspect ratios stand for width / height ratios.
- If the available space is within bounds in terms of min and max aspect
ratio, we use the entire available space.
- If the available space is too oblong horizontally, we use the client
height and the width that corresponds max_aspect_ratio (maximize width
under the constraints).
- If the available space is too oblong vertically, we use the client width
and the height that corresponds to min_aspect_ratio (maximize height
under the constraint).
This corresponds to maximizing the area under the constraints.
Default min and max aspect ratio are both equal to 16 / 9.
| class Figure(DOMWidget):
"""Main canvas for drawing a chart.
The Figure object holds the list of Marks and Axes. It also holds an
optional Interaction object that is responsible for figure-level mouse
interactions, the "interaction layer".
Besides, the Figure object has two reference scales, for positioning items
in an absolute fashion in the figure canvas.
Attributes
----------
title: string (default: '')
title of the figure
axes: List of Axes (default: [])
list containing the instances of the axes for the figure
marks: List of Marks (default: [])
list containing the marks which are to be appended to the figure
interaction: Interaction or None (default: None)
optional interaction layer for the figure
scale_x: Scale
Scale representing the x values of the figure
scale_y: Scale
Scale representing the y values of the figure
padding_x: Float (default: 0.0)
Padding to be applied in the horizontal direction of the figure
around the data points, proportion of the horizontal length
padding_y: Float (default: 0.025)
Padding to be applied in the vertical direction of the figure
around the data points, proportion of the vertical length
legend_location: {'top-right', 'top', 'top-left', 'left',
'bottom-left', 'bottom', 'bottom-right', 'right'}
location of the legend relative to the center of the figure
background_style: Dict (default: {})
CSS style to be applied to the background of the figure
legend_style: Dict (default: {})
CSS style to be applied to the SVG legend e.g, {'fill': 'white'}
legend_text: Dict (default: {})
CSS style to be applied to the legend text e.g., {'font-size': 20}
title_style: Dict (default: {})
CSS style to be applied to the title of the figure
animation_duration: nonnegative int (default: 0)
Duration of transition on change of data attributes, in milliseconds.
pixel_ratio:
Pixel ratio of the WebGL canvas (2 on retina screens). Set to 1 for better performance,
but less crisp edges. If set to None it will use the browser's window.devicePixelRatio.
Layout Attributes
fig_margin: dict (default: {top=60, bottom=60, left=60, right=60})
Dictionary containing the top, bottom, left and right margins. The user
is responsible for making sure that the width and height are greater
than the sum of the margins.
min_aspect_ratio: float
minimum width / height ratio of the figure
max_aspect_ratio: float
maximum width / height ratio of the figure
Methods
-------
save_png:
Saves the figure as a PNG file
save_svg:
Saves the figure as an SVG file
Note
----
The aspect ratios stand for width / height ratios.
- If the available space is within bounds in terms of min and max aspect
ratio, we use the entire available space.
- If the available space is too oblong horizontally, we use the client
height and the width that corresponds max_aspect_ratio (maximize width
under the constraints).
- If the available space is too oblong vertically, we use the client width
and the height that corresponds to min_aspect_ratio (maximize height
under the constraint).
This corresponds to maximizing the area under the constraints.
Default min and max aspect ratio are both equal to 16 / 9.
"""
title = Unicode().tag(sync=True, display_name='Title')
axes = List(Instance(Axis)).tag(sync=True, **widget_serialization)
marks = List(Instance(Mark)).tag(sync=True, **widget_serialization)
interaction = Instance(Interaction, default_value=None,
allow_none=True).tag(sync=True,
**widget_serialization)
scale_x = Instance(Scale).tag(sync=True, **widget_serialization)
scale_y = Instance(Scale).tag(sync=True, **widget_serialization)
title_style = Dict(value_trait=Unicode()).tag(sync=True)
background_style = Dict().tag(sync=True)
legend_style = Dict().tag(sync=True)
legend_text = Dict().tag(sync=True)
theme = Enum(['classic', 'gg'], default_value='classic').tag(sync=True)
min_aspect_ratio = Float(0.01).tag(sync=True)
max_aspect_ratio = Float(100).tag(sync=True)
pixel_ratio = Float(None, allow_none=True).tag(sync=True)
fig_margin = Dict(dict(top=60, bottom=60, left=60, right=60))\
.tag(sync=True)
padding_x = Float(0.0, min=0.0, max=1.0).tag(sync=True)
padding_y = Float(0.025, min=0.0, max=1.0).tag(sync=True)
legend_location = Enum(['top-right', 'top', 'top-left', 'left',
'bottom-left', 'bottom', 'bottom-right', 'right'],
default_value='top-right')\
.tag(sync=True, display_name='Legend position')
animation_duration = Int().tag(sync=True,
display_name='Animation duration')
def __init__(self, **kwargs):
super(Figure, self).__init__(**kwargs)
self._upload_png_callback = None
self.on_msg(self._handle_custom_msgs)
@default('scale_x')
def _default_scale_x(self):
return LinearScale(min=0, max=1, allow_padding=False)
@default('scale_y')
def _default_scale_y(self):
return LinearScale(min=0, max=1, allow_padding=False)
def save_png(self, filename='bqplot.png', scale=None):
'''
Saves the Figure as a PNG file
Parameters
----------
filename: str (default: 'bqplot.png')
name of the saved file
scale: float (default: None)
Scale up the png resolution when scale > 1, when not given base this on the screen pixel ratio.
'''
self.send({'type': 'save_png', 'filename': filename, 'scale': scale})
def save_svg(self, filename='bqplot.svg'):
'''
Saves the Figure as an SVG file
Parameters
----------
filename: str (default: 'bqplot.svg')
name of the saved file
'''
self.send({"type": "save_svg", "filename": filename})
def get_png_data(self, callback, scale=None):
'''
Gets the Figure as a PNG memory view
Parameters
----------
callback: callable
Called with the PNG data as the only positional argument.
scale: float (default: None)
Scale up the png resolution when scale > 1, when not given base this on the screen pixel ratio.
'''
if self._upload_png_callback:
raise Exception('get_png_data already in progress')
self._upload_png_callback = callback
self.send({'type': 'upload_png', 'scale': scale})
@validate('min_aspect_ratio', 'max_aspect_ratio')
def _validate_aspect_ratio(self, proposal):
value = proposal['value']
if proposal['trait'].name == 'min_aspect_ratio' and \
value > self.max_aspect_ratio:
raise TraitError('setting min_aspect_ratio > max_aspect_ratio')
if proposal['trait'].name == 'max_aspect_ratio' and \
value < self.min_aspect_ratio:
raise TraitError('setting max_aspect_ratio < min_aspect_ratio')
return value
def _handle_custom_msgs(self, _, content, buffers=None):
if content.get('event') == 'upload_png':
try:
self._upload_png_callback(buffers[0])
finally:
self._upload_png_callback = None
_view_name = Unicode('Figure').tag(sync=True)
_model_name = Unicode('FigureModel').tag(sync=True)
_view_module = Unicode('bqplot').tag(sync=True)
_model_module = Unicode('bqplot').tag(sync=True)
_view_module_version = Unicode(__frontend_version__).tag(sync=True)
_model_module_version = Unicode(__frontend_version__).tag(sync=True)
| (**kwargs) | [
0.04507826268672943,
-0.07227221131324768,
-0.0555720254778862,
0.03911682590842247,
-0.04422079399228096,
0.023641588166356087,
-0.059981852769851685,
0.05226465314626694,
-0.049488089978694916,
0.005696030333638191,
0.03697315603494644,
0.035503216087818146,
0.0469156913459301,
0.01456672977656126,
-0.029358034953475,
0.006966918706893921,
0.021742912009358406,
-0.020426087081432343,
0.03397202491760254,
-0.007329300511628389,
-0.0073344046249985695,
-0.06300340592861176,
-0.013494896702468395,
0.007855009287595749,
0.00526219280436635,
0.01660831831395626,
-0.011882041580975056,
0.032257091253995895,
0.0031338375993072987,
0.021089604124426842,
-0.06814820319414139,
-0.048426464200019836,
0.007191493641585112,
0.006824007723480463,
0.014342155307531357,
-0.04638487845659256,
0.013239697553217411,
0.0004883861402049661,
-0.02558109723031521,
0.010126275941729546,
-0.005006994586437941,
0.006563705392181873,
0.10305935889482498,
-0.05900189280509949,
0.005203497130423784,
0.04560907557606697,
-0.04115841165184975,
0.092851422727108,
-0.039810966700315475,
-0.06316673010587692,
0.04205671325325966,
-0.037034403532743454,
-0.03640151396393776,
0.11481890827417374,
-0.03231833875179291,
0.07606956362724304,
0.029031381011009216,
0.0957913026213646,
0.03558487817645073,
-0.030787145718932152,
-0.019629867747426033,
0.03352287411689758,
0.02721436694264412,
-0.0640241950750351,
-0.03858601301908493,
0.007967296987771988,
0.027438942342996597,
-0.030685067176818848,
-0.03348204120993614,
-0.02032400853931904,
0.011841210536658764,
0.020150473341345787,
-0.002827599411830306,
0.01105519849807024,
0.012423062697052956,
-0.03983138129115105,
-0.002955198520794511,
0.014995463192462921,
-0.020283175632357597,
0.019670700654387474,
0.0077784499153494835,
0.02317202277481556,
0.005190737545490265,
-0.04981474578380585,
0.019885066896677017,
-0.03834102302789688,
0.03282873332500458,
0.07823365181684494,
-0.004259262699633837,
-0.04532325267791748,
-0.008365406654775143,
0.005070793908089399,
0.022559545934200287,
0.03205293044447899,
-0.023641588166356087,
-0.0603901706635952,
-0.045486580580472946,
-0.06900567561388016,
0.010065028443932533,
-0.006512665655463934,
-0.05177466943860054,
-0.0040397923439741135,
-0.03454366698861122,
-0.00000706281753082294,
-0.0013512760633602738,
-0.019976938143372536,
-0.01583251543343067,
-0.01594480127096176,
-0.042220037430524826,
0.019466541707515717,
0.010437618009746075,
0.009227977134287357,
-0.04560907557606697,
0.03932098299264908,
0.012157656252384186,
-0.009871077723801136,
-0.07149641215801239,
-0.030133837834000587,
0.04115841165184975,
-0.06773988902568817,
-0.08509338647127151,
0.038688089698553085,
-0.02027296833693981,
-0.004192911088466644,
0.011289981193840504,
0.03401285409927368,
0.03901474550366402,
0.04965141788125038,
-0.06994480639696121,
-0.04283251613378525,
0.013474480248987675,
-0.014791304245591164,
-0.012688469141721725,
0.040055956691503525,
0.019139887765049934,
-0.019048014655709267,
0.07406880706548691,
-0.0018846408929675817,
-0.06369754672050476,
0.05659281834959984,
0.013545935973525047,
-0.008222495205700397,
-0.011514555662870407,
0.034400757402181625,
-0.04213837534189224,
-0.01335198525339365,
-0.036279018968343735,
-0.061860114336013794,
-0.06537164747714996,
-0.03558487817645073,
-0.0013882798375561833,
0.022314555943012238,
-0.004124007653445005,
-0.018129300326108932,
0.04479243978857994,
-0.04605822265148163,
-0.006415690295398235,
-0.002855671104043722,
0.025764839723706245,
0.05520453676581383,
-0.0356052927672863,
-0.010110964067280293,
0.07594706863164902,
-0.014699432998895645,
0.006568809039890766,
0.04589489847421646,
0.03299206122756004,
-0.033277884125709534,
-0.01174933835864067,
0.09113648533821106,
-0.0006344872526824474,
-0.03405368700623512,
-0.03834102302789688,
0.024927789345383644,
-0.04826314002275467,
0.07513043284416199,
0.03889225050806999,
0.021763326600193977,
-0.0015375709626823664,
0.0005614366964437068,
0.01386238168925047,
-0.013760303147137165,
-0.012443478219211102,
0.047854822129011154,
-0.016802268102765083,
0.01592438668012619,
0.016577694565057755,
0.004889603238552809,
0.04340415820479393,
-0.014474858529865742,
0.013260114006698132,
0.039484310895204544,
-0.01442381925880909,
-0.03201209753751755,
0.020946692675352097,
-0.017333080992102623,
0.020354632288217545,
-0.06357505172491074,
0.053530436009168625,
-0.01063667330890894,
0.027969755232334137,
-0.04152590036392212,
0.03934140130877495,
-0.03907599300146103,
0.00006659085920546204,
-0.013852174393832684,
-0.016812477260828018,
0.026887713000178337,
-0.03262457624077797,
0.009707750752568245,
-0.04503742977976799,
-0.014280907809734344,
-0.04716068133711815,
-0.014342155307531357,
0.03911682590842247,
-0.05050888657569885,
-0.012106616050004959,
0.03903516009449959,
-0.060757655650377274,
0.002827599411830306,
0.028643479570746422,
0.026030246168375015,
-0.03268582373857498,
0.002748487750068307,
-0.011973912827670574,
-0.02774517983198166,
0.09080982953310013,
0.01757807284593582,
0.05749111622571945,
-0.09562797844409943,
0.012188280001282692,
0.00553780747577548,
0.016373535618185997,
0.020375046879053116,
-0.006849527359008789,
-0.013484688475728035,
0.0125659741461277,
0.01211682427674532,
-0.005496975500136614,
-0.012341398745775223,
0.0034451796673238277,
-0.004098488017916679,
-0.0028735350351780653,
0.03186918795108795,
-0.024172401055693626,
0.010228355415165424,
0.028765974566340446,
0.009222873486578465,
-0.011157277971506119,
-0.04589489847421646,
-0.030256332829594612,
-0.02666313946247101,
-0.043526653200387955,
0.003733553923666477,
0.029603024944663048,
-0.04373081400990486,
-0.04205671325325966,
-0.021089604124426842,
0.06773988902568817,
-0.030807562172412872,
0.0469156913459301,
-0.013137618079781532,
0.000982514233328402,
0.09938450157642365,
0.06651493161916733,
-0.016251040622591972,
-0.00786521751433611,
0.004032136406749487,
-0.06724990904331207,
0.0018221172504127026,
0.028500568121671677,
0.062390927225351334,
-0.01485255267471075,
-0.013933837413787842,
0.0013308601919561625,
-0.017322873696684837,
0.004948298912495375,
-0.012974291108548641,
0.01725141890347004,
0.0016753780655562878,
0.01667977310717106,
-0.06733156740665436,
0.016006048768758774,
0.05573534965515137,
-0.007758034393191338,
-0.04295501112937927,
0.0011101134587079287,
0.013719471171498299,
0.036789413541555405,
-0.025193195790052414,
-0.03470699489116669,
0.053285446017980576,
-0.02182457596063614,
-0.049773912876844406,
-0.039280153810977936,
-0.023580340668559074,
-0.013494896702468395,
0.027091871947050095,
-0.01924196630716324,
-0.0005036980146542192,
0.035768620669841766,
0.01884385757148266,
0.12053535133600235,
0.02590775117278099,
-0.012004537507891655,
0.005614366848021746,
0.05667448043823242,
-0.022192060947418213,
0.05936937779188156,
-0.011922873556613922,
0.017547449097037315,
0.0267039705067873,
0.03638109564781189,
0.05904272198677063,
-0.023417014628648758,
0.013586767949163914,
0.06145179644227028,
-0.05034555867314339,
0.03313497081398964,
0.0490797758102417,
-0.022314555943012238,
-0.026785634458065033,
-0.050835538655519485,
-0.058920226991176605,
0.06006351858377457,
-0.0452415905892849,
0.032236672937870026,
0.009161625988781452,
0.05197883024811745,
0.00188974488992244,
-0.03229792043566704,
0.015424196608364582,
-0.01972173899412155,
0.00188974488992244,
0.0017072779592126608,
-0.05079470947384834,
-0.03380869701504707,
-0.014076748862862587,
0.0014240075834095478,
-0.05928771570324898,
0.03907599300146103,
0.0005518667167052627,
-0.00531833665445447,
0.036524008959531784,
-0.022886201739311218,
0.005369376391172409,
0.0374223068356514,
-0.04320000112056732,
0.0030521738808602095,
-0.01254555769264698,
-0.01822117157280445,
0.010687712579965591,
-0.017241209745407104,
0.03431909158825874,
0.008998299017548561,
-0.012627221643924713,
0.013045746833086014,
-0.048916447907686234,
-0.051121361553668976,
0.01789451763033867,
0.03823894262313843,
-0.02262079529464245,
-0.06071682646870613,
0.04311833903193474,
-0.013158034533262253,
-0.029521360993385315,
0.010029301047325134,
-0.05099886655807495,
0.058920226991176605,
-0.017639320343732834,
0.05071304365992546,
0.003200189210474491,
-0.038422685116529465,
-0.02053837478160858,
0.007370132487267256,
0.015597731806337833,
0.002314650220796466,
0.04079092666506767,
-0.0028454631101340055,
-0.053775426000356674,
0.02186540700495243,
-0.01958903670310974,
-0.007880529388785362,
0.00404234416782856,
-0.014454443007707596,
-0.06067599356174469,
-0.006818903610110283,
0.003121077548712492,
-0.005951229017227888,
-0.025295274332165718,
0.033829111605882645,
-0.0517338402569294,
0.006966918706893921,
0.03258374333381653,
-0.061574291437864304,
-0.059491872787475586,
0.009452552534639835,
0.10330434888601303,
-0.01536294911056757,
-0.0036314744502305984,
-0.02449905499815941,
-0.053816258907318115,
-0.003164461348205805,
-0.0015681947115808725,
0.026091493666172028,
-0.012269943952560425,
0.027357278391718864,
0.05063138157129288,
0.034951984882354736,
0.051080528646707535,
0.023396598175168037,
-0.05361209809780121,
-0.07684537023305893,
0.003998960368335247,
0.008916635066270828,
-0.027071455493569374,
-0.021947070956230164,
-0.006017580628395081,
-0.014985255897045135,
0.0021385634317994118,
-0.04097466915845871,
0.10485595464706421,
0.05099886655807495,
0.03405368700623512,
0.010019092820584774,
-0.01952778920531273,
-0.03399243950843811,
0.03507447987794876,
-0.003549810964614153,
0.020813988521695137,
-0.003993856254965067,
0.03617693856358528,
-0.036238186061382294,
-0.020130056887865067,
-0.00251242914237082,
-0.00904423464089632,
-0.0067321364767849445,
-0.03417618200182915,
0.006517769303172827,
0.006997542455792427,
0.046425711363554,
-0.030052173882722855,
0.018966352567076683,
-0.0339311920106411,
0.0003585538943298161,
-0.019609451293945312,
-0.06594329327344894,
0.018119093030691147,
0.0076049151830375195,
-0.016618525609374046,
0.04711984843015671,
0.09644461423158646,
0.03582986816763878,
-0.005542911123484373,
-0.008043856360018253,
-0.05495954677462578,
-0.011198109947144985,
-0.08211266994476318,
0.017016636207699776,
-0.012749716639518738,
-0.00733950873836875,
-0.004851323552429676,
-0.05475538969039917,
-0.05479621887207031,
0.01240264717489481,
0.019517580047249794,
0.07378298789262772,
-0.02087523601949215,
-0.04503742977976799,
0.0017060019308701158,
0.08444007486104965,
-0.0060277883894741535,
0.0029398866463452578,
-0.03217542544007301,
0.030133837834000587,
-0.005277504678815603,
-0.014668809249997139,
0.016577694565057755,
-0.0502638965845108,
-0.027357278391718864,
0.03856559470295906,
-0.04560907557606697,
0.009580151177942753,
0.02394782565534115,
-0.033869944512844086,
0.034604914486408234,
0.045772403478622437,
-0.04344499111175537,
-0.008641021326184273,
0.020395463332533836,
-0.08113270252943039,
0.00015662806981708854,
-0.011085822246968746,
0.01211682427674532,
0.018017014488577843,
0.044874101877212524,
0.05749111622571945,
-0.021436672657728195,
-0.04324083402752876,
-0.08260264992713928,
-0.00018820888362824917,
-0.04124007746577263,
0.01239243894815445,
0.005726654082536697,
0.046425711363554,
-0.015444613061845303,
-0.023376181721687317,
0.041648395359516144,
-0.011432892642915249,
-0.02180415950715542,
-0.058389414101839066,
-0.017373913899064064,
0.04777315631508827,
-0.018476370722055435,
0.022171644493937492,
-0.013158034533262253,
-0.012678260914981365,
0.028214745223522186,
-0.01831304468214512,
-0.05679697543382645,
0.017731191590428352,
0.013423440977931023,
0.033788278698921204,
-0.041382987052202225,
0.003646786557510495,
0.042465027421712875,
-0.04124007746577263,
-0.005986956413835287,
0.037340644747018814,
-0.005813421681523323,
0.01565898023545742,
-0.010514178313314915,
0.04765066131949425,
0.03205293044447899,
-0.003983648493885994,
0.03454366698861122,
-0.006706616375595331,
-0.0237028356641531,
-0.024356143549084663,
-0.010973535478115082,
-0.02398865856230259,
0.02208998240530491,
-0.03538071736693382,
-0.026316069066524506,
0.024356143549084663,
0.007584499195218086,
0.07325217872858047,
0.006992438808083534,
0.04936559498310089,
-0.031705860048532486,
0.0237028356641531,
0.053775426000356674,
0.07035312056541443,
-0.03213459253311157,
-0.007268053013831377,
0.005343856289982796,
0.050835538655519485,
-0.012167864479124546,
0.030868809670209885,
-0.032522495836019516,
-0.029725519940257072,
0.00126450858078897,
-0.01577126607298851,
-0.03023591823875904,
-0.0006383152212947607,
0.036238186061382294,
0.012994707562029362,
0.046425711363554,
-0.00531833665445447,
-0.05067221447825432,
0.030276749283075333,
0.03323705121874809,
0.08317429572343826,
-0.0347682423889637,
-0.004029584117233753,
0.00350897922180593,
0.009768998250365257,
0.004180151503533125,
-0.05495954677462578,
-0.028684310615062714,
0.02239621989428997,
0.052142154425382614,
0.015689603984355927,
-0.027071455493569374,
0.0006233223248273134,
0.01573043502867222,
0.029480529949069023,
0.04401663690805435,
0.000356639880919829,
-0.018323251977562904,
-0.03262457624077797,
0.017833270132541656,
-0.01053459383547306,
-0.00833988655358553,
0.016638942062854767,
0.0469156913459301,
-0.010626465082168579,
-0.032747071236371994,
-0.006635160651057959,
0.018813233822584152,
-0.01387258991599083,
0.020885445177555084,
0.0027000000700354576,
0.0025787807535380125,
-0.008809451945126057,
0.0013142722891643643,
0.028418904170393944,
0.0018195653101429343,
-0.02639773301780224,
-0.0359523631632328,
0.0286230631172657,
0.02294744923710823,
0.018629489466547966,
-0.05912438780069351,
-0.010391682386398315,
-0.07762117683887482,
-0.05765444412827492,
0.07247637212276459,
0.045159924775362015,
0.05961436778306961,
0.034441590309143066,
0.026111910119652748,
-0.020681286230683327,
-0.017945557832717896,
-0.03938223049044609,
-0.05830775201320648,
0.027826843783259392,
-0.0647183358669281,
-0.03972930088639259,
0.02180415950715542,
0.046017393469810486,
-0.041668809950351715,
0.014699432998895645,
-0.10918412357568741,
0.07464045286178589,
0.013831757940351963,
-0.015138374641537666,
0.005818525794893503,
-0.019742155447602272,
0.008043856360018253,
0.061860114336013794,
-0.0116064278408885,
0.0023580340202897787,
-0.0036927221808582544,
0.04662986844778061,
0.037075236439704895,
0.00024642603239044547,
-0.016138752922415733,
0.024886956438422203,
0.007385444361716509,
-0.025458602234721184,
0.01879281736910343,
-0.023417014628648758,
-0.0381164476275444,
0.041342154145240784,
0.07312968373298645,
-0.03180794045329094,
-0.07415047287940979,
-0.025724008679389954,
0.008222495205700397,
-0.01869073696434498,
-0.0027969754301011562,
0.0022840264718979597,
0.04728317633271217,
0.007773346267640591,
-0.0447516068816185,
-0.014985255897045135,
0.03666691854596138,
0.013841966167092323,
-0.0010303639573976398,
-0.013433648273348808,
-0.013137618079781532,
-0.011790170334279537,
0.011994329281151295,
-0.013841966167092323,
0.002420557662844658,
0.0381164476275444,
0.011820794083178043,
-0.008253118954598904,
-0.011943289078772068,
0.015189413912594318,
0.056225333362817764,
-0.08664499223232269,
0.025683175772428513,
0.02564234472811222,
-0.025193195790052414,
0.04348582401871681,
-0.022967863827943802,
-0.0015286389971151948,
0.015424196608364582,
0.0066045369021594524,
0.014975047670304775,
0.03131796047091484,
-0.02807183377444744,
0.020170889794826508,
-0.08092854917049408,
-0.05157051235437393,
-0.01729224994778633,
0.04364915192127228,
-0.04969225078821182,
0.050059735774993896,
-0.04589489847421646,
-0.02995009534060955,
0.050590548664331436,
0.025295274332165718,
0.028663894161581993,
-0.062431760132312775,
0.002544329036027193,
0.016159169375896454,
-0.04226087033748627,
-0.0011190454242751002,
0.05177466943860054,
0.04503742977976799,
-0.006415690295398235,
-0.0036952742375433445,
-0.030419660732150078,
-0.01844574697315693,
0.028704727068543434,
-0.019670700654387474,
-0.001605198485776782,
-0.04585406556725502,
0.02968468889594078,
0.03297164663672447,
-0.012024953030049801,
0.012188280001282692,
0.058961059898138046,
0.015005671419203281,
-0.05418374389410019,
0.013831757940351963,
-0.03125671297311783,
-0.023253686726093292,
0.029725519940257072,
-0.04560907557606697,
0.025479016825556755,
-0.024927789345383644,
-0.019497165456414223,
0.035993196070194244,
-0.026540642604231834,
-0.05691947042942047,
0.014362570829689503,
0.017465785145759583,
-0.08194933831691742,
-0.05152967944741249,
-0.013423440977931023,
0.020813988521695137,
0.007982608862221241,
-0.0005123110022395849,
0.035441964864730835,
-0.002751039806753397,
0.03580945357680321,
0.0517338402569294,
0.040566351264715195,
-0.05201965942978859,
0.06116597354412079,
0.04124007746577263,
-0.035503216087818146,
0.07104726135730743,
0.010932703502476215,
0.03876975551247597,
-0.05446956679224968,
-0.011208318173885345,
0.001606474514119327,
0.014005293138325214,
0.0024639414623379707,
0.04262835532426834,
0.050059735774993896,
-0.034604914486408234,
0.029888847842812538
]
|
33,049 | bqplot.figure | __init__ | null | def __init__(self, **kwargs):
super(Figure, self).__init__(**kwargs)
self._upload_png_callback = None
self.on_msg(self._handle_custom_msgs)
| (self, **kwargs) | [
-0.027717851102352142,
-0.0747835710644722,
-0.01925976574420929,
0.07950600236654282,
-0.04123316705226898,
0.03548871725797653,
-0.024986594915390015,
0.09599927067756653,
0.028739869594573975,
0.023929333314299583,
0.06710081547498703,
0.06371758133172989,
0.029198016971349716,
-0.021162835881114006,
-0.04028163477778435,
0.02792930416762829,
0.017206918448209763,
-0.006977920886129141,
0.009673935361206532,
-0.015250985510647297,
-0.029039427638053894,
-0.0008089145994745195,
-0.0009763141861185431,
0.017515286803245544,
0.024387480691075325,
0.0864839255809784,
-0.0431009940803051,
-0.0014339098706841469,
-0.0065462058410048485,
-0.012845717370510101,
-0.05585860833525658,
-0.01791175827383995,
0.03964727744460106,
0.0628717690706253,
-0.010202566161751747,
-0.0028700223192572594,
-0.02042275294661522,
0.016625424847006798,
-0.0915587767958641,
0.040563568472862244,
0.03184117004275322,
-0.02350642904639244,
0.03064293973147869,
-0.013673905283212662,
0.02407030202448368,
0.04722431302070618,
-0.013074791058897972,
0.04183228313922882,
-0.0071321045979857445,
-0.06502153724431992,
-0.042678091675043106,
-0.012308277189731598,
-0.035277266055345535,
0.08810506016016006,
-0.04179704189300537,
0.09057199954986572,
0.0401054248213768,
0.06378806382417679,
0.0008204783662222326,
0.04197325184941292,
-0.0488806888461113,
0.03964727744460106,
0.041691314429044724,
-0.04362962394952774,
-0.014334693551063538,
-0.03376185894012451,
0.024316996335983276,
0.008775264024734497,
-0.035576824098825455,
0.0029272905085235834,
0.07020211219787598,
0.021867675706744194,
-0.021568119525909424,
0.034748636186122894,
0.05039609596133232,
-0.025215668603777885,
-0.020246542990207672,
0.04229043051600456,
0.0007753245299682021,
0.05282779410481453,
0.04666043817996979,
0.031594473868608475,
-0.035277266055345535,
-0.008828126825392246,
0.033620890229940414,
-0.0802108496427536,
0.023453567177057266,
0.010722385719418526,
-0.021074730902910233,
0.011013132520020008,
-0.030537214130163193,
0.017524097114801407,
0.0052774930372834206,
-0.01899545080959797,
-0.014924997463822365,
-0.03619355708360672,
-0.029233258217573166,
-0.01047569140791893,
0.030519593507051468,
0.00025151242152787745,
-0.04091598838567734,
-0.022660620510578156,
-0.011286257766187191,
-0.04313623905181885,
0.041092198342084885,
-0.05920660123229027,
0.009400810115039349,
-0.04923310875892639,
-0.044545918703079224,
0.016916170716285706,
0.05226392298936844,
-0.01622014120221138,
-0.04778818413615227,
0.08303020894527435,
-0.015048344619572163,
-0.0022004239726811647,
-0.04183228313922882,
-0.04070453718304634,
0.033885207027196884,
-0.03707461059093475,
-0.07309195399284363,
0.03457242622971535,
-0.020369889214634895,
0.002995572052896023,
-0.027664989233016968,
0.023894092068076134,
0.03383234143257141,
0.012739991769194603,
-0.00004587657895172015,
-0.0745721235871315,
0.034942466765642166,
-0.006735631730407476,
-0.03356802836060524,
-0.006105680484324694,
-0.026854421943426132,
-0.011365552432835102,
0.06477484107017517,
-0.016008689999580383,
-0.007409635465592146,
0.009339136071503162,
0.008105665445327759,
0.024228891357779503,
-0.004319350700825453,
0.005092472303658724,
0.0034977709874510765,
0.0518762581050396,
-0.011339121498167515,
-0.042748574167490005,
-0.006110086105763912,
-0.029973341152071953,
0.007502146065235138,
0.00453300541266799,
0.0023215683177113533,
0.0038149491883814335,
0.03777945041656494,
-0.034378595650196075,
-0.0023193657398223877,
0.011947046034038067,
0.004077061545103788,
0.06047531217336655,
0.019048314541578293,
0.011700351722538471,
0.04817584529519081,
-0.022731104865670204,
-0.00884134229272604,
0.030167171731591225,
0.029867615550756454,
-0.049092140048742294,
-0.007665140088647604,
0.0745016410946846,
0.01832585223019123,
-0.052440132945775986,
-0.035946864634752274,
0.006911842152476311,
-0.019347870722413063,
0.06963823735713959,
0.011347931809723377,
0.023964576423168182,
-0.03968251869082451,
0.006237838417291641,
0.014572576619684696,
0.014801650308072567,
-0.006127706728875637,
0.020792793482542038,
0.0015121031319722533,
0.021374287083745003,
0.03954154998064041,
0.020105574280023575,
0.0014273020206019282,
-0.025656193494796753,
0.03462528809905052,
0.04306575283408165,
-0.03265173360705376,
-0.015233364887535572,
0.07323292642831802,
0.003737857099622488,
0.021356666460633278,
-0.0485987514257431,
0.016317056491971016,
0.005484540015459061,
0.03464290872216225,
-0.01075762789696455,
-0.005577050149440765,
-0.020405132323503494,
-0.002042936161160469,
0.023559292778372765,
0.027471156790852547,
0.07080122828483582,
-0.025656193494796753,
-0.01859016716480255,
-0.0329689122736454,
-0.011779646389186382,
-0.020475616678595543,
0.005396435037255287,
0.04077502340078354,
-0.04570890590548515,
-0.04747100546956062,
0.04186752438545227,
-0.03636976704001427,
0.021691465750336647,
0.0517352893948555,
0.07122413069009781,
-0.05726828798651695,
-0.0011260927421972156,
-0.01896020956337452,
0.04468688741326332,
0.07774390280246735,
-0.025409499183297157,
0.033180367201566696,
-0.050854239612817764,
-0.04465164244174957,
0.02125094085931778,
-0.009947061538696289,
0.030960118398070335,
-0.013136464171111584,
0.03457242622971535,
0.032951291650533676,
-0.017673874273896217,
-0.08176149427890778,
-0.007352367043495178,
0.033215608447790146,
-0.011832509189844131,
0.008079233579337597,
-0.007277477998286486,
0.026255307719111443,
-0.03555920347571373,
0.007158535998314619,
0.03464290872216225,
-0.013488885015249252,
0.03844904899597168,
0.016458025202155113,
-0.030995359644293785,
-0.04662519693374634,
0.011532952077686787,
-0.008854558691382408,
-0.0543079599738121,
-0.017603391781449318,
-0.06258983165025711,
0.04701285809278488,
0.021092351526021957,
0.00608365423977375,
0.027048252522945404,
0.012123255990445614,
0.09973492473363876,
0.0050087724812328815,
-0.03686315566301346,
-0.022237716242671013,
-0.001901968033052981,
-0.059981923550367355,
-0.003156363731250167,
0.11418415606021881,
0.024228891357779503,
0.024334616959095,
-0.009991114027798176,
-0.023347841575741768,
-0.0684400126338005,
-0.04768245667219162,
-0.02088089846074581,
0.005695992149412632,
0.011427226476371288,
0.08880989998579025,
-0.02429937571287155,
0.024757521227002144,
0.05836079269647598,
-0.004515384323894978,
-0.03409665822982788,
0.03347992151975632,
0.039294857531785965,
-0.03841380774974823,
-0.08986715972423553,
-0.02380598708987236,
0.04246664047241211,
0.0019559322390705347,
0.03658122196793556,
-0.011101237498223782,
-0.05384981259703636,
-0.045074548572301865,
0.07689809799194336,
0.01250210776925087,
0.019365491345524788,
0.02898656390607357,
-0.022431548684835434,
0.032686978578567505,
0.0077664609998464584,
-0.0001952077727764845,
-0.020475616678595543,
0.011559383943676949,
0.006986731197685003,
-0.00029349999385885894,
-0.042149461805820465,
0.036545976996421814,
0.038096629083156586,
-0.0008854558691382408,
0.030096689239144325,
-0.027206841856241226,
0.04070453718304634,
0.07851923257112503,
-0.03788517415523529,
0.02965616248548031,
0.05469562113285065,
-0.009700367227196693,
-0.05099520832300186,
-0.06368234008550644,
-0.0005792907904833555,
0.030889634042978287,
-0.02234344370663166,
-0.0007114483742043376,
0.021991023793816566,
0.010140892118215561,
0.03344468027353287,
-0.027576884254813194,
0.011947046034038067,
0.013162896037101746,
-0.08479230850934982,
-0.06801710277795792,
-0.04743576422333717,
-0.035753034055233,
-0.015365522354841232,
-0.0011376566253602505,
-0.06963823735713959,
-0.021832434460520744,
-0.016792824491858482,
-0.011286257766187191,
0.06040482968091965,
-0.021691465750336647,
0.023294977843761444,
0.01985887996852398,
-0.08274827152490616,
0.05177053436636925,
-0.039294857531785965,
-0.0187663771212101,
-0.0215152557939291,
-0.023964576423168182,
0.032193589955568314,
0.03837856277823448,
0.008255444467067719,
-0.023946955800056458,
-0.029444711282849312,
-0.0036211179103702307,
-0.018220126628875732,
0.05691586807370186,
-0.01236995030194521,
-0.01244924496859312,
-0.012334708124399185,
-0.0009096847497858107,
0.021462392061948776,
0.022766347974538803,
-0.01813202165067196,
0.02872224897146225,
-0.004933883436024189,
0.011550573632121086,
-0.02144477143883705,
-0.05561191216111183,
0.0186606515198946,
0.008810506202280521,
-0.028334587812423706,
-0.038766227662563324,
0.04757673293352127,
0.013339105993509293,
-0.002317163161933422,
-0.0047532678581774235,
0.010731196030974388,
-0.023594535887241364,
-0.01273118145763874,
-0.024722279980778694,
-0.014369934797286987,
-0.065796859562397,
0.05504804104566574,
0.05409650504589081,
-0.012528539635241032,
0.017321454361081123,
-0.03883671015501022,
-0.017356697469949722,
-0.023999817669391632,
-0.017621012404561043,
-0.07640470564365387,
0.0214095301926136,
0.04433446750044823,
0.008942663669586182,
-0.013506505638360977,
-0.013189327903091908,
-0.04803488031029701,
-0.03536536917090416,
-0.009409620426595211,
0.06258983165025711,
0.04778818413615227,
-0.020669447258114815,
0.05099520832300186,
0.033620890229940414,
0.0025990991853177547,
0.04997318983078003,
-0.017806032672524452,
-0.05677489936351776,
-0.029303742572665215,
0.007629898376762867,
-0.03397331014275551,
-0.02489848993718624,
-0.044475432485342026,
-0.02158574014902115,
-0.019048314541578293,
-0.04458115994930267,
0.10960269719362259,
0.04997318983078003,
-0.00040913786506280303,
0.024052681401371956,
0.020792793482542038,
-0.0064316694624722,
0.0007301706937141716,
0.03848429024219513,
0.01978839561343193,
-0.04986746236681938,
0.07379680126905441,
-0.05293352156877518,
0.027876440435647964,
0.01952408067882061,
0.03950630873441696,
-0.0186606515198946,
-0.032352179288864136,
-0.03064293973147869,
0.02019367925822735,
0.002601301996037364,
-0.0016618816880509257,
0.042219944298267365,
-0.03270459920167923,
0.043841078877449036,
-0.02068706788122654,
-0.06332992017269135,
0.027347810566425323,
-0.018519682809710503,
-0.0287927333265543,
0.004030806478112936,
0.08415795117616653,
0.024264132604002953,
0.0029272905085235834,
0.002477954840287566,
-0.03157685324549675,
-0.05011415854096413,
-0.022290579974651337,
0.02500421553850174,
-0.05399078130722046,
-0.050184641033411026,
-0.009629882872104645,
-0.10847494751214981,
-0.06505677849054337,
0.03529488667845726,
0.0022951369173824787,
0.06505677849054337,
-0.011700351722538471,
-0.06424620747566223,
-0.006400832440704107,
0.07661616057157516,
0.010986700654029846,
-0.003132134908810258,
-0.019083555787801743,
0.0065462058410048485,
-0.01903069205582142,
0.012669507414102554,
-0.003601294243708253,
-0.03138302266597748,
-0.021339045837521553,
0.02489848993718624,
-0.026942526921629906,
0.00006742101686540991,
-0.007466903887689114,
-0.04292478412389755,
-0.001958135049790144,
-0.005044014658778906,
-0.05681014433503151,
0.024828005582094193,
-0.005947091616690159,
-0.052017226815223694,
0.023559292778372765,
-0.036968883126974106,
0.035682547837495804,
0.032916050404310226,
0.025620952248573303,
0.010396396741271019,
-0.0003895895497407764,
0.015524111688137054,
-0.047999635338783264,
-0.01918928138911724,
-0.005907444283366203,
-0.008220202289521694,
-0.0003895895497407764,
0.015894152224063873,
-0.04761197417974472,
-0.013999894261360168,
0.04285430163145065,
-0.00948010478168726,
-0.007713598199188709,
-0.004394239746034145,
0.006555016618221998,
0.010502123273909092,
-0.016660666093230247,
0.01899545080959797,
-0.032792702317237854,
-0.016079172492027283,
0.031629715114831924,
-0.03788517415523529,
-0.02925088070333004,
0.04370011016726494,
-0.0026629753410816193,
0.03799090161919594,
-0.008061612956225872,
0.014008704572916031,
-0.003676183521747589,
-0.00878847949206829,
0.021955780684947968,
0.022995419800281525,
0.029832372441887856,
0.02440510131418705,
-0.03314512223005295,
0.010880975052714348,
0.015286227688193321,
-0.008775264024734497,
0.06829904019832611,
-0.031559232622385025,
0.0019151837332174182,
-0.07203469425439835,
-0.015779616311192513,
-0.025885267183184624,
0.004999962169677019,
-0.0047180261462926865,
-0.028017409145832062,
-0.023259736597537994,
-0.02058134227991104,
0.02391171269118786,
0.031136328354477882,
0.06604355573654175,
-0.01832585223019123,
0.04091598838567734,
-0.01829061098396778,
0.009541777893900871,
-0.008387601934373379,
-0.015594596043229103,
0.01727740280330181,
0.034713394939899445,
-0.06551492214202881,
0.031101085245609283,
-0.0331098809838295,
-0.066219761967659,
0.05409650504589081,
-0.01475759781897068,
0.016387540847063065,
-0.041515104472637177,
-0.0001595527573954314,
0.01794700138270855,
0.05955902114510536,
-0.04130365327000618,
-0.039823487401008606,
0.02324211411178112,
0.021497635170817375,
0.00948010478168726,
-0.03462528809905052,
-0.024457965046167374,
0.0071321045979857445,
0.05917135998606682,
0.02128618210554123,
-0.040528327226638794,
-0.021162835881114006,
0.0027753093745559454,
0.006374401040375233,
0.0037819095887243748,
-0.011541762389242649,
-0.07802584022283554,
-0.010132081806659698,
0.023700261488556862,
-0.029109911993145943,
-0.02105710841715336,
0.010722385719418526,
0.0015076978597790003,
-0.010581417940557003,
0.0014074783539399505,
0.00040748590254224837,
-0.01135674212127924,
-0.0011552775977179408,
0.03201737999916077,
-0.03629928454756737,
-0.019682670012116432,
-0.0025198047515004873,
0.0004664061707444489,
0.028634143993258476,
-0.028598902747035027,
0.01229946594685316,
-0.01756814867258072,
-0.03894243761897087,
-0.01809677854180336,
0.04532124102115631,
-0.03457242622971535,
0.035841137170791626,
0.0000617767873336561,
0.0430305115878582,
0.032792702317237854,
0.017744358628988266,
0.010713575407862663,
-0.04666043817996979,
-0.01629062555730343,
0.018114401027560234,
0.060616280883550644,
0.07760293781757355,
0.0023061500396579504,
-0.005585860926657915,
-0.04063405469059944,
0.021867675706744194,
-0.01727740280330181,
-0.07266905158758163,
0.04229043051600456,
-0.09071297198534012,
-0.06660742312669754,
0.016132036224007607,
0.028704628348350525,
-0.015330280177295208,
0.016458025202155113,
-0.09466007351875305,
0.06777041405439377,
-0.01941835507750511,
-0.054766103625297546,
-0.006286296062171459,
-0.026872042566537857,
-0.044510677456855774,
0.01843157783150673,
-0.02380598708987236,
-0.008506543934345245,
-0.07668664306402206,
0.022202474996447563,
0.02992047742009163,
-0.03658122196793556,
-0.020281784236431122,
0.011885372921824455,
0.00540524534881115,
0.0014250993262976408,
0.020334647968411446,
-0.013902978040277958,
0.061779268085956573,
0.017999863252043724,
0.061144910752773285,
-0.0023435945622622967,
-0.00629070121794939,
0.027946924790740013,
0.0028501986525952816,
-0.06643121689558029,
0.0185549259185791,
0.034942466765642166,
0.09310942888259888,
-0.008510949090123177,
-0.045603178441524506,
0.022202474996447563,
-0.007440472487360239,
-0.05342690646648407,
0.022836832329630852,
-0.014854513108730316,
0.002356810262426734,
-0.032422661781311035,
-0.005295114126056433,
0.04923310875892639,
-0.010660712607204914,
0.03335657715797424,
-0.022272959351539612,
0.04599083960056305,
0.03397331014275551,
-0.013110033236443996,
0.023753123357892036,
-0.07866019755601883,
0.00709686242043972,
0.030202414840459824,
0.039893969893455505,
0.02088089846074581,
0.006440479774028063,
-0.009497725404798985,
0.016607804223895073,
0.0057973130606114864,
0.037708964198827744,
-0.012669507414102554,
-0.01006159745156765,
-0.040493085980415344,
-0.0313301607966423,
-0.07281002402305603,
-0.12158498167991638,
0.0107047650963068,
-0.05399078130722046,
0.05927708372473717,
-0.0575854666531086,
-0.04479261115193367,
-0.0039052567444741726,
-0.021374287083745003,
0.012255413457751274,
-0.0373213030397892,
-0.025127563625574112,
0.01955932378768921,
-0.0035418234765529633,
-0.026783937588334084,
0.008396412245929241,
0.026255307719111443,
-0.002958127297461033,
-0.02387647144496441,
0.036070212721824646,
-0.01794700138270855,
0.014951428398489952,
-0.03661646321415901,
-0.004889830946922302,
-0.04715382680296898,
0.020739931613206863,
0.03862525895237923,
-0.00348235247656703,
0.0628717690706253,
-0.011867751367390156,
0.00737879890948534,
-0.051347628235816956,
0.029603300616145134,
-0.009647504426538944,
0.007229020353406668,
-0.01548886951059103,
-0.08288924396038055,
0.033057019114494324,
-0.015250985510647297,
-0.04535648599267006,
0.045074548572301865,
0.010537365451455116,
-0.008621079847216606,
0.013365537859499454,
-0.004301729612052441,
-0.0745016410946846,
-0.006215812172740698,
0.025673814117908478,
0.05614054575562477,
-0.007559414021670818,
0.018783999606966972,
0.029603300616145134,
-0.010554986074566841,
0.04711858555674553,
-0.002889845985919237,
0.045673664659261703,
-0.0401054248213768,
0.07083646953105927,
-0.02102186717092991,
-0.03837856277823448,
0.02516280487179756,
0.01462544035166502,
-0.00914530549198389,
-0.029973341152071953,
-0.012475676834583282,
0.015788426622748375,
0.045145031064748764,
-0.02294255793094635,
0.065796859562397,
0.06819331645965576,
0.021638602018356323,
0.020070333033800125
]
|
33,060 | bqplot.figure | _handle_custom_msgs | null | def _handle_custom_msgs(self, _, content, buffers=None):
if content.get('event') == 'upload_png':
try:
self._upload_png_callback(buffers[0])
finally:
self._upload_png_callback = None
| (self, _, content, buffers=None) | [
-0.0014277910813689232,
-0.06285828351974487,
-0.07034309953451157,
0.07002384215593338,
-0.03041815757751465,
0.016388557851314545,
-0.02225935272872448,
0.09230092912912369,
0.06087179109454155,
0.02520361728966236,
0.05320960655808449,
0.02768673188984394,
0.015306630171835423,
-0.059133607894182205,
-0.0417872779071331,
0.009923591278493404,
0.006580254528671503,
-0.015918539837002754,
-0.000858559156768024,
-0.03643084317445755,
-0.021869149059057236,
-0.00888156984001398,
0.03387678414583206,
0.03148235008120537,
-0.0014765665400773287,
0.06764714419841766,
-0.007781905122101307,
0.009622070007026196,
-0.0069881947711110115,
0.005600310862064362,
-0.014002994634211063,
-0.06644105911254883,
0.06370963156223297,
0.052109941840171814,
-0.03767240047454834,
0.023837903514504433,
0.0016284356825053692,
0.04494437947869301,
-0.04930756986141205,
-0.01576777920126915,
-0.019510189071297646,
0.009382626973092556,
0.029123391956090927,
-0.022702764719724655,
0.027438420802354813,
0.07179749757051468,
-0.035756856203079224,
0.1057806983590126,
0.00033339145011268556,
-0.021744992583990097,
-0.032085392624139786,
-0.033734891563653946,
-0.04586667940020561,
0.05047817900776863,
0.02651612088084221,
0.06459645926952362,
0.0368565209209919,
0.04175180569291115,
-0.008460327051579952,
-0.0007549112779088318,
-0.02616138942539692,
0.015173605643212795,
0.004325497429817915,
-0.028555821627378464,
0.005436248145997524,
-0.024902096018195152,
0.06796640157699585,
-0.039410579949617386,
-0.040120042860507965,
0.018747517839074135,
0.003001908538863063,
-0.011262699961662292,
-0.026356492191553116,
0.019155457615852356,
0.026587067171931267,
-0.022631818428635597,
0.022951077669858932,
0.031624242663383484,
-0.010225112549960613,
0.06488024443387985,
0.09137862920761108,
-0.028804132714867592,
0.023128442466259003,
-0.011298173107206821,
0.06282281130552292,
-0.07470628619194031,
0.036395370960235596,
-0.004460738506168127,
-0.05221635848283768,
0.06200692802667618,
0.006762054283171892,
-0.0693143829703331,
0.0011212816461920738,
-0.0466470867395401,
-0.03189029172062874,
-0.0230929683893919,
-0.039233215153217316,
-0.004842074122279882,
0.01260180864483118,
0.0501943938434124,
-0.022525399923324585,
0.0133201377466321,
-0.00656695244833827,
-0.020858164876699448,
0.06367415934801102,
-0.0013202633708715439,
0.012380101718008518,
-0.04043930023908615,
-0.01848147064447403,
-0.006504874210804701,
0.043489985167980194,
-0.04150349274277687,
-0.019474714994430542,
0.011457801796495914,
0.011440065689384937,
-0.03820449858903885,
-0.022543136030435562,
0.008167674764990807,
-0.016424031928181648,
0.0011024365667253733,
-0.051506899297237396,
-0.03204992040991783,
-0.00377123081125319,
-0.0067310151644051075,
-0.012477653101086617,
0.002800155431032181,
0.058707933872938156,
0.007107916753739119,
0.002276927698403597,
-0.025948550552129745,
-0.0222061425447464,
0.029957007616758347,
-0.019102249294519424,
-0.03455077111721039,
-0.016246667131781578,
0.026551593095064163,
-0.005631349980831146,
-0.038772065192461014,
0.0302230566740036,
-0.03453303501009941,
0.0362357422709465,
0.036572735756635666,
-0.009231866337358952,
-0.026533856987953186,
0.008819492533802986,
0.013896575197577477,
0.08733469992876053,
-0.019403770565986633,
-0.015395312570035458,
-0.03236917778849602,
-0.013062958605587482,
0.02231256105005741,
-0.03884301334619522,
0.01853467896580696,
0.0007443802314810455,
-0.003119413275271654,
-0.011954424902796745,
0.0017814133316278458,
-0.03944605588912964,
0.059665706008672714,
0.04955587908625603,
0.003921991214156151,
0.009959064424037933,
-0.00926733948290348,
0.039765313267707825,
0.012584071606397629,
0.023359017446637154,
0.004930756986141205,
0.005383038427680731,
0.007396135479211807,
0.011989898048341274,
0.05491231381893158,
0.012193867936730385,
-0.018924882635474205,
0.049910612404346466,
0.07385493069887161,
-0.031074410304427147,
-0.016663474962115288,
-0.03630668669939041,
0.0013779071159660816,
-0.006398455239832401,
0.03417830541729927,
0.037991657853126526,
0.053103186190128326,
-0.018268631771206856,
0.023518646135926247,
0.02839619293808937,
0.010136430151760578,
-0.022543136030435562,
-0.03082609921693802,
-0.02385563962161541,
0.05657954886555672,
-0.004855376668274403,
-0.01410941407084465,
0.05831772834062576,
0.01514700148254633,
-0.0033943294547498226,
-0.014269042760133743,
-0.005187936592847109,
-0.017816349864006042,
-0.006185616832226515,
-0.054876841604709625,
-0.03123403899371624,
0.0186588354408741,
-0.009196393191814423,
0.05047817900776863,
0.08470969647169113,
0.054947786033153534,
-0.053706228733062744,
-0.026817642152309418,
-0.06871134042739868,
-0.007538027595728636,
-0.02811240777373314,
0.0056712571531534195,
0.037353143095970154,
-0.04866905137896538,
-0.07357114553451538,
0.04292241483926773,
-0.04239032045006752,
-0.0006102476618252695,
0.029034707695245743,
0.050868384540081024,
-0.05991401523351669,
0.007706524804234505,
0.018162211403250694,
0.05303224176168442,
0.051329534500837326,
0.007892758585512638,
0.04246126487851143,
0.016193456947803497,
-0.0003175948513671756,
0.07052046805620193,
0.012566335499286652,
0.030506839975714684,
-0.0063762846402823925,
0.018871674314141273,
0.03806260600686073,
-0.05849509313702583,
-0.0028489308897405863,
0.02025512419641018,
0.022631818428635597,
-0.018197685480117798,
0.018676571547985077,
-0.013967521488666534,
0.015794385224580765,
-0.013932048343122005,
0.014792270958423615,
0.013692605309188366,
-0.030329475179314613,
0.053351499140262604,
0.010899101383984089,
0.007112350780516863,
-0.011927819810807705,
-0.025132670998573303,
-0.056650493294000626,
-0.009950196370482445,
-0.0017160098068416119,
-0.0466470867395401,
0.06480930000543594,
0.004474041052162647,
-0.031624242663383484,
0.036572735756635666,
0.020698536187410355,
0.07151371240615845,
0.010154166258871555,
-0.052642036229372025,
0.021833674982190132,
0.026143653318285942,
-0.028378456830978394,
0.05232277885079384,
0.07020121067762375,
0.03004569187760353,
0.023713747039437294,
-0.03930416330695152,
-0.0153243662789464,
-0.007919362746179104,
0.017816349864006042,
-0.004057232290506363,
0.014694719575345516,
-0.001356844906695187,
0.04639877751469612,
0.01410941407084465,
0.04391566291451454,
0.039233215153217316,
-0.006562517955899239,
-0.0009998971363529563,
0.0818009003996849,
0.033557526767253876,
-0.021478943526744843,
-0.07591237127780914,
-0.024423209950327873,
0.04246126487851143,
-0.0029930402524769306,
0.05207446962594986,
-0.054876841604709625,
-0.013710341416299343,
-0.043135255575180054,
0.0346217155456543,
0.030258528888225555,
0.03557949140667915,
-0.00826522521674633,
0.012096317484974861,
0.03378809988498688,
-0.04214200749993324,
-0.0056357840076088905,
-0.014836612157523632,
0.017266517505049706,
-0.030985727906227112,
-0.017151229083538055,
0.011874610558152199,
0.010757208801805973,
-0.0013446511002257466,
-0.023891113698482513,
-0.010916837491095066,
0.029850589111447334,
0.06853397190570831,
0.11784154176712036,
0.028946025297045708,
0.03336242213845253,
0.06058800593018532,
0.01080155000090599,
-0.0346217155456543,
-0.050158921629190445,
0.020326070487499237,
0.026019496843218803,
-0.03460397943854332,
-0.04022646322846413,
0.02385563962161541,
0.021124213933944702,
-0.02603723481297493,
-0.005143595393747091,
-0.008154371753334999,
-0.0357745923101902,
-0.0995374396443367,
-0.020006811246275902,
-0.05583461374044418,
-0.03792071342468262,
-0.02750936709344387,
0.00655364990234375,
-0.037991657853126526,
-0.0959901288151741,
-0.013435425236821175,
0.020042285323143005,
0.04817242920398712,
0.013887707144021988,
-0.008380512706935406,
0.04604404419660568,
-0.007254242897033691,
0.013958653435111046,
-0.013949785381555557,
-0.007019233889877796,
-0.034568507224321365,
0.028555821627378464,
-0.003875433001667261,
0.020751746371388435,
-0.04192917048931122,
0.009462441317737103,
-0.018268631771206856,
0.03242238610982895,
0.03298995643854141,
0.050868384540081024,
0.01700933836400509,
0.04547647759318352,
-0.027793150395154953,
-0.012247078120708466,
0.02969096042215824,
0.009604333899915218,
0.012353496626019478,
0.07066235691308975,
-0.03463945537805557,
0.02656932920217514,
0.03219181299209595,
-0.08045292645692825,
0.026533856987953186,
-0.014189228415489197,
-0.009293944574892521,
-0.030435895547270775,
0.017568038776516914,
-0.03884301334619522,
0.026303282007575035,
0.009107710793614388,
0.03435567021369934,
-0.025345509871840477,
-0.018100135028362274,
0.009852644987404346,
0.00826522521674633,
-0.05955928564071655,
0.05200352147221565,
-0.036572735756635666,
-0.02958454191684723,
0.022826921194791794,
-0.018321841955184937,
-0.012158394791185856,
-0.03788524121046066,
-0.01682310365140438,
-0.02679990418255329,
-0.023039760068058968,
0.03311411291360855,
0.004975098185241222,
0.01848147064447403,
-0.054522108286619186,
0.0045494213700294495,
-0.0915205255150795,
0.005906266160309315,
0.037636928260326385,
0.04987513646483421,
-0.051400478929281235,
0.04338356480002403,
0.02828977443277836,
0.05814036354422569,
0.003112762002274394,
0.006447230465710163,
-0.006615727674216032,
-0.027012743055820465,
-0.01334674283862114,
-0.016459504142403603,
-0.08158805966377258,
-0.02538098208606243,
-0.07499007135629654,
0.008078991435468197,
-0.05427379906177521,
0.10294285416603088,
0.06853397190570831,
-0.010659657418727875,
0.007870587520301342,
-0.02933622896671295,
-0.02981511689722538,
-0.02319938875734806,
-0.01057097502052784,
-0.02089363895356655,
-0.038701120764017105,
0.031730663031339645,
-0.04604404419660568,
-0.030276266857981682,
0.049343042075634,
0.026604803279042244,
-0.03873659297823906,
-0.009737357497215271,
-0.03937510773539543,
0.004183605313301086,
-0.01906677521765232,
0.04764033481478691,
-0.02413942478597164,
-0.04827884957194328,
0.057182591408491135,
0.003234700532630086,
-0.025753449648618698,
0.021762728691101074,
-0.0255583468824625,
-0.01611364260315895,
-0.01841052435338497,
0.07456439733505249,
0.02036154270172119,
-0.003505182918161154,
-0.003447539173066616,
-0.0386301726102829,
0.023820167407393456,
0.002815674990415573,
0.004165868740528822,
-0.06275185942649841,
-0.05909813567996025,
0.01026945374906063,
-0.06903059780597687,
-0.05725353583693504,
0.05090385675430298,
0.034923236817121506,
0.026409700512886047,
0.024050742387771606,
0.01871204562485218,
0.022152932360768318,
0.03620027005672455,
0.002607270609587431,
0.02101779356598854,
-0.023394489660859108,
0.03316732123494148,
-0.02585986815392971,
0.05704069882631302,
0.024068478494882584,
0.0005963909788988531,
0.022223878651857376,
0.05402548611164093,
-0.03511834144592285,
0.014011862687766552,
-0.04104234278202057,
-0.009214130230247974,
-0.005657954607158899,
-0.0029597843531519175,
-0.054947786033153534,
0.06718599796295166,
-0.00983490888029337,
-0.018641099333763123,
-0.021744992583990097,
-0.015741175040602684,
0.0034564072266221046,
-0.0052189757116138935,
-0.07186844199895859,
-0.03281259164214134,
-0.007888324558734894,
0.03919774293899536,
-0.06949174404144287,
-0.00838494673371315,
-0.0019421506440266967,
-0.023944322019815445,
-0.011617430485785007,
0.008429288864135742,
-0.06856944411993027,
0.051152169704437256,
0.0180025827139616,
0.009041198529303074,
-0.026906324550509453,
-0.06431267410516739,
0.06856944411993027,
-0.0002624453045427799,
-0.029655486345291138,
-0.0226672925055027,
-0.02862676791846752,
0.020166439935564995,
0.01355071272701025,
-0.019989075139164925,
-0.026072707027196884,
0.04707276448607445,
-0.00012547212827485055,
0.02091137506067753,
0.007453779224306345,
0.024369999766349792,
-0.012247078120708466,
-0.07055594027042389,
0.0195456612855196,
0.01260180864483118,
-0.0010852542473003268,
-0.018445996567606926,
-0.01009208895266056,
0.04075855761766434,
-0.0413261279463768,
-0.013337874785065651,
0.029655486345291138,
0.008832794614136219,
-0.05491231381893158,
-0.08939214050769806,
0.005622481927275658,
-0.03325600549578667,
-0.02692406065762043,
-0.027261054143309593,
-0.05757279321551323,
-0.054770421236753464,
0.03784976527094841,
0.011076466180384159,
0.009604333899915218,
0.034266985952854156,
-0.036466315388679504,
0.026125917211174965,
-0.022880131378769875,
0.014410935342311859,
0.04054572060704231,
-0.014623773284256458,
0.013807892799377441,
-0.021691782400012016,
-0.04593762755393982,
0.0195456612855196,
-0.04668256267905235,
-0.03455077111721039,
0.054770421236753464,
-0.055302515625953674,
0.04764033481478691,
-0.055302515625953674,
0.005751071497797966,
-0.038772065192461014,
0.06949174404144287,
-0.032741643488407135,
0.0022359120193868876,
0.019989075139164925,
0.025292299687862396,
0.010420214384794235,
-0.06402889639139175,
0.010828155092895031,
-0.017701061442494392,
0.021869149059057236,
-0.019297350198030472,
-0.010615316219627857,
0.005294356029480696,
-0.004819903522729874,
-0.009409232065081596,
0.025416456162929535,
-0.014934162609279156,
-0.008535707369446754,
-0.035455334931612015,
0.002753597218543291,
-0.04419944807887077,
0.018286367878317833,
0.01913772150874138,
-0.02350091002881527,
0.06370963156223297,
-0.011484406888484955,
-0.05445116385817528,
0.012202735990285873,
0.04097139835357666,
0.05778563395142555,
0.015634756535291672,
-0.0653059259057045,
-0.0215498898178339,
0.011892346665263176,
0.016344217583537102,
-0.04320620000362396,
-0.0166546069085598,
0.022897867485880852,
-0.017727667465806007,
-0.03898490592837334,
0.013621659018099308,
0.023110706359148026,
0.03478134423494339,
-0.03364620730280876,
0.018995828926563263,
0.0226672925055027,
0.04920114949345589,
0.01623779907822609,
-0.007684353739023209,
-0.03742409124970436,
0.021815938875079155,
0.047392021864652634,
0.07009478658437729,
0.021691782400012016,
0.00290879188105464,
-0.0333092138171196,
0.006416191812604666,
-0.008194278925657272,
-0.04334809258580208,
-0.00009249326103599742,
-0.035047393292188644,
-0.04093592241406441,
0.05359980836510658,
-0.001022067852318287,
0.02491983212530613,
0.02380243130028248,
-0.04324167221784592,
0.0666893720626831,
0.003398763481527567,
-0.07428061217069626,
-0.02302202209830284,
-0.061723142862319946,
-0.010109825059771538,
0.04529911279678345,
-0.05987854301929474,
-0.037991657853126526,
-0.09528066962957382,
-0.006123539060354233,
0.08598672598600388,
0.004957361612468958,
-0.015253419987857342,
0.009985669516026974,
0.00814550369977951,
0.025647029280662537,
0.023394489660859108,
0.003106110729277134,
0.04281599819660187,
0.018091266974806786,
0.05604745075106621,
0.01924414001405239,
0.0008674274431541562,
-0.012184999883174896,
0.04051024839282036,
-0.03919774293899536,
-0.0373176708817482,
0.06409984081983566,
0.045795734971761703,
-0.05533799156546593,
-0.05136500671505928,
0.020219650119543076,
-0.05090385675430298,
-0.019279614090919495,
-0.0030728548299521208,
-0.0023390057031065226,
-0.03151782229542732,
-0.004607065115123987,
-0.027704467996954918,
0.05250014364719391,
0.001356844906695187,
0.05306771397590637,
0.016459504142403603,
0.015909671783447266,
0.024760203436017036,
0.004046147223562002,
-0.004828771576285362,
-0.03467492759227753,
0.04639877751469612,
0.03926869109272957,
-0.02036154270172119,
0.05342244356870651,
0.00039824063424021006,
-0.041361600160598755,
-0.016335349529981613,
0.04292241483926773,
0.0202019140124321,
-0.00032618598197586834,
0.009675280191004276,
-0.08002724498510361,
0.07300358265638351,
-0.03930416330695152,
-0.024299053475260735,
-0.021478943526744843,
-0.019049039110541344,
0.029974745586514473,
-0.07584142684936523,
-0.024068478494882584,
-0.030152110382914543,
-0.01736406795680523,
-0.008256357163190842,
-0.06835661083459854,
-0.022401243448257446,
-0.005325394682586193,
0.040474772453308105,
-0.05040723457932472,
-0.04373829811811447,
-0.004961795639246702,
0.030630996450781822,
-0.07279074192047119,
-0.016725553199648857,
-0.05544440820813179,
0.033451106399297714,
0.034284722059965134,
-0.006886209826916456,
-0.06899512559175491,
0.009081105701625347,
0.029265282675623894,
-0.014410935342311859,
0.03128724917769432,
-0.06739883124828339,
0.01853467896580696,
-0.050265341997146606,
0.046327829360961914,
0.02018417790532112,
0.002946482039988041,
-0.028892816975712776,
-0.07385493069887161,
0.041184235364198685,
-0.028254300355911255,
-0.06388700008392334,
0.039765313267707825,
-0.026232335716485977,
0.01740841008722782,
0.006895078346133232,
-0.026604803279042244,
-0.06009138375520706,
0.006562517955899239,
0.009347153827548027,
0.023766957223415375,
-0.01683197170495987,
0.027793150395154953,
0.05214541405439377,
-0.03738861531019211,
0.07328736782073975,
0.0030240793712437153,
0.007799641229212284,
-0.036927465349435806,
0.02202877774834633,
0.00707244360819459,
-0.0022880129981786013,
-0.02656932920217514,
-0.020095495507121086,
-0.011014388874173164,
0.026125917211174965,
0.023784693330526352,
0.024636046960949898,
0.012442179955542088,
-0.04285147041082382,
0.03944605588912964,
0.02415716089308262,
-0.024458682164549828,
0.037104833871126175
]
|
33,080 | bqplot.figure | get_png_data |
Gets the Figure as a PNG memory view
Parameters
----------
callback: callable
Called with the PNG data as the only positional argument.
scale: float (default: None)
Scale up the png resolution when scale > 1, when not given base this on the screen pixel ratio.
| def get_png_data(self, callback, scale=None):
'''
Gets the Figure as a PNG memory view
Parameters
----------
callback: callable
Called with the PNG data as the only positional argument.
scale: float (default: None)
Scale up the png resolution when scale > 1, when not given base this on the screen pixel ratio.
'''
if self._upload_png_callback:
raise Exception('get_png_data already in progress')
self._upload_png_callback = callback
self.send({'type': 'upload_png', 'scale': scale})
| (self, callback, scale=None) | [
0.0433402955532074,
-0.061179954558610916,
-0.03510384261608124,
0.05384267494082451,
-0.0072248815558850765,
0.07632207870483398,
-0.051396917551755905,
0.02762269601225853,
0.01891866885125637,
-0.0459299236536026,
0.08567351847887039,
0.011473488993942738,
0.03199269250035286,
-0.014809433370828629,
0.005741240456700325,
0.000474034488433972,
0.01902657002210617,
-0.019044553861021996,
0.013029064051806927,
0.059489503502845764,
0.009005250409245491,
0.013020072132349014,
0.01765982247889042,
-0.0024772307369858027,
-0.03668639063835144,
0.02780253067612648,
0.036200836300849915,
-0.021112658083438873,
0.06650307774543762,
0.05866226181387901,
-0.05272769555449486,
-0.040678735822439194,
0.0224973913282156,
0.0930107906460762,
-0.004131714813411236,
0.07732915878295898,
0.01438682060688734,
0.040175195783376694,
-0.039671655744314194,
-0.040139228105545044,
-0.008119561709463596,
-0.03434853255748749,
0.050821442157030106,
-0.003740573301911354,
0.041505977511405945,
0.029960554093122482,
-0.024709364399313927,
-0.024025989696383476,
-0.011941061355173588,
-0.10459218174219131,
0.051504816859960556,
0.032154545187950134,
-0.07488340139389038,
0.06704258173704147,
0.016347024589776993,
0.0473686046898365,
-0.007395724765956402,
0.061431724578142166,
0.058554358780384064,
0.029708784073591232,
-0.0490230917930603,
-0.0031403731554746628,
0.03145318478345871,
-0.06376957893371582,
-0.01721922494471073,
0.01592441275715828,
-0.02650771662592888,
-0.0455702543258667,
-0.015492807142436504,
0.002267048228532076,
0.015573733486235142,
0.048951156437397,
0.003972111269831657,
0.042333219200372696,
-0.0008255562279373407,
-0.0038934333715587854,
0.021328460425138474,
-0.0426928885281086,
-0.029708784073591232,
0.05664810538291931,
-0.0005397867644205689,
0.041002437472343445,
0.04308852553367615,
0.0026166029274463654,
0.03830491006374359,
-0.06808562576770782,
0.020501218736171722,
0.0224973913282156,
-0.06416521966457367,
0.030392158776521683,
-0.004520608577877283,
-0.022946977987885475,
0.011518447659909725,
0.027352942153811455,
-0.023594385012984276,
-0.0948810800909996,
-0.03657849133014679,
0.05535329133272171,
-0.0013184172566980124,
-0.003607944818213582,
-0.06171945855021477,
-0.06103608384728432,
0.004635253921151161,
0.00008598373096901923,
0.009113151580095291,
-0.02895347587764263,
0.03855668008327484,
-0.02014154940843582,
-0.0465053953230381,
0.02686738781630993,
0.02870170585811138,
0.020932823419570923,
-0.02855783887207508,
0.005449008196592331,
0.010088757611811161,
0.016652744263410568,
-0.0460737906396389,
-0.03246026486158371,
-0.0010700197890400887,
-0.07517113536596298,
-0.08452256768941879,
0.027532776817679405,
-0.025374755263328552,
0.025968210771679878,
-0.018756818026304245,
0.012588467448949814,
0.07171829789876938,
0.050713542848825455,
-0.009783037938177586,
-0.01325385831296444,
-0.009810012765228748,
-0.01545684039592743,
-0.03152512013912201,
0.04337626323103905,
-0.0032550180330872536,
-0.01970994472503662,
0.08150133490562439,
-0.02773059718310833,
-0.035985033959150314,
0.01899060234427452,
-0.048879221081733704,
0.0064381021074950695,
-0.02625594660639763,
0.04855551943182945,
0.03758556768298149,
-0.025087017565965652,
0.042117416858673096,
0.009989848360419273,
-0.022551340982317924,
-0.0452105849981308,
0.0028301572892814875,
0.027892448008060455,
-0.004815089050680399,
-0.026561668142676353,
0.06506439298391342,
-0.0071709309704601765,
-0.0009722343529574573,
0.060748349875211716,
-0.03485207259654999,
0.05402250960469246,
-0.04869938641786575,
0.03665042668581009,
-0.009621186181902885,
-0.07135862857103348,
0.007746403571218252,
0.015079186297953129,
0.006631425116211176,
0.0009666145197115839,
0.00034477791632525623,
0.06337394565343857,
0.011095834895968437,
-0.05272769555449486,
-0.033017754554748535,
-0.020555170252919197,
0.011455506086349487,
0.02213772013783455,
0.020429285243153572,
0.0041721779853105545,
-0.01924237236380577,
0.05351897329092026,
0.019260356202721596,
-0.02791043184697628,
-0.0218859501183033,
0.06254670023918152,
-0.0074361879378557205,
0.01899060234427452,
0.029780717566609383,
-0.0030167363584041595,
0.0028571325819939375,
-0.03560737892985344,
0.012534516863524914,
0.052008356899023056,
-0.02675948664546013,
-0.03281993418931961,
0.05661213770508766,
-0.05301543325185776,
0.02292899414896965,
0.003167348448187113,
0.029780717566609383,
-0.0056782984174788,
0.004414955619722605,
-0.07394825667142868,
-0.001603905693627894,
-0.052475929260253906,
-0.022011835128068924,
-0.029439032077789307,
0.013604536652565002,
0.03238832950592041,
-0.0426928885281086,
0.015870461240410805,
-0.017785707488656044,
0.006244779098778963,
-0.01902657002210617,
-0.007665477693080902,
0.0448509119451046,
-0.0431964285671711,
-0.07862397283315659,
0.025698458775877953,
0.00015061203157529235,
0.022839076817035675,
0.005615355912595987,
-0.003859714139252901,
-0.008281413465738297,
0.0243676770478487,
0.0013049296103417873,
-0.004455418325960636,
0.041398074477910995,
-0.022047802805900574,
0.020069614052772522,
-0.03350330889225006,
-0.021796032786369324,
-0.012849229387938976,
-0.010969950817525387,
0.022299570962786674,
0.051145147532224655,
-0.015978362411260605,
0.0223175548017025,
0.004208145197480917,
0.05164868384599686,
0.042549021542072296,
-0.0006075059645809233,
0.022982945665717125,
0.03855668008327484,
0.03231639415025711,
0.0013296569231897593,
-0.007090005092322826,
0.0010323667665943503,
0.025698458775877953,
-0.03091368079185486,
-0.027316974475979805,
0.01877480000257492,
-0.051396917551755905,
0.030464092269539833,
0.021220559254288673,
0.024691380560398102,
0.004725171253085136,
-0.07092702388763428,
-0.03352129086852074,
0.04438333958387375,
-0.0008272421546280384,
0.023090846836566925,
-0.01714729145169258,
-0.00241428823210299,
0.051396917551755905,
0.012282747775316238,
-0.039959393441677094,
-0.03693816065788269,
0.008258934132754803,
-0.05625246837735176,
0.03841280937194824,
0.08603318780660629,
0.08315582573413849,
-0.021436361595988274,
-0.018612949177622795,
0.024745332077145576,
-0.030751828104257584,
0.05715164542198181,
-0.04459914192557335,
0.03726186603307724,
-0.021256526932120323,
0.019799862056970596,
-0.050389837473630905,
0.029690800234675407,
-0.0027245040982961655,
0.012957130558788776,
-0.05229609087109566,
0.050425805151462555,
0.06808562576770782,
0.00765648577362299,
-0.03461828827857971,
-0.011392563581466675,
0.00773741165176034,
-0.10077967494726181,
-0.015034227631986141,
-0.05689987540245056,
-0.012525525875389576,
-0.014728507027029991,
0.002427775878459215,
0.0242597758769989,
0.03834087774157524,
-0.029906602576375008,
-0.06751015782356262,
0.01678762026131153,
0.05578489601612091,
0.006379655562341213,
0.008447760716080666,
0.005579388700425625,
-0.04380786791443825,
-0.023018913343548775,
0.017542928457260132,
0.02758672833442688,
0.019404223188757896,
0.01978187821805477,
0.06294234097003937,
-0.009068192914128304,
-0.0031740921549499035,
0.051756586879491806,
0.05452604964375496,
0.023342616856098175,
0.05754728242754936,
-0.030392158776521683,
-0.03490602225065231,
-0.03260413184762001,
-0.02483524940907955,
0.0887666791677475,
0.0235044676810503,
-0.0228570606559515,
0.0238281711935997,
0.08207681030035019,
0.07182620465755463,
-0.042333219200372696,
-0.015294988639652729,
0.051612719893455505,
-0.025572573766112328,
0.0014150786446407437,
-0.0219578854739666,
-0.04416753724217415,
-0.033125653862953186,
0.0017803690861910582,
-0.0108710415661335,
-0.02014154940843582,
-0.03880844637751579,
0.000010607470358081628,
-0.000031734598451294005,
0.02170611545443535,
0.05546119436621666,
0.016562826931476593,
-0.0464334636926651,
0.01726418361067772,
-0.003104406176134944,
0.002189494203776121,
-0.0061998204328119755,
-0.026309898123145103,
0.010025815106928349,
0.013056039810180664,
0.023162780329585075,
0.021544262766838074,
-0.003643911797553301,
-0.01341571006923914,
0.013163940981030464,
0.02866574004292488,
0.004788113757967949,
0.008182504214346409,
-0.009086175821721554,
0.03780137002468109,
-0.02593224309384823,
-0.049994200468063354,
-0.007373245432972908,
0.0911405086517334,
0.021975867450237274,
0.008919828571379185,
0.011842151172459126,
-0.03415071591734886,
0.017848649993538857,
-0.00963917002081871,
-0.03503190726041794,
-0.026309898123145103,
0.031075531616806984,
-0.003484308021143079,
-0.009459334425628185,
-0.032514214515686035,
-0.029690800234675407,
-0.005404049530625343,
0.03292783349752426,
0.03747766837477684,
-0.012066945433616638,
-0.052224159240722656,
0.02582434192299843,
-0.014746490865945816,
0.0007929611019790173,
-0.007422700058668852,
-0.020195499062538147,
-0.025320803746581078,
0.0065954579040408134,
0.008910836651921272,
-0.03949182108044624,
-0.008425281383097172,
0.0897737592458725,
-0.040570832788944244,
0.008191496133804321,
-0.05801485478878021,
-0.0462176613509655,
-0.06938043981790543,
0.00931546650826931,
0.01551079098135233,
-0.0016106495168060064,
-0.03981552645564079,
0.02400800585746765,
0.00019430636893957853,
-0.015294988639652729,
0.005183751229196787,
-0.06894883513450623,
-0.041757747530937195,
-0.01863093301653862,
0.03884441405534744,
0.014045133255422115,
-0.03371911123394966,
-0.05387864261865616,
-0.024241792038083076,
0.0043834843672811985,
0.00019233943021390587,
0.0868963971734047,
-0.00884789414703846,
-0.0005839025834575295,
-0.010466411709785461,
-0.0243676770478487,
-0.006235787644982338,
0.04294465854763985,
-0.0237202700227499,
0.0878315418958664,
0.0032977289520204067,
-0.029169278219342232,
-0.0005990762147121131,
-0.025680474936962128,
0.040139228105545044,
0.021616198122501373,
0.004277830943465233,
0.017821673303842545,
-0.026849403977394104,
0.025554589927196503,
0.050785474479198456,
0.05747534707188606,
-0.0020467499271035194,
-0.07445179671049118,
0.01827126182615757,
-0.015789534896612167,
-0.05600069835782051,
0.010862049646675587,
-0.03474416956305504,
-0.025986194610595703,
0.026453766971826553,
0.06330201029777527,
0.0473686046898365,
-0.003288737265393138,
0.02758672833442688,
-0.087112195789814,
-0.027496811002492905,
-0.06603550910949707,
-0.007975693792104721,
-0.012885196134448051,
0.011743241921067238,
-0.025482656434178352,
-0.07653788477182388,
-0.04539041966199875,
0.06215106323361397,
0.00469370000064373,
0.06952431052923203,
0.04675716534256935,
-0.011518447659909725,
-0.03729783371090889,
0.02931314706802368,
0.0025806359481066465,
-0.050461772829294205,
-0.028000349178910255,
0.014503713697195053,
-0.00771043635904789,
0.012543508782982826,
0.03913215175271034,
-0.011275670491158962,
-0.0224254559725523,
-0.00469370000064373,
-0.03116544894874096,
-0.002319874707609415,
0.0011689291568472981,
-0.06251073628664017,
-0.020069614052772522,
0.0232886653393507,
-0.0029672817327082157,
-0.00863209180533886,
0.007000087294727564,
-0.05481378734111786,
0.001950088539160788,
-0.050641607493162155,
0.029636850580573082,
-0.0005119685083627701,
0.015906428918242455,
0.040930505841970444,
-0.03683026134967804,
0.00111273059155792,
-0.027748579159379005,
-0.026058128103613853,
-0.040211163461208344,
0.042620956897735596,
-0.015663649886846542,
0.014665565453469753,
-0.003589961212128401,
-0.014647581614553928,
0.050965312868356705,
-0.025590557605028152,
-0.025896277278661728,
-0.061215922236442566,
0.03591310232877731,
-0.030050471425056458,
0.007346270140260458,
-0.04003132879734039,
-0.0023288666270673275,
0.026201996952295303,
-0.020483234897255898,
-0.04869938641786575,
-0.04380786791443825,
0.010844065807759762,
0.07783269882202148,
0.023450518026947975,
-0.008609612472355366,
0.016293074935674667,
0.013550586067140102,
-0.05797888711094856,
0.021867966279387474,
-0.00436999648809433,
0.015160111710429192,
-0.00884339865297079,
-0.0229649618268013,
0.06153962388634682,
-0.03787330538034439,
0.005660314578562975,
-0.012588467448949814,
0.008335364051163197,
-0.020788956433534622,
-0.05470588430762291,
-0.04920292645692825,
-0.031794872134923935,
-0.02639981545507908,
-0.013910257257521152,
-0.051468849182128906,
-0.01422496885061264,
0.0219938512891531,
0.060640446841716766,
0.029762735590338707,
0.09876552224159241,
-0.03665042668581009,
-0.0013689958723261952,
0.017354102805256844,
0.05812275409698486,
-0.07991878688335419,
-0.005417536944150925,
0.04646943137049675,
0.006312217563390732,
-0.01148248091340065,
0.008276917971670628,
-0.06754612177610397,
-0.006608945783227682,
0.0229649618268013,
-0.0015308476286008954,
0.043016593903303146,
-0.041002437472343445,
-0.0027020247653126717,
-0.012777294963598251,
0.06981204450130463,
-0.011419538408517838,
-0.06902077049016953,
-0.003315712558105588,
0.05366284027695656,
0.059201765805482864,
-0.025122985243797302,
0.009270507842302322,
-0.020051630213856697,
0.03166898712515831,
-0.003419117769226432,
0.025087017565965652,
-0.03790927305817604,
0.011365587823092937,
0.024979116395115852,
0.022623274475336075,
0.020770972594618797,
-0.05427427962422371,
-0.013667479157447815,
0.008726505562663078,
0.0020860889926552773,
-0.025320803746581078,
0.01830722950398922,
0.02354043535888195,
0.004599286708980799,
-0.050857409834861755,
-0.020878873765468597,
-0.010763140395283699,
-0.030212322250008583,
-0.022011835128068924,
0.009360425174236298,
-0.04905905947089195,
-0.003153860801830888,
0.0011132926447317004,
0.03478013724088669,
-0.052008356899023056,
-0.015897436067461967,
-0.022335538640618324,
-0.009135630913078785,
0.00884789414703846,
0.009630178101360798,
-0.0214543454349041,
-0.008582637645304203,
-0.04287272319197655,
0.06430909037590027,
0.014872375875711441,
-0.015798527747392654,
-0.005579388700425625,
-0.036272771656513214,
-0.051936421543359756,
0.03736976534128189,
-0.04423947259783745,
0.090277299284935,
0.03650655597448349,
0.060604482889175415,
0.014458754099905491,
0.018118401989340782,
-0.01877480000257492,
-0.04589395597577095,
0.02618401311337948,
-0.005610859952867031,
-0.007292319554835558,
-0.06963220983743668,
-0.01169828325510025,
0.00851969514042139,
0.024097925052046776,
-0.04949066415429115,
0.07668175548315048,
-0.061179954558610916,
0.0019691961351782084,
0.03528367727994919,
-0.022731175646185875,
0.0033494315575808287,
0.05456201732158661,
0.010034807026386261,
-0.012624435126781464,
-0.06758208572864532,
0.05326720327138901,
0.007503625936806202,
0.012381657026708126,
0.004972444847226143,
0.003749564988538623,
-0.00461277412250638,
-0.05862629413604736,
0.025662491098046303,
0.05632440373301506,
0.004635253921151161,
0.05290753394365311,
0.06830143183469772,
-0.012696368619799614,
-0.017165275290608406,
-0.03420466557145119,
-0.013775380328297615,
-0.07060331851243973,
-0.016445934772491455,
-0.040858570486307144,
0.018100418150424957,
0.02246142365038395,
-0.010178675875067711,
-0.02830606885254383,
0.03184882551431656,
-0.06416521966457367,
-0.011617357842624187,
-0.03429458290338516,
0.03683026134967804,
-0.01970994472503662,
-0.023774221539497375,
0.03683026134967804,
-0.019620025530457497,
0.003817003220319748,
-0.01610424742102623,
0.006379655562341213,
0.0934423953294754,
0.03830491006374359,
0.0029223228339105844,
-0.0479440800845623,
0.0899176299571991,
-0.01115877740085125,
0.0429806262254715,
0.041541945189237595,
-0.05186448618769646,
-0.015079186297953129,
0.041002437472343445,
0.04474301263689995,
0.012624435126781464,
0.041793715208768845,
-0.01773175597190857,
-0.027748579159379005,
-0.02859380468726158,
-0.07240167260169983,
0.005894100293517113,
0.02791043184697628,
-0.03213655948638916,
-0.023666320368647575,
-0.06387748569250107,
-0.007768882904201746,
0.012858220376074314,
0.051576752215623856,
-0.009971864521503448,
-0.06668291240930557,
-0.003911416977643967,
-0.0068876901641488075,
-0.010628263466060162,
-0.021256526932120323,
0.0005085965967737138,
0.030338207259774208,
0.0029403064399957657,
-0.0480879470705986,
-0.013289825059473515,
-0.06492052972316742,
0.029690800234675407,
-0.027101172134280205,
0.021867966279387474,
-0.049130991101264954,
0.05449008196592331,
0.05549715831875801,
-0.026993270963430405,
-0.025716440752148628,
0.013370751403272152,
-0.015699617564678192,
-0.03916811943054199,
0.018172351643443108,
0.00392715260386467,
0.0010840693721547723,
0.00334043987095356,
0.007544089108705521,
-0.013451676815748215,
-0.06236686557531357,
-0.03449240326881409,
-0.015447848476469517,
-0.026849403977394104,
-0.022767143324017525,
-0.02429574355483055,
0.01830722950398922,
-0.050713542848825455,
0.01314595714211464,
0.036416638642549515,
0.014773466624319553,
-0.011788200587034225,
0.03494198992848396,
0.006064943969249725,
-0.017965542152523994,
-0.00045661296462640166,
0.05704374238848686,
0.023342616856098175,
-0.05456201732158661,
0.0960320234298706,
0.019080519676208496,
-0.03977955877780914,
0.02855783887207508,
0.016329040750861168,
0.042549021542072296,
-0.018505048006772995,
-0.01525902096182108,
0.036056969314813614,
-0.030248289927840233,
-0.03873651474714279,
0.016005337238311768,
0.042836759239435196,
-0.026058128103613853,
0.016239123418927193
]
|
33,094 | bqplot.figure | save_png |
Saves the Figure as a PNG file
Parameters
----------
filename: str (default: 'bqplot.png')
name of the saved file
scale: float (default: None)
Scale up the png resolution when scale > 1, when not given base this on the screen pixel ratio.
| def save_png(self, filename='bqplot.png', scale=None):
'''
Saves the Figure as a PNG file
Parameters
----------
filename: str (default: 'bqplot.png')
name of the saved file
scale: float (default: None)
Scale up the png resolution when scale > 1, when not given base this on the screen pixel ratio.
'''
self.send({'type': 'save_png', 'filename': filename, 'scale': scale})
| (self, filename='bqplot.png', scale=None) | [
0.029926424846053123,
-0.03800797089934349,
-0.04344272240996361,
0.013031051494181156,
-0.06186441332101822,
0.019409826025366783,
-0.06624044477939606,
-0.0012792840134352446,
0.010198981501162052,
-0.03864319995045662,
0.03384368121623993,
-0.01285459939390421,
0.028938287869095802,
0.029855843633413315,
0.0038091784808784723,
-0.0382550023496151,
0.004852456506341696,
0.016727741807699203,
0.0028320702258497477,
0.06197028234601021,
0.03709041327238083,
-0.03154979273676872,
0.03814913332462311,
-0.00023614370729774237,
0.031020432710647583,
0.024968095123767853,
0.04069005697965622,
0.004548075143247843,
-0.010993019677698612,
0.03479652479290962,
-0.0357317253947258,
-0.059923429042100906,
0.026838496327400208,
0.06468766182661057,
0.021580198779702187,
0.06281726062297821,
-0.014927921816706657,
0.0052847666665911674,
-0.07026357203722,
-0.06299371272325516,
0.002836481435224414,
0.03274967148900032,
0.08166243880987167,
-0.04224283993244171,
0.010745986364781857,
0.009978415444493294,
0.005646495148539543,
0.011054778471589088,
0.003921667113900185,
-0.08462684601545334,
0.044113241136074066,
0.028708897531032562,
-0.08018022775650024,
0.06197028234601021,
-0.013930962421000004,
0.014186819083988667,
0.01845698058605194,
0.045771900564432144,
0.00017755580483935773,
-0.012739904224872589,
0.00784333422780037,
0.009978415444493294,
-0.00739337969571352,
-0.046830616891384125,
0.017186518758535385,
0.04806578904390335,
-0.01680714637041092,
-0.06659334897994995,
-0.03963133692741394,
0.010525419376790524,
0.040972378104925156,
-0.01849227212369442,
-0.026344427838921547,
0.01650717481970787,
-0.028832415118813515,
0.000014621127775171772,
0.0009765569120645523,
-0.01766294240951538,
-0.05875883996486664,
0.02802073210477829,
-0.005933231208473444,
-0.002567390678450465,
0.06129976361989975,
-0.0682167187333107,
0.008390339091420174,
-0.026679689064621925,
0.0614762157201767,
0.07629826664924622,
-0.02239188179373741,
-0.019727442413568497,
0.024950450286269188,
-0.036772798746824265,
0.0449955090880394,
-0.006661099847406149,
0.008310934528708458,
-0.07418082654476166,
-0.012739904224872589,
-0.008954987861216068,
-0.040972378104925156,
-0.017680587247014046,
-0.0729103684425354,
-0.05332408845424652,
0.018474625423550606,
-0.024632833898067474,
-0.004404707346111536,
-0.0032070328015834093,
0.03977249935269356,
0.02911473996937275,
-0.009669622406363487,
0.017063003033399582,
0.002666645450517535,
0.06973421573638916,
-0.00937847513705492,
0.0005004095728509128,
0.02408583089709282,
-0.017848217859864235,
-0.04178406298160553,
-0.027967795729637146,
0.035678789019584656,
-0.051100779324769974,
-0.09980180114507675,
0.028073668479919434,
-0.05494745448231697,
0.03821971267461777,
-0.010719518177211285,
0.02189781330525875,
0.050994910299777985,
0.03463771939277649,
-0.05667669326066971,
-0.008915286511182785,
-0.009590218774974346,
0.022127201780676842,
-0.03497298061847687,
0.03507884964346886,
0.043054524809122086,
-0.02405053935945034,
0.05321821570396423,
-0.006312604993581772,
-0.04743055999279022,
0.06144092604517937,
-0.01387802604585886,
-0.03949017450213432,
-0.019303955137729645,
-0.005024498328566551,
0.016860080882906914,
0.007574243936687708,
0.006497880443930626,
-0.043548595160245895,
-0.026062102988362312,
-0.04016069695353508,
0.018651079386472702,
0.035943470895290375,
-0.08321522176265717,
-0.07862744480371475,
0.033067286014556885,
-0.052018336951732635,
0.038290295749902725,
0.05275943875312805,
-0.013869203627109528,
0.020592061802744865,
-0.012704613618552685,
0.04654829204082489,
0.018439335748553276,
-0.05759425088763237,
-0.02352118119597435,
0.010993019677698612,
-0.039384301751852036,
0.07954499870538712,
0.01939218118786812,
0.0496891550719738,
-0.0055626798421144485,
-0.025321001186966896,
-0.026009168475866318,
0.003076898632571101,
-0.022338945418596268,
0.028761833906173706,
0.015413166955113411,
0.02193310484290123,
0.0045701321214437485,
0.03867848962545395,
0.010543065145611763,
-0.019409826025366783,
-0.010110755451023579,
0.09210845082998276,
0.03135569393634796,
-0.006550816353410482,
-0.03507884964346886,
0.05021851509809494,
-0.019639216363430023,
-0.0017843806417658925,
0.06306429207324982,
0.08293289691209793,
0.021262582391500473,
-0.051100779324769974,
0.031514499336481094,
-0.040478311479091644,
0.042595747858285904,
-0.04961857572197914,
0.03807855024933815,
-0.00018541347526479512,
0.033631935715675354,
-0.030720463022589684,
-0.005924408324062824,
-0.03853732720017433,
0.02359176240861416,
-0.04566602781414986,
0.043548595160245895,
-0.02030973695218563,
0.007088998332619667,
0.006661099847406149,
-0.0261679757386446,
-0.0350082702934742,
-0.05960581451654434,
0.004184141289442778,
0.03396719694137573,
0.004989207722246647,
-0.03846674785017967,
0.058970581740140915,
-0.027367856353521347,
0.028603026643395424,
-0.00509507954120636,
-0.01611015573143959,
0.019109856337308884,
0.044254403561353683,
0.018351109698414803,
0.00031182548264041543,
0.13015171885490417,
0.019727442413568497,
0.05819419026374817,
-0.030914559960365295,
-0.05512390658259392,
0.008412395603954792,
0.012810485437512398,
0.029555872082710266,
0.015263182111084461,
0.019903894513845444,
-0.02170371636748314,
-0.0008436657954007387,
0.032202668488025665,
0.020521480590105057,
0.01617191545665264,
0.028338346630334854,
0.004565720446407795,
0.026750270277261734,
-0.008610905148088932,
-0.005430340301245451,
0.02500338666141033,
0.030579300597310066,
-0.01412506029009819,
-0.02756195329129696,
0.05374757573008537,
-0.05512390658259392,
-0.014301513321697712,
0.03192034363746643,
0.02911473996937275,
-0.015633733943104744,
-0.07072234898805618,
-0.07566303759813309,
0.03523765876889229,
0.006639042869210243,
0.008191829547286034,
-0.00987254362553358,
-0.0037121293134987354,
0.02382115088403225,
0.03377309814095497,
-0.012881066650152206,
-0.0458424836397171,
0.01531611755490303,
-0.032273247838020325,
0.0042591337114572525,
0.08497975021600723,
0.04333684965968132,
-0.021580198779702187,
0.01630425453186035,
0.011054778471589088,
-0.04658358544111252,
0.01219290029257536,
0.03476123511791229,
-0.02064499817788601,
-0.04658358544111252,
0.02170371636748314,
-0.04485434666275978,
0.0535358302295208,
0.0258680060505867,
0.02500338666141033,
-0.005677374545484781,
0.022038975730538368,
0.05819419026374817,
0.017918799072504044,
-0.014495611190795898,
-0.003132040146738291,
0.06804026663303375,
-0.039384301751852036,
-0.016648337244987488,
-0.08441510051488876,
-0.020203866064548492,
0.01875695027410984,
-0.03158508241176605,
0.03867848962545395,
0.03063223510980606,
-0.004336331970989704,
-0.04188993573188782,
0.05981755629181862,
0.014601483009755611,
0.02004505693912506,
0.036208149045705795,
-0.0012583303032442927,
-0.03559056296944618,
0.006122918333858252,
0.03229089453816414,
-0.005011264234781265,
0.0449955090880394,
0.019233373925089836,
0.0629231259226799,
0.0035444991663098335,
0.0345318466424942,
0.024191701784729958,
-0.02140374481678009,
-0.0055318004451692104,
-0.006246434990316629,
-0.03373780846595764,
-0.025550389662384987,
-0.017610006034374237,
-0.02465048059821129,
0.05039496719837189,
-0.030843978747725487,
-0.039843082427978516,
0.022621270269155502,
0.06429946422576904,
0.023503536358475685,
0.009916656650602818,
0.016321899369359016,
0.07622768729925156,
-0.058900002390146255,
0.030226394534111023,
-0.044113241136074066,
-0.00011379837815184146,
0.009740203619003296,
-0.009563750587403774,
-0.005117136053740978,
-0.01684243604540825,
-0.0643700435757637,
0.004031950607895851,
0.0057876575738191605,
-0.005646495148539543,
0.04915979877114296,
-0.031638018786907196,
-0.0708635151386261,
0.012219368480145931,
-0.016454240307211876,
0.00369668984785676,
0.006912545301020145,
-0.025285711511969566,
-0.028126602992415428,
0.0051215472631156445,
0.014407385140657425,
0.018386399373412132,
0.03262615576386452,
-0.029661744832992554,
-0.011292990297079086,
0.0382550023496151,
-0.029891133308410645,
-0.03160272538661957,
0.03599640727043152,
0.03184976056218147,
-0.01258991938084364,
-0.014019188471138477,
-0.04633655026555061,
0.05127723515033722,
0.0205744169652462,
0.06369952112436295,
0.007724228780716658,
-0.028003087267279625,
-0.006912545301020145,
-0.040407732129096985,
0.017848217859864235,
-0.007168401964008808,
0.025815069675445557,
0.024632833898067474,
-0.024826932698488235,
-0.008954987861216068,
-0.08010964840650558,
0.003926078788936138,
0.02745608240365982,
0.013851557858288288,
-0.004285601433366537,
-0.016886549070477486,
0.005328879691660404,
0.0008899846579879522,
-0.026291493326425552,
0.0005141950096003711,
-0.026415009051561356,
0.022180138155817986,
0.030843978747725487,
0.014530901797115803,
-0.044183824211359024,
-0.02696201391518116,
0.0623231902718544,
-0.06197028234601021,
0.06574637442827225,
-0.061617378145456314,
-0.027209049090743065,
-0.015210245735943317,
0.013586878776550293,
0.020521480590105057,
0.0019806846976280212,
-0.07044002413749695,
0.02722669392824173,
0.03747861087322235,
0.020768513903021812,
0.005487687420099974,
-0.10989490896463394,
-0.11780000478029251,
0.006802262272685766,
0.02405053935945034,
-0.002373292576521635,
0.0006942321779206395,
-0.06369952112436295,
0.008505033329129219,
-0.009519637562334538,
-0.04061947390437126,
0.051488976925611496,
-0.003963574767112732,
0.029220612719655037,
-0.002666645450517535,
-0.002677673939615488,
0.005430340301245451,
0.05755895748734474,
0.027103176340460777,
0.04121941328048706,
-0.021809587255120277,
-0.07890976965427399,
-0.021156711503863335,
-0.0000017964084690902382,
0.04983031749725342,
-0.03304964303970337,
0.042101677507162094,
-0.0018968693912029266,
-0.03184976056218147,
0.01253698393702507,
0.032432056963443756,
-0.018668724223971367,
-0.04859514907002449,
-0.08864997327327728,
0.0564296618103981,
-0.015704315155744553,
-0.002973232651129365,
0.006330250296741724,
0.018086429685354233,
0.01762765273451805,
0.043619174510240555,
0.08850880712270737,
0.04817166179418564,
-0.004203991964459419,
0.0376550629734993,
-0.0725574642419815,
-0.0019112062873318791,
-0.08194475620985031,
0.026379719376564026,
-0.031143950298428535,
0.011681186966598034,
0.0008370488067157567,
-0.040937088429927826,
0.00017934790230356157,
0.058970581740140915,
-0.016648337244987488,
0.0482422411441803,
0.027544308453798294,
0.007944795303046703,
-0.046265970915555954,
0.009528460912406445,
0.004958328325301409,
-0.05014793574810028,
-0.003076898632571101,
-0.04181935265660286,
0.008377104997634888,
0.022127201780676842,
0.04859514907002449,
0.010128400288522243,
0.0001447465765522793,
0.008050667122006416,
-0.0379020981490612,
-0.013119278475642204,
0.03047342784702778,
0.03641989454627037,
-0.025215130299329758,
-0.01009310968220234,
-0.023609407246112823,
0.013110456056892872,
0.047289397567510605,
-0.04400737211108208,
-0.02461518906056881,
-0.03252028301358223,
-0.019798023626208305,
0.00006558398308698088,
0.01690419390797615,
0.007966851815581322,
0.02461518906056881,
-0.03509649634361267,
-0.03659634664654732,
-0.022621270269155502,
-0.0561826266348362,
-0.02113906666636467,
0.0255680363625288,
0.027403146028518677,
-0.015254359692335129,
-0.014151528477668762,
0.047359976917505264,
-0.03747861087322235,
-0.017063003033399582,
-0.06461707502603531,
0.0029026514384895563,
0.011566492728888988,
0.02650323696434498,
-0.015492570586502552,
0.004856868181377649,
0.01714240573346615,
-0.024297574535012245,
-0.022568335756659508,
-0.025885650888085365,
-0.023574117571115494,
0.010587178170681,
0.024932805448770523,
0.00005579636126640253,
0.0012252453016117215,
-0.004091503098607063,
-0.014760291203856468,
0.031055722385644913,
0.018704015761613846,
0.04718352481722832,
0.04111354053020477,
0.0017711466643959284,
0.0342848114669323,
-0.04376033693552017,
0.005836181808263063,
0.04721881449222565,
-0.028038376942276955,
-0.009837253019213676,
0.023132985457777977,
-0.05565326660871506,
-0.017742346972227097,
-0.0202744472771883,
0.0034077479504048824,
-0.03945488482713699,
-0.01654246635735035,
0.03357899934053421,
0.01657775603234768,
0.004089297726750374,
0.09627274423837662,
-0.029891133308410645,
0.03327903151512146,
0.04693648964166641,
0.047854047268629074,
-0.07425141334533691,
-0.030579300597310066,
0.03663163632154465,
0.03694925084710121,
0.03361429274082184,
-0.014548547565937042,
-0.0535358302295208,
-0.0324849933385849,
0.029855843633413315,
0.06066453084349632,
0.03709041327238083,
-0.04111354053020477,
-0.0002897688536904752,
-0.010322499088943005,
0.04316039755940437,
-0.013754509389400482,
-0.0732632726430893,
0.0178658626973629,
0.040866509079933167,
0.10537771135568619,
-0.0431956872344017,
0.0073889680206775665,
0.004640713334083557,
0.04668945446610451,
0.013622169382870197,
-0.05067729204893112,
0.029361775144934654,
-0.018615787848830223,
0.05371228605508804,
-0.021827232092618942,
0.059994008392095566,
-0.015466103330254555,
-0.002748254919424653,
0.029450001195073128,
-0.010860680602490902,
-0.0242446381598711,
0.050994910299777985,
0.025779780000448227,
0.0033129046205431223,
0.016754209995269775,
-0.04065476357936859,
-0.02246246300637722,
-0.02877947874367237,
-0.005311234388500452,
-0.025091612711548805,
-0.03112630359828472,
-0.00006227548874448985,
0.021297873929142952,
0.013286909088492393,
-0.032767318189144135,
-0.011407684534788132,
-0.025726843625307083,
0.02011563815176487,
0.03709041327238083,
0.026838496327400208,
-0.027332564815878868,
0.0016002078773453832,
-0.05646495148539543,
0.05706489086151123,
0.006286137271672487,
-0.028832415118813515,
-0.01743355393409729,
-0.06242906302213669,
-0.022815369069576263,
0.05777070298790932,
-0.058935292065143585,
0.06197028234601021,
-0.008588848635554314,
0.039349012076854706,
0.02858538180589676,
0.024438736960291862,
-0.022850660607218742,
-0.06804026663303375,
0.010693049989640713,
-0.028955932706594467,
-0.004305452574044466,
-0.05650024116039276,
-0.029432356357574463,
-0.03516707569360733,
0.012457579374313354,
-0.07799221575260162,
0.02798544056713581,
-0.056394368410110474,
-0.026573818176984787,
0.017724700272083282,
-0.03744332119822502,
0.009616686962544918,
0.04647771269083023,
0.030420491471886635,
0.02038031816482544,
-0.031408630311489105,
0.052088916301727295,
0.048383403569459915,
-0.03199092298746109,
-0.028497155755758286,
-0.008915286511182785,
-0.02272714301943779,
-0.008760889992117882,
-0.004025333561003208,
0.051453687250614166,
-0.005845004692673683,
0.06909898668527603,
0.0535358302295208,
-0.023803506046533585,
-0.054665129631757736,
-0.0021152300760149956,
-0.02382115088403225,
0.02729727514088154,
-0.04873631149530411,
-0.02798544056713581,
0.054206352680921555,
-0.038325585424900055,
-0.012386998161673546,
-0.03142627328634262,
0.013039874844253063,
-0.09860192239284515,
-0.02302711270749569,
-0.03403778001666069,
0.02329179272055626,
-0.03966662660241127,
-0.0336848720908165,
0.027209049090743065,
0.012007624842226505,
-0.00803743302822113,
-0.00024262283113785088,
-0.006264080293476582,
-0.017063003033399582,
-0.025426873937249184,
-0.04287807270884514,
-0.02756195329129696,
0.04608951508998871,
0.011866462416946888,
0.02487986907362938,
0.04312510788440704,
-0.011972334235906601,
-0.042595747858285904,
0.039384301751852036,
0.019939186051487923,
0.02994406968355179,
-0.02742079086601734,
-0.03149685636162758,
0.018386399373412132,
-0.017292391508817673,
-0.041431158781051636,
0.00714634545147419,
0.003787121968343854,
-0.03604934364557266,
-0.013189859688282013,
-0.0016498352633789182,
0.033190805464982986,
0.045771900564432144,
0.03407306969165802,
0.027367856353521347,
-0.048383403569459915,
0.02904415875673294,
-0.001318985945545137,
-0.04284278303384781,
-0.05593559145927429,
-0.015413166955113411,
-0.003304081968963146,
-0.027367856353521347,
-0.05985284969210625,
-0.031973280012607574,
-0.0122723039239645,
0.011989979073405266,
-0.03184976056218147,
-0.012660500593483448,
-0.029026513919234276,
0.03158508241176605,
0.01935689151287079,
-0.08455626666545868,
0.009899011813104153,
-0.0012925179908052087,
-0.02583271451294422,
-0.006431710906326771,
0.022038975730538368,
-0.0035489103756844997,
-0.025726843625307083,
0.014636773616075516,
-0.030614590272307396,
-0.024174056947231293,
-0.029061803594231606,
-0.019003985449671745,
-0.005902351811528206,
-0.019603924825787544,
0.027861924842000008,
-0.04185464605689049,
0.06796968728303909,
-0.054206352680921555,
0.0005092322244308889,
-0.010013706050813198,
0.031214531511068344,
0.002876183483749628,
-0.0022960943169891834,
0.03698454424738884,
-0.01898634061217308,
0.04083121940493584,
0.04608951508998871,
0.04795991629362106,
-0.017883509397506714,
0.06182911992073059,
0.02666204422712326,
-0.06324074417352676,
0.10580120235681534,
0.02018621936440468,
0.02457989938557148,
0.007710994686931372,
-0.0051215472631156445,
0.0332084484398365,
0.02888535149395466,
-0.05830006301403046,
-0.0025034265127032995,
0.0020865562837570906,
-0.028126602992415428,
-0.03550233691930771
]
|
33,095 | bqplot.figure | save_svg |
Saves the Figure as an SVG file
Parameters
----------
filename: str (default: 'bqplot.svg')
name of the saved file
| def save_svg(self, filename='bqplot.svg'):
'''
Saves the Figure as an SVG file
Parameters
----------
filename: str (default: 'bqplot.svg')
name of the saved file
'''
self.send({"type": "save_svg", "filename": filename})
| (self, filename='bqplot.svg') | [
0.030860615894198418,
-0.035774946212768555,
-0.04536304250359535,
0.006782977841794491,
-0.053885798901319504,
0.0038833515718579292,
-0.0613088421523571,
0.041376594454050064,
0.04715007171034813,
-0.014906227588653564,
0.05594775453209877,
-0.05148018151521683,
0.013815108686685562,
0.01071358285844326,
-0.02575727365911007,
-0.0031809976790100336,
0.029589077457785606,
0.01500073354691267,
0.0024099117144942284,
0.04062054306268692,
0.007981490343809128,
-0.04938386008143425,
-0.022561240941286087,
-0.023506304249167442,
0.051720742136240005,
0.008557119406759739,
0.020705480128526688,
0.028351902961730957,
0.0020984704606235027,
0.0016227168962359428,
-0.03428002819418907,
-0.0938190221786499,
-0.011289211921393871,
0.01061907596886158,
0.0402425192296505,
0.049521323293447495,
-0.01049879565834999,
0.025190236046910286,
-0.041101668030023575,
-0.024812210351228714,
-0.01281849667429924,
0.004164722748100758,
0.055775925517082214,
-0.022217581048607826,
-0.01646987721323967,
0.011418084613978863,
-0.03226961940526962,
0.06388628482818604,
0.01382370013743639,
-0.057391125708818436,
0.042029548436403275,
0.02981245517730713,
-0.08000391721725464,
0.06350826472043991,
-0.03474396839737892,
0.02544798143208027,
0.04508811607956886,
0.04972751811146736,
0.00291036581620574,
0.012466245330870152,
0.04416023567318916,
0.0340566486120224,
0.055432263761758804,
-0.03290538862347603,
0.0383867584168911,
0.07313072681427002,
0.0017848811112344265,
-0.06618880480527878,
-0.048937100917100906,
0.003997188527137041,
0.03053414076566696,
-0.007788181770592928,
-0.04405713826417923,
0.01104005891829729,
-0.00497017428278923,
0.006306150462478399,
-0.009983306750655174,
-0.053026650100946426,
-0.07512395083904266,
0.024159258231520653,
0.0026354382280260324,
-0.05474494770169258,
0.0016613785410299897,
-0.08495260775089264,
-0.019897880032658577,
-0.00687318854033947,
0.07203101366758347,
0.035001713782548904,
-0.033575527369976044,
-0.04151405766606331,
0.04845597967505455,
0.02316264621913433,
-0.010859637521207333,
-0.01622931659221649,
0.024159258231520653,
-0.08859539777040482,
-0.01171878632158041,
-0.045191213488578796,
-0.035465653985738754,
-0.025860371068120003,
-0.05900632217526436,
-0.0017687721410766244,
-0.0060269273817539215,
-0.030637238174676895,
-0.000719536910764873,
-0.0012683180393651128,
0.03567184880375862,
-0.004385953303426504,
0.011289211921393871,
-0.0013316802214831114,
0.00017209819634445012,
0.04505375027656555,
0.012517794966697693,
0.005863688886165619,
0.03711521625518799,
-0.023849964141845703,
0.0018417997052893043,
-0.0018213950097560883,
0.05625704675912857,
-0.02792232856154442,
-0.07897293567657471,
0.032956939190626144,
-0.01854042522609234,
0.07629239559173584,
-0.023334475234150887,
0.037630707025527954,
0.07938532531261444,
0.06031223013997078,
-0.03848985582590103,
-0.00660255691036582,
0.011882024817168713,
0.010808088816702366,
-0.026925716549158096,
-0.008668809197843075,
0.050792861729860306,
-0.01739775761961937,
0.030791884288191795,
-0.00846690870821476,
-0.03409101441502571,
0.07285580039024353,
-0.0067958650179207325,
-0.05691000074148178,
-0.04969315230846405,
0.007049314212054014,
0.033575527369976044,
0.03570621460676193,
-0.0724434107542038,
-0.04591289907693863,
-0.032252438366413116,
-0.02551671303808689,
0.02312827855348587,
0.0625460147857666,
-0.07966025173664093,
-0.07093130797147751,
-0.02378123253583908,
-0.06739161163568497,
0.01445947028696537,
0.030843432992696762,
0.003468812443315983,
0.021306883543729782,
-0.006649809889495373,
0.029829638078808784,
0.04491628706455231,
-0.028901757672429085,
-0.0012608005199581385,
0.046428389847278595,
-0.015198337845504284,
0.06845695525407791,
-0.007182482164353132,
0.0396239310503006,
-0.00027465904713608325,
0.003724409034475684,
-0.06787274032831192,
0.02421080693602562,
-0.01671903021633625,
0.032029058784246445,
0.028592463582754135,
0.04041434824466705,
0.02216603234410286,
0.016521427780389786,
0.008286488242447376,
0.009888799861073494,
0.008960919454693794,
0.046084728091955185,
0.004398840479552746,
-0.03690902143716812,
-0.02780204825103283,
0.026461776345968246,
0.03780253604054451,
0.0013005360960960388,
0.04192645102739334,
0.06165250018239021,
0.032252438366413116,
-0.0008806272526271641,
0.05849083513021469,
-0.07897293567657471,
0.03780253604054451,
-0.03424566239118576,
-0.05178947374224663,
-0.016590159386396408,
0.03711521625518799,
-0.04051744565367699,
-0.018024936318397522,
-0.0402425192296505,
-0.013093424029648304,
-0.039830125868320465,
0.02625557966530323,
-0.054813679307699203,
0.02845500037074089,
0.036393534392118454,
-0.002162906574085355,
-0.039005346596241,
-0.0328194759786129,
0.010361331515014172,
0.03694338724017143,
0.034228477627038956,
-0.03321468457579613,
0.06460797041654587,
-0.01054175291210413,
-0.00809747539460659,
0.0018224689410999417,
0.00667987996712327,
0.017973387613892555,
0.05498550832271576,
-0.004370918497443199,
-0.05498550832271576,
0.1000048965215683,
-0.011246254667639732,
0.05151454731822014,
-0.047012608498334885,
0.006611148361116648,
0.051720742136240005,
0.031565118581056595,
0.008191981352865696,
-0.011787517927587032,
-0.008643034845590591,
0.00548136793076992,
-0.03290538862347603,
0.055122971534729004,
0.003294834867119789,
0.004489051178097725,
0.02213166654109955,
-0.028970489278435707,
0.01569664478302002,
0.012028079479932785,
-0.0060140397399663925,
0.019141830503940582,
0.013351168483495712,
0.024691930040717125,
-0.011632871814072132,
0.03649663180112839,
-0.03618733584880829,
-0.05732239410281181,
0.021719275042414665,
0.028248805552721024,
0.007775294594466686,
-0.08928272128105164,
-0.04783739149570465,
0.024193624034523964,
0.004121765028685331,
0.02690853364765644,
0.006628331262618303,
0.010129361413419247,
-0.00020445050904527307,
0.05343903973698616,
-0.03194314241409302,
-0.011615688912570477,
-0.0005356254405342042,
-0.02706317976117134,
0.006817343644797802,
0.03976139426231384,
0.030379492789506912,
-0.042338840663433075,
-0.015335801988840103,
0.029451612383127213,
-0.028661197051405907,
-0.05385143309831619,
0.03306003659963608,
-0.005812140181660652,
-0.025894736871123314,
0.025155870243906975,
-0.03914280980825424,
0.04278559982776642,
0.06797583401203156,
-0.01249202061444521,
0.03300848975777626,
0.027424022555351257,
0.02737247385084629,
0.047940488904714584,
-0.039245907217264175,
0.022836169227957726,
0.07154989242553711,
-0.03390200063586235,
-0.056050851941108704,
-0.059556178748607635,
-0.033180318772792816,
0.026496142148971558,
-0.027905145660042763,
0.019983796402812004,
0.0402425192296505,
0.07292453199625015,
-0.002521601039916277,
0.051411449909210205,
-0.019313659518957138,
-0.013187930919229984,
0.04464136064052582,
0.034417491406202316,
-0.020138442516326904,
0.024107709527015686,
0.02266433835029602,
-0.03718395158648491,
0.021994203329086304,
0.011074424721300602,
0.049521323293447495,
0.04292306303977966,
0.045122481882572174,
0.028248805552721024,
-0.07319945842027664,
0.020688297227025032,
-0.03046540729701519,
-0.013076241128146648,
-0.029314149171113968,
-0.009811476804316044,
-0.031908776611089706,
-0.023953061550855637,
0.0032626166939735413,
-0.06612007319927216,
0.04161715507507324,
0.018969999626278877,
-0.011108790524303913,
0.014742989093065262,
0.026461776345968246,
0.04536304250359535,
-0.01761254481971264,
0.05000244826078415,
-0.026015019044280052,
0.01548185758292675,
0.0025989243295043707,
-0.0094420425593853,
0.028970489278435707,
0.016048895195126534,
-0.023197012022137642,
0.012036671862006187,
0.006276080384850502,
-0.039005346596241,
0.0430261604487896,
-0.06825076043605804,
-0.04412586987018585,
0.005365382879972458,
-0.007749520242214203,
-0.023231377825140953,
0.03659972921013832,
-0.007736633066087961,
0.002841633977368474,
-0.01096273586153984,
0.008866413496434689,
0.028369085863232613,
0.04800922051072121,
-0.018626341596245766,
0.005829323083162308,
0.022217581048607826,
-0.03080906718969345,
-0.023678135126829147,
0.009605281054973602,
0.023849964141845703,
-0.04306052625179291,
0.022183215245604515,
-0.025276150554418564,
0.02185674011707306,
-0.01922774501144886,
0.07113750278949738,
0.018282681703567505,
-0.05027737468481064,
-0.021977020427584648,
0.013041875325143337,
0.056050851941108704,
0.001650639227591455,
-0.0015808333409950137,
0.001096488325856626,
-0.0609995499253273,
-0.01764691062271595,
-0.06333643198013306,
-0.0012393217766657472,
0.018093667924404144,
0.02579163946211338,
-0.006898962892591953,
0.02551671303808689,
-0.0008655921556055546,
0.00004560870729619637,
-0.013986938633024693,
0.0027342403773218393,
-0.06818202883005142,
0.021805191412568092,
0.04491628706455231,
0.011340760625898838,
-0.04635965824127197,
-0.027080362662672997,
0.05031174048781395,
0.003670712234452367,
0.039005346596241,
-0.05526043474674225,
-0.0187294390052557,
-0.03340369462966919,
-0.0038360983598977327,
0.006989173591136932,
-0.02641022764146328,
-0.07216847687959671,
0.0159457977861166,
0.032682012766599655,
-0.012371739372611046,
0.0077795903198421,
-0.06993469595909119,
-0.09230691939592361,
0.004119617398828268,
0.02158181183040142,
0.017904656007885933,
-0.000470652332296595,
-0.027355290949344635,
0.02049928531050682,
0.041101668030023575,
-0.06337080150842667,
0.05316411331295967,
0.007319945842027664,
0.04824978485703468,
0.0187294390052557,
-0.003466664580628276,
-0.038558587431907654,
0.03134173899888992,
0.03505326062440872,
0.08117235451936722,
0.028936123475432396,
-0.016976775601506233,
-0.05343903973698616,
-0.010137952864170074,
0.03848985582590103,
0.0018085077172145247,
0.012973143719136715,
-0.04543177783489227,
-0.01938239112496376,
0.055535364896059036,
0.016804946586489677,
-0.0034129677806049585,
-0.05989983677864075,
-0.07622366398572922,
0.047631196677684784,
-0.0408611074090004,
-0.035603117197752,
0.029245417565107346,
0.06636063754558563,
-0.0005622053286060691,
0.020705480128526688,
0.041067302227020264,
0.048593442887067795,
-0.01374637708067894,
0.025001224130392075,
-0.051136523485183716,
0.022269131615757942,
-0.0833030417561531,
0.02895330637693405,
-0.010241051204502583,
-0.01817958429455757,
-0.0010331261437386274,
-0.042613767087459564,
-0.03711521625518799,
0.032063424587249756,
-0.004390249028801918,
0.020946042612195015,
-0.006417839787900448,
-0.0027084657922387123,
-0.031032446771860123,
0.04254503548145294,
-0.04034561663866043,
-0.04708134010434151,
-0.04041434824466705,
-0.0005270339315757155,
0.02154744602739811,
0.0024743478279560804,
0.03065442107617855,
-0.01154695637524128,
-0.008986693806946278,
0.005442705936729908,
-0.018248315900564194,
-0.030224846675992012,
0.04625655710697174,
0.07113750278949738,
0.03177131339907646,
-0.012191317975521088,
-0.024846576154232025,
0.026049384847283363,
0.025774456560611725,
-0.0036943387240171432,
-0.05474494770169258,
-0.04065490886569023,
-0.021598994731903076,
0.0761549323797226,
0.04938386008143425,
0.024451367557048798,
0.0318915955722332,
-0.03390200063586235,
-0.05632577836513519,
-0.011761743575334549,
-0.05845646932721138,
-0.03821492940187454,
0.043885309249162674,
0.009802885353565216,
-0.020258722826838493,
0.0015980163589119911,
0.05003681406378746,
-0.0027922329027205706,
-0.02551671303808689,
-0.06694485992193222,
0.019159013405442238,
0.045775435864925385,
0.05529480054974556,
-0.012002305127680302,
-0.014081444591283798,
0.007745224516838789,
0.01360891293734312,
-0.017191562801599503,
-0.023609403520822525,
-0.02737247385084629,
-0.04429769888520241,
0.008368107490241528,
-0.02390151284635067,
-0.03464087098836899,
-0.000909086549654603,
-0.03285384178161621,
0.02421080693602562,
0.013256662525236607,
0.01783592440187931,
0.04660021886229515,
0.021358434110879898,
0.04254503548145294,
-0.029864003881812096,
0.005636014509946108,
0.042029548436403275,
0.04677204787731171,
-0.01133216917514801,
0.010284008458256721,
-0.05649761110544205,
0.00969119556248188,
-0.04068927466869354,
-0.036393534392118454,
0.00009511043026577681,
-0.01864352449774742,
0.04216701164841652,
0.027045996859669685,
-0.031908776611089706,
0.09766800701618195,
-0.034194111824035645,
-0.0025645585265010595,
0.045500509440898895,
0.04852471128106117,
-0.06330206990242004,
-0.006447909865528345,
-0.006782977841794491,
0.02470911294221878,
0.022956449538469315,
0.003823211183771491,
-0.03742451220750809,
-0.05123962089419365,
0.018523242324590683,
0.045809801667928696,
0.01643551141023636,
-0.027097545564174652,
0.01650424487888813,
-0.00033318856731057167,
0.010782314464449883,
0.010060629807412624,
-0.07031271606683731,
0.0678040012717247,
0.031169909983873367,
0.09354409575462341,
-0.061102647334337234,
0.003436594270169735,
0.03108399547636509,
0.04660021886229515,
-0.0034129677806049585,
-0.048868369311094284,
0.03910844400525093,
-0.007289875764399767,
0.038902245461940765,
-0.023987427353858948,
0.06955666840076447,
-0.023231377825140953,
0.041754622012376785,
0.01079090591520071,
0.026272762566804886,
-0.002452869201079011,
0.04543177783489227,
-0.016306640580296516,
-0.03178849816322327,
0.04570670425891876,
-0.03945210203528404,
-0.00865162629634142,
-0.0038382462225854397,
0.02854091487824917,
-0.03866168484091759,
-0.06862878799438477,
-0.010782314464449883,
0.008935145102441311,
0.04319798946380615,
0.022303497418761253,
0.02127251774072647,
-0.01761254481971264,
0.020104076713323593,
0.009038242511451244,
0.047974854707717896,
-0.015292844735085964,
-0.006976286415010691,
-0.03166821599006653,
0.038867879658937454,
0.00978570245206356,
-0.03000146709382534,
-0.012156952172517776,
-0.009416268207132816,
-0.005996856838464737,
0.05123962089419365,
-0.07175608724355698,
0.07972898334264755,
0.001896570436656475,
0.004570670425891876,
-0.007758111692965031,
-0.005352495703846216,
-0.025035589933395386,
-0.08928272128105164,
0.011899207718670368,
-0.0022681523114442825,
-0.023849964141845703,
-0.050724130123853683,
-0.020636748522520065,
-0.09340663254261017,
0.020258722826838493,
-0.1006234809756279,
0.052614256739616394,
-0.029022037982940674,
-0.04385094344615936,
0.021135054528713226,
-0.07258087396621704,
-0.01776719279587269,
0.02548234723508358,
0.047321904450654984,
0.012268641963601112,
-0.021942654624581337,
0.041376594454050064,
0.024382635951042175,
-0.045122481882572174,
-0.012638075277209282,
0.0024356862995773554,
-0.023334475234150887,
0.013230888172984123,
-0.02714909426867962,
-0.008230643346905708,
-0.01061907596886158,
0.08254699409008026,
0.05825027450919151,
-0.02501840703189373,
-0.08474641293287277,
0.020052528008818626,
0.0024958266876637936,
0.01662452518939972,
-0.01637537218630314,
-0.023506304249167442,
0.0786292776465416,
-0.04543177783489227,
-0.030379492789506912,
-0.011143157258629799,
0.02988118678331375,
-0.07374931126832962,
-0.03780253604054451,
-0.031187092885375023,
0.027664583176374435,
-0.041067302227020264,
-0.02158181183040142,
-0.019313659518957138,
-0.021409982815384865,
0.023145461454987526,
-0.003333496395498514,
0.010318374261260033,
-0.006172982510179281,
-0.03725268319249153,
0.0054770722053945065,
-0.0038081759121268988,
-0.002751423278823495,
-0.001733332290314138,
-0.034572139382362366,
0.036977753043174744,
0.003737296210601926,
-0.05873139575123787,
0.036393534392118454,
-0.01146963331848383,
-0.0017064838903024793,
-0.016014529392123222,
-0.0001896838948596269,
0.03464087098836899,
-0.025258967652916908,
0.008716062642633915,
-0.014407921582460403,
0.0026332903653383255,
-0.010558935813605785,
0.03046540729701519,
-0.022990815341472626,
0.03328341618180275,
0.007861209101974964,
0.0017891768366098404,
0.009553732350468636,
-0.039864491671323776,
0.015842700377106667,
-0.018849719315767288,
-0.007225439418107271,
-0.05742549151182175,
-0.07258087396621704,
-0.017011141404509544,
0.01513819769024849,
-0.0196573194116354,
-0.008840639144182205,
-0.052614256739616394,
-0.015584954991936684,
-0.006520937662571669,
-0.015163972042500973,
-0.048902735114097595,
0.0020157773979008198,
0.01934802532196045,
-0.016495652496814728,
-0.016177767887711525,
-0.00411102594807744,
0.018059302121400833,
0.018780987709760666,
0.02139279991388321,
0.006061293184757233,
-0.0371495857834816,
-0.008196277543902397,
-0.06498599797487259,
-0.02529333345592022,
-0.0036857472732663155,
-0.018832536414265633,
0.0022123076487332582,
-0.018093667924404144,
-0.0029876891057938337,
-0.005588761530816555,
0.03214934095740318,
-0.02854091487824917,
-0.016031712293624878,
-0.052992284297943115,
0.013754968531429768,
-0.0066584013402462006,
-0.007367198821157217,
0.014614117331802845,
-0.032338351011276245,
0.06522656232118607,
0.039245907217264175,
0.0841965600848198,
-0.010223868303000927,
0.054882410913705826,
0.014485244639217854,
0.005086159333586693,
0.0907260850071907,
0.017698461189866066,
0.017011141404509544,
0.018368596211075783,
-0.008625851944088936,
0.02625557966530323,
0.001034200075082481,
-0.08075996488332748,
0.04663458466529846,
0.010378514416515827,
-0.02436545304954052,
-0.0424075722694397
]
|
33,109 | bqplot.marks | FlexLine | Flexible Lines mark.
In the case of the FlexLines mark, scales for 'x' and 'y' MUST be provided.
Scales for the color and width data attributes are optional. In the case
where another data attribute than 'x' or 'y' is provided but the
corresponding scale is missing, the data attribute is ignored.
Attributes
----------
name: string (class-level attributes)
user-friendly name of the mark
colors: list of colors (default: CATEGORY10)
List of colors for the Lines
stroke_width: float (default: 1.5)
Default stroke width of the Lines
Data Attributes
x: numpy.ndarray (default: [])
abscissas of the data points (1d array)
y: numpy.ndarray (default: [])
ordinates of the data points (1d array)
color: numpy.ndarray or None (default: None)
Array controlling the color of the data points
width: numpy.ndarray or None (default: None)
Array controlling the widths of the Lines.
| class FlexLine(Mark):
"""Flexible Lines mark.
In the case of the FlexLines mark, scales for 'x' and 'y' MUST be provided.
Scales for the color and width data attributes are optional. In the case
where another data attribute than 'x' or 'y' is provided but the
corresponding scale is missing, the data attribute is ignored.
Attributes
----------
name: string (class-level attributes)
user-friendly name of the mark
colors: list of colors (default: CATEGORY10)
List of colors for the Lines
stroke_width: float (default: 1.5)
Default stroke width of the Lines
Data Attributes
x: numpy.ndarray (default: [])
abscissas of the data points (1d array)
y: numpy.ndarray (default: [])
ordinates of the data points (1d array)
color: numpy.ndarray or None (default: None)
Array controlling the color of the data points
width: numpy.ndarray or None (default: None)
Array controlling the widths of the Lines.
"""
# Mark decoration
icon = 'fa-line-chart'
name = 'Flexible lines'
# Scaled attributes
x = Array([]).tag(sync=True, scaled=True, rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
y = Array([]).tag(sync=True, scaled=True,
rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
color = Array(None, allow_none=True)\
.tag(sync=True, scaled=True, rtype='Color',
atype='bqplot.ColorAxis',
**array_serialization).valid(array_squeeze)
width = Array(None, allow_none=True)\
.tag(sync=True, scaled=True, rtype='Number',
**array_serialization).valid(array_squeeze)
# Other attributes
scales_metadata = Dict({
'x': {'orientation': 'horizontal', 'dimension': 'x'},
'y': {'orientation': 'vertical', 'dimension': 'y'},
'color': {'dimension': 'color'}
}).tag(sync=True)
stroke_width = Float(1.5).tag(sync=True, display_name='Stroke width')
colors = List(trait=Color(default_value=None, allow_none=True),
default_value=CATEGORY10).tag(sync=True)
_view_name = Unicode('FlexLine').tag(sync=True)
_model_name = Unicode('FlexLineModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.035081665962934494,
-0.027539560571312904,
-0.018184449523687363,
0.06425293534994125,
-0.011149986647069454,
-0.023061435669660568,
-0.06722626090049744,
0.0022322635632008314,
0.0030549149960279465,
-0.007474117446690798,
0.022898266091942787,
0.016489289700984955,
0.03738418221473694,
0.004518917296081781,
-0.00673078466206789,
-0.005720033776015043,
-0.003963684197515249,
-0.014576568268239498,
0.0543176606297493,
0.032035816460847855,
0.05123554915189743,
-0.0005994251114316285,
-0.004185777623206377,
0.011512587778270245,
0.030404111370444298,
0.04093767702579498,
0.06341894716024399,
0.015664372593164444,
0.011059336364269257,
-0.009744906798005104,
-0.056747086346149445,
0.008262774907052517,
-0.030911752954125404,
0.021012740209698677,
0.03555304929614067,
-0.05315733700990677,
-0.015800347551703453,
-0.01842014119029045,
-0.054825302213430405,
0.01205648947507143,
0.015691567212343216,
0.02567216567695141,
0.09659695625305176,
-0.02864549495279789,
0.013071773573756218,
-0.0006708122091367841,
-0.01171201840043068,
0.039777349680662155,
-0.03665897995233536,
-0.03934222832322121,
0.06874918937683105,
-0.05497034266591072,
0.018447335809469223,
0.038580767810344696,
-0.05312107503414154,
0.03250719606876373,
0.03138313442468643,
0.09456638991832733,
-0.01869209110736847,
0.002649255096912384,
-0.012400960549712181,
0.027702732011675835,
0.027340130880475044,
-0.029225656762719154,
-0.05043782666325569,
0.003909294027835131,
0.0130173834040761,
0.005380095448344946,
0.01720542646944523,
0.02351468801498413,
0.008978912606835365,
0.02070452831685543,
-0.02074078842997551,
0.007152308709919453,
0.00868429895490408,
0.009581736288964748,
-0.06135212257504463,
0.01643489859998226,
0.021175909787416458,
-0.043911006301641464,
0.025128263980150223,
0.047355715185403824,
0.036894671618938446,
-0.03254345804452896,
0.01961672492325306,
-0.04024873301386833,
0.02844606339931488,
0.06835032254457474,
-0.01657087542116642,
0.024221759289503098,
-0.049168720841407776,
0.046557992696762085,
0.01424116175621748,
0.03734792396426201,
-0.01386043056845665,
-0.052903514355421066,
0.01776745915412903,
-0.029461346566677094,
-0.03611508011817932,
0.05471652001142502,
0.02507387287914753,
-0.018945911899209023,
0.022716965526342392,
0.009917142800986767,
-0.04663051292300224,
0.0005625984049402177,
-0.03586125746369362,
-0.0026696512941271067,
-0.009291655384004116,
0.04489002749323845,
0.0012827017344534397,
-0.00876588374376297,
-0.03731166198849678,
0.005656578578054905,
-0.03410264104604721,
0.026288587599992752,
-0.03923344984650612,
-0.014712543226778507,
0.024493711069226265,
-0.0189821720123291,
-0.013534089550375938,
0.023695988580584526,
-0.014567502774298191,
0.0031455655116587877,
-0.012754497118294239,
0.004790868144482374,
0.03248906880617142,
0.06697244197130203,
-0.0018039409769698977,
-0.061642203480005264,
0.01490290928632021,
-0.0002878147060982883,
-0.021937372162938118,
-0.015292705968022346,
0.02017875760793686,
-0.0012056489940732718,
0.07832185924053192,
0.017649613320827484,
-0.06497813761234283,
0.04416482523083687,
0.038617026060819626,
-0.001828869804739952,
-0.004285492934286594,
-0.04003117233514786,
-0.0857914462685585,
-0.0038753002882003784,
0.03156443312764168,
-0.013697260059416294,
-0.04304076358675957,
0.003909294027835131,
-0.03948726877570152,
-0.02639736793935299,
0.03948726877570152,
-0.003324599703773856,
0.05036530643701553,
0.01382417045533657,
-0.06715374439954758,
-0.032924190163612366,
0.054027579724788666,
0.05036530643701553,
-0.06320139020681381,
-0.02123030088841915,
0.018964042887091637,
-0.018474530428647995,
-0.008697896264493465,
0.04300450161099434,
-0.05420887842774391,
-0.05729098990559578,
-0.04061133414506912,
0.05493408069014549,
0.03992239385843277,
-0.03948726877570152,
0.002769366605207324,
0.013987340964376926,
-0.007999888621270657,
0.0520695336163044,
0.016389574855566025,
0.04035751521587372,
0.018429206684231758,
0.01169388834387064,
-0.01981615461409092,
0.014467787928879261,
0.014893843792378902,
0.01299925334751606,
-0.014431527815759182,
0.000016058558685472235,
0.0003016955161001533,
-0.031999554485082626,
0.03916092962026596,
0.009590801782906055,
0.023659728467464447,
0.024693140760064125,
0.01746831275522709,
-0.020450707525014877,
-0.06602967530488968,
-0.0007869579130783677,
0.021411601454019547,
-0.029551997780799866,
0.0007263355073519051,
-0.038254424929618835,
-0.01410518679767847,
0.024729400873184204,
0.038218166679143906,
0.008335295133292675,
0.008507530204951763,
0.0004583505797199905,
0.02993272989988327,
0.009309785440564156,
-0.1037764623761177,
0.010624215006828308,
-0.027140699326992035,
-0.014775998890399933,
-0.05497034266591072,
0.00010800133168231696,
0.057508550584316254,
-0.06911178678274155,
0.02675996907055378,
0.042025480419397354,
-0.00712058087810874,
0.02113964967429638,
0.07781421393156052,
-0.02599850669503212,
-0.002694580238312483,
0.036532070487737656,
0.015755021944642067,
-0.026107287034392357,
0.09442134946584702,
-0.0018424673471599817,
0.01123157236725092,
-0.035081665962934494,
-0.049204982817173004,
-0.044237345457077026,
-0.000014783789083594456,
0.017187297344207764,
-0.019689245149493217,
0.008203851990401745,
0.05714594945311546,
0.004618632607161999,
-0.04068385437130928,
-0.0019002569606527686,
0.029823947697877884,
0.032833538949489594,
-0.008729623630642891,
0.0036486745811998844,
-0.03138313442468643,
0.008743221871554852,
0.056710828095674515,
0.022807614877820015,
-0.06182350590825081,
-0.0447087287902832,
-0.03952353075146675,
-0.00004964520485373214,
0.04285946115851402,
0.03390321135520935,
0.019326644018292427,
-0.010044053196907043,
-0.006137025076895952,
-0.07135991752147675,
0.009935272857546806,
-0.0388345867395401,
-0.00559765612706542,
-0.060083020478487015,
0.009454825893044472,
0.08731436729431152,
0.061062041670084,
0.03803686425089836,
0.018139125779271126,
0.009105823002755642,
-0.020251277834177017,
0.03493662551045418,
0.002354641444981098,
0.04093767702579498,
-0.015718761831521988,
-0.003224884392693639,
-0.0014186771586537361,
0.054498959332704544,
0.00470475060865283,
-0.0322171151638031,
-0.00508548179641366,
0.02146599069237709,
-0.02804720215499401,
-0.06958317011594772,
-0.0003713829501066357,
0.0015501200687140226,
0.04793587699532509,
-0.07955469936132431,
0.003628278151154518,
-0.03473719581961632,
-0.048878639936447144,
-0.00022152667224872857,
-0.014041731134057045,
0.018909651786088943,
-0.005357432644814253,
-0.02656053751707077,
0.054462701082229614,
-0.028917444869875908,
0.004546112380921841,
0.019109083339571953,
-0.024022329598665237,
-0.05739976838231087,
0.049567583948373795,
-0.021375341340899467,
0.12197904288768768,
0.022445013746619225,
-0.027593951672315598,
-0.029352566227316856,
0.03526296839118004,
-0.01736859790980816,
0.035643696784973145,
0.013434374704957008,
0.030385980382561684,
0.09188314527273178,
-0.04648547247052193,
-0.040430035442113876,
-0.05718220770359039,
0.030476631596684456,
0.012972057797014713,
0.03700345382094383,
0.017975954338908195,
0.04717441648244858,
-0.020632008090615273,
-0.10363142192363739,
-0.04365718364715576,
-0.05272221565246582,
0.06479683518409729,
0.029461346566677094,
0.02960638701915741,
-0.011367547325789928,
0.006467898841947317,
0.02755769155919552,
0.03442898392677307,
-0.00158977962564677,
-0.027249479666352272,
0.0072338939644396305,
-0.02695939876139164,
-0.0821654349565506,
-0.0027806980069726706,
-0.007029930595308542,
-0.024783791974186897,
-0.039414748549461365,
0.011766408570110798,
-0.01941729336977005,
-0.04964010417461395,
0.019145343452692032,
-0.02527330443263054,
0.0032588783651590347,
0.036205731332302094,
-0.010116573423147202,
0.016579939052462578,
0.12139888107776642,
0.011521653272211552,
-0.009214603342115879,
-0.00026118618552573025,
0.002253793179988861,
0.018166320398449898,
-0.07426072657108307,
-0.018837131559848785,
-0.07447828352451324,
-0.011476327665150166,
0.004285492934286594,
0.02206428349018097,
-0.02126656100153923,
-0.00987181719392538,
0.07469584792852402,
-0.02162916213274002,
-0.016860956326127052,
-0.049168720841407776,
-0.029515737667679787,
0.08716932684183121,
0.02732199989259243,
0.0033155346754938364,
-0.004226570017635822,
-0.005416355561465025,
-0.0017189562786370516,
0.0036962658632546663,
0.01958046481013298,
0.01311709824949503,
0.018501726910471916,
0.0041971090249717236,
-0.021520381793379784,
-0.00026628526393324137,
-0.04362092539668083,
0.004222037736326456,
0.006318326108157635,
-0.020559487864375114,
-0.008357957936823368,
0.0064135086722671986,
-0.04416482523083687,
0.0037189284339547157,
-0.01709664613008499,
0.051090508699417114,
-0.044998809695243835,
0.01997932605445385,
-0.0379643440246582,
-0.0992802083492279,
-0.03615133836865425,
-0.0011716551380231977,
0.04180791974067688,
0.007999888621270657,
-0.04742823541164398,
-0.04434612765908241,
-0.03651393949985504,
0.05420887842774391,
-0.007011800538748503,
-0.006662797182798386,
-0.031201833859086037,
0.06425293534994125,
0.04862482100725174,
0.0025631373282521963,
0.12415464967489243,
0.009187407791614532,
-0.0033042035065591335,
-0.0088973268866539,
-0.036006297916173935,
-0.001160323852673173,
-0.04173539951443672,
0.017214491963386536,
-0.03049476072192192,
-0.018673961982131004,
0.012047424912452698,
-0.027539560571312904,
0.06051814183592796,
0.015691567212343216,
0.012283115647733212,
0.006069037597626448,
-0.058995213359594345,
-0.05043782666325569,
0.018139125779271126,
0.023242736235260963,
-0.008326229639351368,
0.025708425790071487,
-0.031238093972206116,
-0.03393947333097458,
-0.03627825155854225,
-0.052613433450460434,
-0.01739579252898693,
-0.007927368395030499,
-0.05620318651199341,
0.011929579079151154,
-0.04978514462709427,
0.03413890302181244,
-0.013552219606935978,
0.04717441648244858,
-0.0455789715051651,
-0.010678605176508427,
-0.04253312200307846,
-0.05551424250006676,
0.007478649728000164,
-0.007777795661240816,
-0.06222236528992653,
0.00712058087810874,
0.10805515944957733,
0.029751427471637726,
-0.015038885176181793,
0.015174860134720802,
-0.06425293534994125,
-0.0005226556095294654,
-0.12089124321937561,
0.008484868332743645,
0.021411601454019547,
0.010624215006828308,
0.01207461953163147,
-0.04985766485333443,
-0.043838486075401306,
0.02070452831685543,
0.014993559569120407,
0.007088853511959314,
-0.0009750573080964386,
-0.03992239385843277,
-0.04851603880524635,
0.033214271068573,
-0.04518010839819908,
0.010515434667468071,
-0.002839620690792799,
0.0284098032861948,
0.048080917447805405,
0.021284690126776695,
0.0012827017344534397,
-0.05761732906103134,
0.007845783606171608,
0.01905469223856926,
-0.05950285494327545,
0.004673022776842117,
0.007315479218959808,
0.024258019402623177,
0.07948218286037445,
0.009214603342115879,
-0.03763800486922264,
-0.006073569878935814,
0.0408288948237896,
-0.03999491408467293,
0.047645796090364456,
-0.010488240048289299,
0.06240366771817207,
0.007301881443709135,
0.027974681928753853,
0.08463112264871597,
-0.034592155367136,
0.015836607664823532,
-0.039777349680662155,
-0.014794128946959972,
-0.04481750726699829,
-0.0226625744253397,
-0.013660999946296215,
0.052867256104946136,
-0.02159290201961994,
-0.033721912652254105,
0.039777349680662155,
-0.02708631008863449,
-0.02844606339931488,
-0.08347079902887344,
-0.010678605176508427,
0.07273779809474945,
0.008344359695911407,
-0.020051846280694008,
0.004296824336051941,
-0.0408288948237896,
0.05243213474750519,
0.02808346226811409,
-0.013951080851256847,
-0.00008158526907209307,
0.045470189303159714,
-0.013180553913116455,
-0.0711786150932312,
-0.03720288351178169,
0.04028499498963356,
-0.00977210234850645,
-0.02804720215499401,
0.04173539951443672,
0.03325052931904793,
0.04441864788532257,
-0.033196140080690384,
0.03535361588001251,
0.022245584055781364,
0.0012940330198034644,
0.051416851580142975,
-0.04449116811156273,
0.028953704982995987,
0.021792331710457802,
-0.012129009701311588,
0.030621672049164772,
0.01047010999172926,
-0.0006787441088818014,
-0.01997932605445385,
-0.009899012744426727,
0.027775252237915993,
0.04927750304341316,
0.0019693777430802584,
0.041227757930755615,
-0.009074094705283642,
0.0088973268866539,
0.03136500343680382,
0.024022329598665237,
-0.0023025176487863064,
0.01990680582821369,
0.009092224761843681,
-0.006096232682466507,
-0.031600695103406906,
0.026270456612110138,
0.010025923140347004,
0.02259005419909954,
0.0711786150932312,
0.02540021389722824,
-0.04666677489876747,
-0.035208575427532196,
0.0039410218596458435,
-0.005284912418574095,
0.03343183174729347,
0.020450707525014877,
0.006010114680975676,
0.02106712944805622,
-0.0020724923815578222,
0.00014454474148806185,
0.05391879752278328,
0.03198142722249031,
0.04057507589459419,
0.00002669934656296391,
-0.005919464398175478,
-0.09123045951128006,
-0.045724011957645416,
-0.008466738276183605,
0.0511992909014225,
-0.031002402305603027,
-0.07469584792852402,
-0.001360887661576271,
0.002916673431172967,
-0.028790535405278206,
0.023496557027101517,
-0.014322747476398945,
-0.022281844168901443,
-0.03774678334593773,
0.01921786367893219,
-0.026107287034392357,
0.01205648947507143,
0.026850618422031403,
0.03337743878364563,
0.002019235398620367,
-0.02844606339931488,
0.0008991376380436122,
0.005942127201706171,
-0.03926970809698105,
0.03410264104604721,
-0.04271442070603371,
0.033486220985651016,
0.017704004421830177,
-0.02074078842997551,
0.009282590821385384,
-0.045724011957645416,
-0.0543176606297493,
-0.025780946016311646,
-0.013660999946296215,
0.020722659304738045,
-0.017649613320827484,
-0.023732248693704605,
0.005108144599944353,
-0.05885017290711403,
-0.05043782666325569,
0.02636110782623291,
0.019634854048490524,
-0.020758919417858124,
0.042388081550598145,
0.0047682058066129684,
0.014839453622698784,
-0.008067877031862736,
-0.007714340463280678,
-0.002728573977947235,
0.02507387287914753,
-0.05515164136886597,
-0.010252549313008785,
-0.049930185079574585,
0.04978514462709427,
0.03522670641541481,
0.021175909787416458,
-0.06483309715986252,
0.03506353497505188,
-0.004525716416537762,
-0.01627172902226448,
0.01171201840043068,
0.029080616310238838,
0.015310836024582386,
-0.015963517129421234,
-0.01994306594133377,
-0.007220296189188957,
0.024421190842986107,
-0.01785810850560665,
-0.029388826340436935,
-0.0195442046970129,
-0.02917126566171646,
0.03731166198849678,
0.0498214066028595,
-0.04032125324010849,
0.013334658928215504,
-0.02423989027738571,
-0.023442167788743973,
0.04518010839819908,
0.0821654349565506,
0.0013586214045062661,
-0.03618760034441948,
-0.007029930595308542,
-0.026143547147512436,
-0.04285946115851402,
-0.02278948575258255,
-0.017722133547067642,
0.001425475929863751,
0.029153136536478996,
-0.06650105863809586,
0.03642329201102257,
0.017903434112668037,
0.04898742213845253,
-0.0030753114260733128,
-0.05739976838231087,
0.026143547147512436,
-0.03310548886656761,
-0.010343199595808983,
-0.014875713735818863,
-0.03263410925865173,
0.021574771031737328,
-0.013325594365596771,
0.036695241928100586,
-0.018075669184327126,
-0.012546001933515072,
-0.010397589765489101,
-0.04256938025355339,
0.09608931839466095,
-0.0069710081443190575,
-0.006762512493878603,
0.03410264104604721,
-0.02431241050362587,
-0.04293198138475418,
0.015573721379041672,
0.04188043996691704,
-0.003775584977120161,
0.03767426311969757,
-0.013053643517196178,
-0.00830356776714325,
-0.06294757127761841,
-0.058596353977918625,
-0.03141939267516136,
0.016036037355661392,
-0.015174860134720802,
0.032072074711322784,
-0.030585411936044693,
-0.03141939267516136,
0.04285946115851402,
-0.0034923027269542217,
0.033957600593566895,
-0.047283194959163666,
-0.016226403415203094,
0.0005733631551265717,
0.0008288836688734591,
0.03263410925865173,
0.07426072657108307,
0.05609440430998802,
-0.0390884093940258,
0.00828543771058321,
-0.07099731266498566,
-0.005230522248893976,
0.006957410369068384,
-0.012709172442555428,
0.040176212787628174,
-0.019961196929216385,
0.06762512028217316,
-0.0035466928966343403,
0.003981814254075289,
-0.04492628946900368,
0.031147442758083344,
-0.02764834091067314,
-0.024892572313547134,
-0.013053643517196178,
-0.07052593678236008,
-0.0037483898922801018,
0.03399386256933212,
-0.011240636929869652,
-0.0015943121397867799,
-0.0046503604389727116,
0.012990187853574753,
-0.01861957088112831,
0.0033789898734539747,
0.041264016181230545,
0.004958571400493383,
-0.016697784885764122,
-0.03399386256933212,
-0.032398417592048645,
-0.013996406458318233,
0.006273000966757536,
0.05526042357087135,
0.00446679349988699,
0.08905485272407532,
0.005153469741344452,
-0.013316528871655464,
0.03854450583457947,
0.021846722811460495,
-0.07687145471572876,
0.06396285444498062,
0.08608152717351913,
-0.05174319073557854,
0.030712321400642395,
-0.008335295133292675,
0.033721912652254105,
-0.08861973136663437,
0.012310310266911983,
-0.021320950239896774,
-0.007147775962948799,
0.023297127336263657,
0.049168720841407776,
0.021756071597337723,
-0.014993559569120407,
0.05953911691904068
]
|
33,197 | bqplot.scales | GeoScale | The base projection scale class for Map marks.
The GeoScale represents a mapping between topographic data and a
2d visual representation.
| class GeoScale(Scale):
"""The base projection scale class for Map marks.
The GeoScale represents a mapping between topographic data and a
2d visual representation.
"""
_view_name = Unicode('GeoScale').tag(sync=True)
_model_name = Unicode('GeoScaleModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.04073035717010498,
-0.0822858214378357,
-0.003349659265950322,
0.06507105380296707,
-0.03450453653931618,
-0.019971376284956932,
-0.05468219146132469,
-0.031222855672240257,
0.028128698468208313,
-0.029722658917307854,
0.019802603870630264,
0.0197650995105505,
0.009024623781442642,
0.048943936824798584,
-0.0056444923393428326,
-0.005982036702334881,
-0.02816620282828808,
-0.03229174762964249,
0.03442952781915665,
-0.006296140607446432,
0.005967972334474325,
0.0038536316715180874,
0.05880773440003395,
0.013501775451004505,
-0.0015552826225757599,
0.04568100720643997,
0.024078166112303734,
-0.007482233922928572,
0.02981642074882984,
-0.049318984150886536,
-0.09998814761638641,
-0.0017217107815667987,
-0.0029980505350977182,
0.025728384032845497,
0.026741016656160355,
-0.03247927129268646,
0.003380131907761097,
0.0030074266251176596,
-0.03632352501153946,
-0.014101854525506496,
-0.018499307334423065,
-0.020627712830901146,
-0.0034762383438646793,
-0.03204796463251114,
0.06282076239585876,
0.024209434166550636,
-0.012742300517857075,
0.0019315039971843362,
-0.008443297818303108,
0.0011790612479671836,
-0.0077400803565979,
-0.0026042487006634474,
-0.02732234261929989,
0.02297176979482174,
-0.06754638254642487,
0.042605601251125336,
0.004099757876247168,
0.12474140524864197,
-0.022634226828813553,
0.011654657311737537,
-0.011701538227498531,
-0.008607381954789162,
-0.028560005128383636,
-0.04943149909377098,
-0.007294709328562021,
-0.00014130276395007968,
-0.006807145196944475,
-0.011373370885848999,
-0.002260844223201275,
0.03523588180541992,
-0.009530941024422646,
-0.018564941361546516,
-0.011157717555761337,
0.036586061120033264,
0.02852250076830387,
0.05059415102005005,
-0.013511152006685734,
0.056182388216257095,
-0.0001775624114088714,
-0.016342774033546448,
0.007252516224980354,
-0.042268056422472,
0.031616657972335815,
-0.03808625787496567,
0.01082954928278923,
-0.07028423994779587,
0.040092773735523224,
-0.013792438432574272,
0.006117992103099823,
-0.00827452540397644,
-0.0544571615755558,
0.026440976187586784,
0.0435057207942009,
0.04346821457147598,
0.015395774506032467,
-0.0018611822742968798,
-0.017814842984080315,
0.01716788299381733,
-0.028972560539841652,
-0.016286516562104225,
0.022315435111522675,
-0.0005570068606175482,
-0.03028523176908493,
0.001001498894765973,
-0.0309603214263916,
-0.012029706500470638,
0.013483023270964622,
-0.018658703193068504,
-0.06848400831222534,
0.04590603709220886,
-0.014823824167251587,
0.06454598903656006,
-0.011664033867418766,
0.04043031483888626,
-0.0721219852566719,
-0.009591885842382908,
-0.027341095730662346,
0.03442952781915665,
-0.002625345252454281,
0.0027073873206973076,
-0.06180812790989876,
0.08836162090301514,
-0.03279806300997734,
0.01655842736363411,
0.0022362314630299807,
0.023609355092048645,
0.06559612601995468,
0.032235488295555115,
-0.04928148165345192,
0.0012704795226454735,
0.004467775113880634,
-0.03257303312420845,
-0.035817209631204605,
-0.00558823486790061,
0.09233713895082474,
-0.04013027623295784,
0.06709632277488708,
-0.0025292388163506985,
-0.010801420547068119,
0.10951440036296844,
-0.020533950999379158,
0.03664231672883034,
0.034523289650678635,
-0.006854026112705469,
-0.02525957114994526,
0.03737366572022438,
0.025578362867236137,
-0.011907815933227539,
-0.03133536875247955,
-0.035142119973897934,
-0.018208643421530724,
0.012067211791872978,
0.04463087022304535,
-0.016980357468128204,
-0.003750493051484227,
-0.06447097659111023,
0.023365572094917297,
-0.023928146809339523,
0.022259177640080452,
0.05265692248940468,
-0.028635015711188316,
0.023403076454997063,
-0.015151992440223694,
-0.05614488199353218,
-0.017055368050932884,
-0.023778127506375313,
0.003984898794442415,
-0.0815357193350792,
-0.004449022468179464,
0.05325700342655182,
-0.040017761290073395,
-0.06334582716226578,
-0.0011409703874960542,
0.015517665073275566,
0.06927160918712616,
0.02854125387966633,
0.033566914498806,
0.05922028794884682,
0.012845438905060291,
0.017983615398406982,
0.08821159601211548,
-0.01472068578004837,
-0.011504638008773327,
0.03964271396398544,
-0.029572637751698494,
0.0556948222219944,
0.01171091478317976,
0.009090257808566093,
-0.02929135225713253,
-0.009259030222892761,
0.05681997165083885,
-0.012386003509163857,
-0.04493090882897377,
-0.062295690178871155,
0.008058872073888779,
0.0023006931878626347,
0.01739291287958622,
-0.058620207011699677,
-0.016886595636606216,
0.05400710180401802,
-0.05055664852261543,
-0.018977494910359383,
0.01891186088323593,
-0.007158753927797079,
-0.014411269687116146,
0.010913935489952564,
0.03731740638613701,
-0.01694285310804844,
-0.03377319127321243,
-0.007154065649956465,
-0.0012892320519313216,
0.0049131461419165134,
-0.045718513429164886,
0.03240426257252693,
0.060232918709516525,
-0.07362218201160431,
-0.043205682188272476,
-0.004814695566892624,
0.009249653667211533,
0.05858270451426506,
0.07054677605628967,
-0.033379390835762024,
0.03465455770492554,
-0.003757525235414505,
-0.011767172254621983,
-0.00478891097009182,
0.07103434205055237,
-0.024003155529499054,
0.044143304228782654,
-0.05228187516331673,
-0.025840897113084793,
-0.1066640242934227,
-0.00614143256098032,
0.009770034812390804,
0.03645479306578636,
-0.016445912420749664,
0.02692854031920433,
0.03411073610186577,
0.03189794346690178,
-0.014073725789785385,
0.013117349706590176,
-0.007243140134960413,
-0.07553493231534958,
0.05063165724277496,
-0.0437682569026947,
-0.03562968596816063,
-0.006544610485434532,
0.006371150258928537,
0.02640347182750702,
-0.03424200415611267,
0.020627712830901146,
-0.02471574954688549,
-0.006446159910410643,
0.044518355280160904,
0.044293325394392014,
-0.07846031337976456,
-0.07786023616790771,
-0.05651993304491043,
-0.014589418657124043,
-0.0484938770532608,
-0.0760975033044815,
-0.01045450009405613,
-0.03097907267510891,
0.07065929472446442,
0.06818396598100662,
0.0016666253795847297,
0.003731740638613701,
0.0047842226922512054,
0.020496444776654243,
0.008841787464916706,
0.16292142868041992,
0.04706868901848793,
-0.054194625467061996,
0.03836754336953163,
0.004941274877637625,
-0.024922026321291924,
-0.007730704266577959,
-0.013051716610789299,
0.035967230796813965,
0.016595931723713875,
0.003272305242717266,
-0.042455583810806274,
-0.025803392753005028,
-0.0038723840843886137,
0.026028422638773918,
-0.07054677605628967,
-0.002140125259757042,
0.0025714319199323654,
0.004596698097884655,
-0.011720291338860989,
-0.03204796463251114,
0.03799249604344368,
-0.03791748732328415,
-0.014355012215673923,
0.022671731188893318,
-0.039005130529403687,
0.018574317917227745,
0.023365572094917297,
0.017955485731363297,
-0.03960520774126053,
0.049919065088033676,
-0.04785629361867905,
0.06555861979722977,
0.044893402606248856,
0.011542142368853092,
0.012807934544980526,
0.0068352739326655865,
-0.03609849512577057,
0.018208643421530724,
0.04395578056573868,
-0.019090009853243828,
0.047331225126981735,
-0.06270824372768402,
0.035967230796813965,
-0.044668372720479965,
0.05723252519965172,
0.004652955569326878,
-0.011448380537331104,
-0.0012775117065757513,
0.04744374006986618,
-0.05974535644054413,
-0.02737860009074211,
-0.017758585512638092,
-0.03309810161590576,
0.0529569648206234,
-0.012479766272008419,
-0.016267763450741768,
0.006558674853295088,
0.07275956869125366,
0.011260855942964554,
-0.04395578056573868,
-0.0007032174617052078,
0.04631859064102173,
0.00522256176918745,
-0.08491116762161255,
-0.04050532728433609,
0.05111922323703766,
0.03465455770492554,
-0.012029706500470638,
-0.014561289921402931,
0.018789971247315407,
0.002986330073326826,
-0.07399722933769226,
0.036961108446121216,
-0.01700848713517189,
0.016961606219410896,
-0.012048459611833096,
-0.08663639426231384,
0.038030002266168594,
-0.053669556975364685,
-0.028109947219491005,
-0.03671732917428017,
-0.01335175521671772,
-0.015330140478909016,
0.024734502658247948,
0.0017779681365936995,
0.0305852722376585,
-0.04669364169239998,
-0.008457361720502377,
-0.012039083056151867,
0.04354322701692581,
-0.06004539504647255,
-0.02563462033867836,
-0.015470784157514572,
-0.0026323774363845587,
-0.012536023743450642,
0.017758585512638092,
-0.02906632237136364,
0.06567113846540451,
0.02891630306839943,
0.009263718500733376,
-0.03465455770492554,
-0.03244176506996155,
0.04654362052679062,
-0.04838136211037636,
0.006474288646131754,
-0.015986477956175804,
0.013192359358072281,
-0.06312079727649689,
-0.042380571365356445,
0.015048854053020477,
-0.0008350707357749343,
0.0040317801758646965,
0.031916696578264236,
0.030622776597738266,
-0.010763915255665779,
0.04560599848628044,
0.01113896444439888,
0.015686437487602234,
-0.005991412792354822,
0.011073331348598003,
-0.014298754744231701,
0.018368041142821312,
-0.033604416996240616,
-0.040467821061611176,
-0.0006938412552699447,
-0.012226607650518417,
0.034748319536447525,
0.014617547392845154,
0.01693347655236721,
-0.03270430117845535,
-0.019633831456303596,
0.019090009853243828,
0.010623271577060223,
-0.014823824167251587,
-0.03735491260886192,
0.03202921152114868,
-0.001912751467898488,
0.01662406139075756,
0.044518355280160904,
-0.022409196943044662,
-0.02029016800224781,
-0.027884917333722115,
-0.03244176506996155,
-0.022465454414486885,
-0.023815631866455078,
0.008583941496908665,
-0.028091194108128548,
-0.01937129721045494,
-0.019352544099092484,
-0.013511152006685734,
0.0654086023569107,
0.0011778892949223518,
0.004974091425538063,
0.03112909384071827,
-0.06732135266065598,
0.011917192488908768,
-0.005888274405151606,
0.046506114304065704,
0.058695219457149506,
-0.040242791175842285,
-0.04286813735961914,
-0.0018072689417749643,
-0.03851756453514099,
0.043055661022663116,
-0.020346425473690033,
0.003593441331759095,
0.008785529993474483,
-0.030378995463252068,
-0.04174298793077469,
0.0203839298337698,
-0.007622877135872841,
0.013670547865331173,
-0.02441571094095707,
0.07380970567464828,
-0.053519535809755325,
-0.06975917518138885,
0.006296140607446432,
0.025690877810120583,
-0.027341095730662346,
0.038555070757865906,
0.03667982295155525,
0.04114291071891785,
-0.002409691922366619,
0.0805605947971344,
-0.07876035571098328,
-0.06098301708698273,
-0.08296091109514236,
-0.0034363893792033195,
-0.022990522906184196,
-0.035273388028144836,
-0.02548460103571415,
-0.017983615398406982,
-0.02182787097990513,
0.01129836030304432,
0.056632447987794876,
0.033004339784383774,
-0.01411123014986515,
-0.02426569163799286,
-0.06188313663005829,
0.019483812153339386,
0.013173607178032398,
0.011148341000080109,
-0.07470982521772385,
-0.04920646920800209,
0.04065534472465515,
-0.03919265419244766,
0.057870108634233475,
-0.011260855942964554,
-0.02195913717150688,
0.010473252274096012,
-0.04706868901848793,
0.05325700342655182,
0.06675878167152405,
-0.0033285627141594887,
0.021321553736925125,
0.04114291071891785,
-0.0006323097040876746,
-0.020927751436829567,
0.0008467910229228437,
-0.017364783212542534,
0.07373469322919846,
0.007791649550199509,
0.034598298370838165,
-0.021546583622694016,
0.042380571365356445,
0.035517171025276184,
-0.026741016656160355,
-0.0208902470767498,
0.011767172254621983,
0.012882944196462631,
-0.06162060424685478,
-0.014823824167251587,
-0.018293030560016632,
0.056257396936416626,
-0.01716788299381733,
-0.03896762430667877,
0.0477437786757946,
0.006652437150478363,
0.007772896904498339,
-0.05636991187930107,
-0.026816025376319885,
0.028184955939650536,
-0.014251873828470707,
0.044143304228782654,
0.018255526199936867,
-0.058320168405771255,
0.001724054804071784,
-0.031166598200798035,
-0.0030988450162112713,
0.011757795698940754,
0.011598399840295315,
0.005832016933709383,
0.004010683856904507,
0.0047607822343707085,
-0.00032348002423532307,
-0.013276745565235615,
0.0024706374388188124,
0.03392321243882179,
0.057795099914073944,
0.04729371890425682,
-0.03163541108369827,
-0.010735786519944668,
0.039867743849754333,
0.027903668582439423,
0.05348203331232071,
-0.06795893609523773,
-0.03637978434562683,
0.03189794346690178,
-0.019896365702152252,
-0.01437376532703638,
-0.019174396991729736,
0.03664231672883034,
0.009282470680773258,
0.04676865041255951,
-0.002123716752976179,
0.003312154207378626,
-0.032310497015714645,
0.04658112674951553,
0.0076978872530162334,
0.023290563374757767,
0.04631859064102173,
-0.003656730754300952,
-0.03180418163537979,
0.02953513339161873,
0.05772009119391441,
-0.03351065516471863,
-0.005944531876593828,
-0.03165416419506073,
-0.010557638481259346,
-0.009587198495864868,
-0.004620138555765152,
0.11318988353013992,
0.10658901929855347,
-0.08236082643270493,
0.023440582677721977,
-0.046806152909994125,
0.07017172873020172,
0.013398637063801289,
0.003220736049115658,
0.01045450009405613,
-0.02036517858505249,
0.021846622228622437,
0.03097907267510891,
0.011007697321474552,
0.010557638481259346,
0.04965652897953987,
0.020271414890885353,
-0.04331819713115692,
-0.04121791943907738,
-0.02180911786854267,
0.049694035202264786,
0.011870310641825199,
0.006830585654824972,
0.019202524796128273,
0.03137287497520447,
-0.0018576661823317409,
0.03814251720905304,
0.012536023743450642,
-0.026572244241833687,
0.0038395673036575317,
0.01570519059896469,
0.0437682569026947,
-0.0013947146944701672,
-0.03386695310473442,
-0.06548360735177994,
-0.02976016327738762,
-0.04770627245306969,
0.04264310747385025,
-0.002911320421844721,
-0.015742694959044456,
0.03456079587340355,
-0.007571307942271233,
0.004020059946924448,
-0.018021119758486748,
-0.034598298370838165,
0.028728777542710304,
-0.023440582677721977,
-0.029178837314248085,
-0.017411664128303528,
0.003197295358404517,
0.0006686426349915564,
-0.05486971512436867,
-0.019118139520287514,
0.007749456446617842,
-0.08048558235168457,
-0.049694035202264786,
0.0375424362719059,
0.0033332507591694593,
-0.021715356037020683,
-0.03311685472726822,
0.003487958572804928,
0.0022163069806993008,
0.008682391606271267,
-0.011392123065888882,
0.021115276962518692,
0.03202921152114868,
0.007585372310131788,
-0.0043646362610161304,
-0.0489814393222332,
0.013989339582622051,
-0.01716788299381733,
-0.017796089872717857,
-0.09008684754371643,
0.0015435623936355114,
-0.017636694014072418,
-0.03844255581498146,
0.018518060445785522,
-0.0015306699788197875,
0.05925779044628143,
0.011026449501514435,
0.010051321238279343,
0.03915514796972275,
0.02364685945212841,
-0.014655051752924919,
-0.0002285456721438095,
-0.011073331348598003,
0.01761794090270996,
-0.004221648909151554,
0.014889458194375038,
-0.009788786992430687,
0.036736082285642624,
0.05734504014253616,
0.003734084777534008,
0.03081030212342739,
0.04234306886792183,
-0.03465455770492554,
-0.022746741771697998,
0.02280299924314022,
-0.04920646920800209,
-0.062295690178871155,
-0.008279213681817055,
0.01541452668607235,
0.009240277111530304,
0.026909789070487022,
-0.025615869089961052,
-0.03347315266728401,
0.010567014105618,
-0.0030589960515499115,
0.01541452668607235,
-0.027603629976511,
0.007618189323693514,
-0.01800236664712429,
-0.01929628662765026,
-0.04406829550862312,
-0.008063560351729393,
0.0591827817261219,
-0.0203839298337698,
0.005841393023729324,
0.022934265434741974,
0.0005994928651489317,
-0.0020194060634821653,
-0.039530199021101,
0.07418475300073624,
-0.003952082246541977,
0.0336981825530529,
-0.02732234261929989,
-0.012001577764749527,
0.028409985825419426,
0.041067901998758316,
0.060532961040735245,
-0.045268453657627106,
-0.0027073873206973076,
-0.014823824167251587,
0.03896762430667877,
-0.025990918278694153,
-0.05029411241412163,
-0.013211112469434738,
0.02441571094095707,
-0.007224387489259243,
0.009371545165777206,
-0.013867448084056377,
-0.07545991986989975,
0.06180812790989876,
0.05888274312019348,
0.028860045596957207,
-0.02769739180803299,
0.014317507855594158,
0.07838530838489532,
-0.0272285807877779,
0.03587346896529198,
0.04800631105899811,
0.05224436894059181,
-0.019408801570534706,
0.02479076012969017,
-0.034523289650678635,
0.017439793795347214,
0.06600867956876755,
-0.029741410166025162,
-0.0019537725020200014,
0.0019736969843506813,
0.009146515280008316,
0.035517171025276184,
-0.011532766744494438,
-0.0007389643578790128,
0.021134028211236,
-0.04005526751279831,
-0.027791153639554977,
-0.05063165724277496,
0.006394590716809034,
-0.04928148165345192,
0.03960520774126053,
-0.05201933905482292,
-0.009259030222892761,
-0.036811091005802155,
-0.0042755622416734695,
-0.041630472987890244,
-0.021227791905403137,
-0.0201401486992836,
-0.01793673448264599,
0.001681861816905439,
-0.06113303825259209,
0.0065492987632751465,
-0.028128698468208313,
-0.03081030212342739,
0.03727990388870239,
0.009741906076669693,
0.042905643582344055,
-0.02959139086306095,
0.04271811619400978,
0.06143307685852051,
0.03834879398345947,
-0.013379883952438831,
-0.011532766744494438,
0.019090009853243828,
-0.06308329850435257,
0.04204303026199341,
-0.026384718716144562,
-0.00409741373732686,
-0.03197295591235161,
-0.009287158958613873,
-0.030491508543491364,
-0.03632352501153946,
-0.01216097455471754,
0.03990524634718895,
0.010679529048502445,
0.002433132380247116,
0.0083917286247015
]
|
33,254 | bqplot.scales | Gnomonic | A perspective projection which displays great circles as straight lines.
The projection is neither equal-area nor conformal.
Attributes
----------
scale_factor: float (default: 145)
Specifies the scale value for the projection
center: tuple (default: (0, 60))
Specifies the longitude and latitude where the map is centered.
precision: float (default: 0.1)
Specifies the threshold for the projections adaptive resampling to the
specified value in pixels.
clip_angle: float (default: 89.999)
Specifies the clipping circle radius to the specified angle in degrees.
| class Gnomonic(GeoScale):
"""A perspective projection which displays great circles as straight lines.
The projection is neither equal-area nor conformal.
Attributes
----------
scale_factor: float (default: 145)
Specifies the scale value for the projection
center: tuple (default: (0, 60))
Specifies the longitude and latitude where the map is centered.
precision: float (default: 0.1)
Specifies the threshold for the projections adaptive resampling to the
specified value in pixels.
clip_angle: float (default: 89.999)
Specifies the clipping circle radius to the specified angle in degrees.
"""
scale_factor = Float(145.0).tag(sync=True)
center = Tuple((0, 60)).tag(sync=True)
precision = Float(0.1).tag(sync=True)
clip_angle = Float(89.999, min=0.0, max=360.0).tag(sync=True)
rtype = '(Number, Number)'
dtype = np.number
_view_name = Unicode('Gnomonic').tag(sync=True)
_model_name = Unicode('GnomonicModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.04200587049126625,
-0.04980380833148956,
0.027899695560336113,
0.04899458959698677,
0.007853111252188683,
-0.021554676815867424,
-0.044543880969285965,
-0.01966036669909954,
0.014372849836945534,
-0.003832300193607807,
0.006965728476643562,
0.027734173461794853,
-0.010529055260121822,
0.07426431775093079,
-0.01818905770778656,
-0.019513234496116638,
-0.03466771915555,
-0.04513240233063698,
0.0009006020263768733,
-0.024350162595510483,
0.02284207195043564,
-0.005641550291329622,
0.02087419666349888,
-0.01702120527625084,
-0.030989445745944977,
0.012754409573972225,
0.05487982556223869,
-0.007627817336469889,
-0.02326507307589054,
-0.013821108266711235,
-0.06613533943891525,
0.007899089716374874,
-0.008225536905229092,
-0.01691085658967495,
0.0031725100707262754,
-0.03503554314374924,
0.016929248347878456,
0.04101273790001869,
-0.08452670276165009,
-0.024754773825407028,
-0.03676433116197586,
-0.006965728476643562,
-0.010933664627373219,
-0.010657794773578644,
0.013673977926373482,
-0.017563750967383385,
-0.04586805775761604,
0.05605687201023102,
-0.019973019137978554,
0.017370641231536865,
-0.012331408448517323,
0.00561396311968565,
-0.04954633116722107,
0.007287577260285616,
-0.08393817394971848,
0.029407788068056107,
0.05042911320924759,
0.10975965112447739,
0.023798422887921333,
-0.04145412892103195,
-0.04597840458154678,
-0.011191143654286861,
0.011237122118473053,
-0.0562775693833828,
0.003685169154778123,
0.03166992589831352,
0.002165582962334156,
0.00775655684992671,
0.03836438059806824,
0.024515686556696892,
-0.021058110520243645,
-0.004997852724045515,
0.014005022123456001,
0.005917420610785484,
0.0612800195813179,
0.07775867730379105,
-0.029628483578562737,
0.017894795164465904,
0.04877389222383499,
-0.04152769595384598,
-0.026888171210885048,
-0.02725599892437458,
0.051973991096019745,
-0.03304927796125412,
-0.015246438793838024,
-0.05057624727487564,
0.05414417013525963,
-0.04163804277777672,
0.01685568317770958,
-0.011742884293198586,
-0.06635603308677673,
0.02146271988749504,
0.01777525059878826,
-0.0007063432713039219,
0.006505944300442934,
0.028065219521522522,
-0.006859978195279837,
0.013572825118899345,
0.007214011624455452,
-0.01652463898062706,
0.04233691468834877,
0.002195468870922923,
-0.03466771915555,
-0.0017667202046141028,
-0.001544874394312501,
-0.0023517953231930733,
0.030989445745944977,
0.021205240860581398,
-0.019789105281233788,
0.0815105140209198,
-0.07279301434755325,
0.06249384954571724,
-0.027329564094543457,
0.002170180669054389,
-0.016257964074611664,
-0.0156694408506155,
-0.029757224023342133,
-0.0008506004814989865,
0.011126774363219738,
-0.002754106419160962,
-0.06002940610051155,
0.07812650501728058,
-0.027495086193084717,
0.02409268356859684,
-0.00784851424396038,
0.03843794763088226,
0.046566929668188095,
0.007200218271464109,
-0.029794007539749146,
-0.04763362929224968,
0.007227805443108082,
-0.014087783172726631,
0.0043610516004264355,
-0.012910735793411732,
0.04123343527317047,
-0.017168337479233742,
0.05204755440354347,
-0.01890631951391697,
0.009489943273365498,
0.11292296648025513,
-0.04244726523756981,
-0.014492393471300602,
0.017195923253893852,
0.028065219521522522,
-0.02742152102291584,
0.02043280377984047,
0.03898968920111656,
-0.003023080062121153,
-0.015080916695296764,
-0.037665508687496185,
-0.005494419485330582,
-0.01081412099301815,
0.05686609074473381,
-0.013342932797968388,
0.013591216877102852,
-0.037279292941093445,
0.03807011991739273,
-0.03212970867753029,
0.04237369820475578,
0.05807992070913315,
-0.04807502031326294,
0.04943598061800003,
0.011319883167743683,
0.017572946846485138,
0.008703712373971939,
-0.014216522686183453,
0.04719223454594612,
-0.08894062787294388,
-0.013278563506901264,
0.040571343153715134,
0.002223055809736252,
-0.04653014615178108,
0.01641429029405117,
-0.0017793643055483699,
0.03429989144206047,
0.06367089599370956,
0.03146762028336525,
0.07996564358472824,
-0.008230134844779968,
0.003133428283035755,
0.055689044296741486,
-0.029702050611376762,
-0.0036047070752829313,
0.024294989183545113,
0.009701443836092949,
0.12138298898935318,
0.046456579118967056,
-0.04314613714814186,
-0.01571541838347912,
-0.046897973865270615,
0.056351132690906525,
0.004485193639993668,
-0.003452978329733014,
-0.03282858058810234,
-0.010887686163187027,
-0.0023908771108835936,
0.019586801528930664,
-0.04333005100488663,
-0.014409632422029972,
0.054548781365156174,
-0.07356544584035873,
-0.013572825118899345,
-0.005453038960695267,
-0.05042911320924759,
-0.03898968920111656,
0.0015023443847894669,
-0.014106174930930138,
0.01261647418141365,
0.02010175958275795,
0.029518136754631996,
0.02589503861963749,
0.0025931820273399353,
-0.008772679604589939,
-0.0003123657952528447,
0.04583127424120903,
-0.09659143537282944,
-0.0171867273747921,
0.021812155842781067,
0.0031954990699887276,
0.022786898538470268,
0.017903991043567657,
-0.025085818022489548,
0.023412203416228294,
-0.01638670451939106,
-0.011945189908146858,
-0.010198010131716728,
0.05226825177669525,
0.015393570065498352,
0.022823680192232132,
-0.0934281200170517,
0.014161349274218082,
-0.08754288405179977,
-0.06337663531303406,
-0.01571541838347912,
0.0036047070752829313,
-0.06105932220816612,
0.04189552366733551,
0.04005638509988785,
-0.01371076051145792,
0.0005028888117522001,
-0.0007977253408171237,
0.009646269492805004,
-0.053776342421770096,
0.07628737390041351,
-0.013011888600885868,
-0.02229033038020134,
-0.029297439381480217,
-0.003200097009539604,
0.051863640546798706,
0.020451195538043976,
0.011126774363219738,
-0.05193720757961273,
-0.03862186148762703,
0.042410481721162796,
0.017922382801771164,
-0.06720203906297684,
-0.10365371406078339,
-0.002924226690083742,
0.014474001713097095,
-0.05120155215263367,
-0.04119665175676346,
-0.050392333418130875,
-0.027403129264712334,
0.03735285624861717,
0.07143205404281616,
0.025030644610524178,
-0.021775372326374054,
-0.006156508345156908,
0.07176309823989868,
0.0014701595064252615,
0.12469343841075897,
0.0840117409825325,
-0.07746441662311554,
-0.01597289741039276,
0.03898968920111656,
0.015485526993870735,
-0.022878853604197502,
-0.0006638132035732269,
0.047560062259435654,
0.03898968920111656,
0.011706101708114147,
-0.08592444658279419,
-0.02076384797692299,
-0.0005083487485535443,
-0.017205119132995605,
0.01188081968575716,
0.015080916695296764,
0.03781263902783394,
0.02622608281672001,
-0.008639342151582241,
-0.002319610444828868,
0.06311915814876556,
-0.02664908394217491,
-0.023945553228259087,
0.06665029376745224,
-0.042851872742176056,
-0.007374936249107122,
0.02173859067261219,
-0.040571343153715134,
-0.023357030004262924,
0.06698133796453476,
-0.033674582839012146,
0.0496198944747448,
-0.007025500293821096,
-0.004278290551155806,
0.019421277567744255,
-0.008772679604589939,
-0.03928394988179207,
0.01813388243317604,
0.03279179707169533,
-0.023504160344600677,
0.005586376413702965,
-0.04675084352493286,
-0.0026851389557123184,
-0.025968603789806366,
0.03865864500403404,
0.04156447947025299,
-0.0066346838138997555,
0.028819264844059944,
0.010004901327192783,
-0.031651534140110016,
-0.004558758810162544,
-0.04561057686805725,
-0.004082882311195135,
0.04046099632978439,
-0.03829081729054451,
0.007522067055106163,
0.03634133189916611,
0.03371136635541916,
0.037389639765024185,
-0.03887933865189552,
0.02190411277115345,
-0.026998519897460938,
0.030014703050255775,
-0.033674582839012146,
-0.020083367824554443,
0.04928885027766228,
0.00458174804225564,
-0.03295731917023659,
-0.03906325250864029,
-0.016322333365678787,
-0.009931335225701332,
-0.069298654794693,
0.022878853604197502,
-0.05053946375846863,
0.006294443737715483,
-0.007807133253663778,
-0.0526728630065918,
0.036028679460287094,
-0.025637559592723846,
-0.025140991434454918,
-0.0005638101720251143,
0.0073335557244718075,
0.008699114434421062,
0.006239269394427538,
0.05418095365166664,
0.006427781190723181,
-0.02354094386100769,
-0.0030391726177185774,
-0.014142957516014576,
0.044323183596134186,
-0.000501739326864481,
-0.006395596079528332,
-0.013637195341289043,
-0.016975227743387222,
-0.02550881914794445,
-0.01807870902121067,
-0.03490680456161499,
0.07533101737499237,
0.02315472438931465,
-0.02698012813925743,
-0.028984786942601204,
-0.056020088493824005,
0.004108170513063669,
-0.006836988963186741,
0.007774948142468929,
-0.0007414018036797643,
0.01988106220960617,
-0.0659882053732872,
-0.05002450570464134,
-0.013839500024914742,
-0.01766490377485752,
0.029462961480021477,
0.01729707606136799,
-0.033729758113622665,
0.0022035150323063135,
0.055468346923589706,
0.03477806597948074,
0.005324299447238445,
-0.04009316861629486,
-0.027991652488708496,
-0.03496197983622551,
0.04259439557790756,
0.021609850227832794,
-0.0022402978502213955,
-0.0034115975722670555,
-0.01755455508828163,
0.028856046497821808,
-0.007108261343091726,
0.01977071352303028,
-0.030235398560762405,
-0.027954870834946632,
-0.005853050854057074,
0.023632900789380074,
-0.027844522148370743,
-0.07448501884937286,
0.048589978367090225,
-0.008147373795509338,
0.01879597268998623,
-0.007738165557384491,
0.02409268356859684,
0.0000765109434723854,
0.009039354510605335,
-0.006804803851991892,
-0.006368009373545647,
-0.016561422497034073,
-0.02944457158446312,
-0.02293402887880802,
-0.03529302403330803,
0.026134125888347626,
-0.0013862489722669125,
0.02698012813925743,
0.0034621739760041237,
0.029150309041142464,
0.035311415791511536,
-0.035053934901952744,
0.012947519309818745,
0.0011235972633585334,
0.003197798039764166,
0.03501715511083603,
-0.045095618814229965,
0.020009802654385567,
0.018428144976496696,
-0.03643328696489334,
0.010041683912277222,
-0.002535708947107196,
0.008602559566497803,
0.021867329254746437,
-0.012018755078315735,
-0.018170665949583054,
0.03363780304789543,
0.027568651363253593,
-0.0014736078446730971,
-0.04527953267097473,
0.03413436934351921,
-0.02617090754210949,
-0.0027334161568433046,
-0.023743247613310814,
0.006027768831700087,
-0.013765934854745865,
0.03950464725494385,
0.031872231513261795,
0.04502205550670624,
-0.01999141089618206,
0.07073318213224411,
-0.04090239107608795,
-0.06882047653198242,
-0.04391857236623764,
-0.04145412892103195,
-0.01269923523068428,
0.005526604130864143,
0.014584350399672985,
-0.04060812667012215,
0.0035150491166859865,
-0.012680844403803349,
0.03658042103052139,
0.06381803005933762,
0.01602807268500328,
-0.08813140541315079,
-0.08048059791326523,
0.03711376711726189,
0.005057624541223049,
0.02370646595954895,
-0.04384500905871391,
-0.014308479614555836,
0.06311915814876556,
-0.026318039745092392,
0.058925922960042953,
0.005903627257794142,
-0.02528812363743782,
-0.023283464834094048,
-0.03906325250864029,
0.024883512407541275,
0.027292780578136444,
-0.02447890304028988,
0.0668342113494873,
0.007876100949943066,
0.0025518015027046204,
-0.022271940484642982,
-0.042153000831604004,
-0.026318039745092392,
0.08607157319784164,
0.0059358119033277035,
0.04299900308251381,
0.004142654128372669,
0.09688569605350494,
0.020635107532143593,
-0.058594878762960434,
-0.003480565268546343,
0.006230073980987072,
-0.023743247613310814,
-0.02731117233633995,
-0.02698012813925743,
-0.0007350797532126307,
0.030125051736831665,
-0.002262137597426772,
-0.03376654163002968,
0.05270964279770851,
-0.02988596260547638,
0.04112308472394943,
-0.054659128189086914,
-0.03639650717377663,
0.04840606451034546,
-0.01477745920419693,
0.019623583182692528,
0.02677782252430916,
-0.008253123611211777,
-0.016129225492477417,
-0.08202547580003738,
-0.032644666731357574,
0.016211986541748047,
-0.00023693246475886554,
-0.019458061084151268,
0.006653075106441975,
-0.017628120258450508,
0.03124692477285862,
-0.011292296461760998,
0.005223146639764309,
0.05903627350926399,
0.030290573835372925,
0.05903627350926399,
-0.031982578337192535,
-0.008570374920964241,
0.04483814164996147,
0.03371136635541916,
0.037665508687496185,
-0.03634133189916611,
-0.03661720082163811,
0.041049521416425705,
-0.016395898535847664,
-0.047118671238422394,
-0.027936479076743126,
-0.01838216558098793,
0.020120149478316307,
0.04744971543550491,
0.012506126426160336,
0.07503675669431686,
-0.01477745920419693,
0.04660371318459511,
-0.017600534483790398,
0.050392333418130875,
0.051054421812295914,
-0.023173116147518158,
-0.04141734912991524,
0.05947766453027725,
0.1297694444656372,
-0.029407788068056107,
-0.057601746171712875,
-0.031338881701231,
-0.003625397337600589,
0.014170544221997261,
-0.012634865939617157,
0.08908776193857193,
0.06797447800636292,
-0.08673366159200668,
0.017490185797214508,
-0.021076500415802002,
0.07606667280197144,
0.013867086730897427,
0.009820987470448017,
0.05002450570464134,
-0.021113283932209015,
-0.006115127820521593,
0.04550023004412651,
-0.009572704322636127,
0.009319823235273361,
0.03332514688372612,
0.020690282806754112,
-0.03102622739970684,
-0.02911352552473545,
0.004689797293394804,
0.018639646470546722,
0.029959529638290405,
-0.007145044393837452,
-0.01901666820049286,
0.038327597081661224,
-0.01343488972634077,
0.043624311685562134,
0.02495707757771015,
-0.0670916885137558,
0.0049196891486644745,
0.033233191817998886,
0.05259929597377777,
-0.013067062944173813,
-0.05745461583137512,
-0.054217737168073654,
-0.061647847294807434,
-0.028285915032029152,
0.041159868240356445,
0.017278684303164482,
-0.02808360941708088,
-0.010225597769021988,
-0.03304927796125412,
-0.014869416132569313,
-0.021665025502443314,
-0.04789110645651817,
-0.025490427389740944,
-0.010510663501918316,
-0.030566444620490074,
-0.01732466369867325,
0.008515200577676296,
0.003416195511817932,
-0.06440655142068863,
-0.05484304204583168,
-0.031596358865499496,
-0.04752327874302864,
-0.04218978434801102,
0.06264097988605499,
-0.0036644788924604654,
-0.011292296461760998,
-0.01663498766720295,
0.020745456218719482,
-0.009940531104803085,
-0.025140991434454918,
0.008740494959056377,
-0.03016183339059353,
0.009172691963613033,
-0.06337663531303406,
-0.0040093171410262585,
0.007968057878315449,
0.01921897381544113,
0.01089688204228878,
-0.061316803097724915,
-0.04888423904776573,
-0.03501715511083603,
-0.03851151093840599,
-0.04987737536430359,
0.012395777739584446,
-0.0015207357937470078,
0.07224126905202866,
-0.030382530763745308,
-0.031228533014655113,
-0.00013060741184744984,
0.00046064614434726536,
-0.005108200944960117,
-0.000619559024926275,
-0.005986388307064772,
0.016129225492477417,
0.019310930743813515,
-0.018979886546730995,
-0.020120149478316307,
0.06628246605396271,
0.04737614840269089,
-0.006993315648287535,
-0.004154148977249861,
-0.01486022025346756,
-0.07518389075994492,
0.01738903298974037,
0.0008212892571464181,
-0.017591338604688644,
-0.026906562969088554,
-0.014630328863859177,
0.013076258823275566,
-0.009462355636060238,
0.004646117798984051,
-0.023191507905721664,
0.01633152924478054,
-0.023081159219145775,
0.0016506247920915484,
0.014032609760761261,
-0.03720572590827942,
-0.01591772399842739,
0.02381681464612484,
0.032534319907426834,
-0.01163253653794527,
-0.02026728168129921,
0.04248404502868652,
0.024442119523882866,
-0.020469585433602333,
0.03141244500875473,
0.012175081297755241,
0.033288367092609406,
0.003696663770824671,
0.05031876638531685,
-0.009214072488248348,
-0.014740676619112492,
0.002139145275577903,
-0.031541187316179276,
0.014759068377315998,
0.051422249525785446,
0.02955491840839386,
0.03415276110172272,
0.04785432294011116,
-0.009756617248058319,
0.042153000831604004,
-0.028800873085856438,
-0.07084352523088455,
-0.004023110494017601,
-0.03470449894666672,
-0.016589008271694183,
0.014630328863859177,
-0.029536528512835503,
-0.06260419636964798,
0.05914662033319473,
0.016349921002984047,
0.02096615359187126,
0.030787140130996704,
0.01196358073502779,
0.03407919406890869,
-0.014501589350402355,
0.015393570065498352,
0.08445313572883606,
0.0557258278131485,
-0.05167972669005394,
0.009554312564432621,
-0.010777338407933712,
0.05237859860062599,
0.05164294317364693,
-0.018235035240650177,
-0.03429989144206047,
0.013609607703983784,
-0.01769248954951763,
0.05237859860062599,
0.028046827763319016,
-0.005747300572693348,
0.003889773041009903,
-0.00967385619878769,
-0.05969836190342903,
-0.05035554990172386,
-0.04402891919016838,
-0.05201077088713646,
0.07062283158302307,
-0.025159383192658424,
-0.013729152269661427,
-0.029205482453107834,
0.010004901327192783,
-0.024166250601410866,
-0.02972044050693512,
-0.05359242856502533,
-0.021223632618784904,
-0.027127258479595184,
-0.036083851009607315,
0.022051243111491203,
-0.042520828545093536,
0.00009820699779083952,
0.04156447947025299,
0.010188814252614975,
-0.0014276294969022274,
-0.01526483055204153,
0.003078254172578454,
0.06661351025104523,
0.0340975858271122,
0.027623826637864113,
-0.0110899917781353,
0.024993861094117165,
-0.03792298957705498,
0.012736018747091293,
0.02267654985189438,
0.013582020998001099,
-0.056939657777547836,
-0.05741783231496811,
0.0024391543120145798,
-0.051753293722867966,
0.0038644850719720125,
0.013407303020358086,
0.035145893692970276,
-0.028488220646977425,
-0.005664539523422718
]
|
33,311 | bqplot.marks | Graph | Graph with nodes and links.
Attributes
----------
node_data: List
list of node attributes for the graph
link_matrix: numpy.ndarray of shape(len(nodes), len(nodes))
link data passed as 2d matrix
link_data: List
list of link attributes for the graph
charge: int (default: -600)
charge of force layout. Will be ignored when x and y data attributes
are set
static: bool (default: False)
whether the graph is static or not
link_distance: float (default: 100)
link distance in pixels between nodes. Will be ignored when x and y
data attributes are set
link_type: {'arc', 'line', 'slant_line'} (default: 'arc')
Enum representing link type
directed: bool (default: True)
directed or undirected graph
highlight_links: bool (default: True)
highlights incoming and outgoing links when hovered on a node
colors: list (default: CATEGORY10)
list of node colors
Data Attributes
x: numpy.ndarray (default: [])
abscissas of the node data points (1d array)
y: numpy.ndarray (default: [])
ordinates of the node data points (1d array)
color: numpy.ndarray or None (default: None)
color of the node data points (1d array).
link_color: numpy.ndarray of shape(len(nodes), len(nodes))
link data passed as 2d matrix
| class Graph(Mark):
"""Graph with nodes and links.
Attributes
----------
node_data: List
list of node attributes for the graph
link_matrix: numpy.ndarray of shape(len(nodes), len(nodes))
link data passed as 2d matrix
link_data: List
list of link attributes for the graph
charge: int (default: -600)
charge of force layout. Will be ignored when x and y data attributes
are set
static: bool (default: False)
whether the graph is static or not
link_distance: float (default: 100)
link distance in pixels between nodes. Will be ignored when x and y
data attributes are set
link_type: {'arc', 'line', 'slant_line'} (default: 'arc')
Enum representing link type
directed: bool (default: True)
directed or undirected graph
highlight_links: bool (default: True)
highlights incoming and outgoing links when hovered on a node
colors: list (default: CATEGORY10)
list of node colors
Data Attributes
x: numpy.ndarray (default: [])
abscissas of the node data points (1d array)
y: numpy.ndarray (default: [])
ordinates of the node data points (1d array)
color: numpy.ndarray or None (default: None)
color of the node data points (1d array).
link_color: numpy.ndarray of shape(len(nodes), len(nodes))
link data passed as 2d matrix
"""
charge = Int(-600).tag(sync=True)
static = Bool(False).tag(sync=True)
link_distance = Float(100).tag(sync=True)
node_data = List().tag(sync=True)
link_data = List().tag(sync=True)
link_matrix = Array([]).tag(sync=True, rtype='Number',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 2))
link_type = Enum(['arc', 'line', 'slant_line'],
default_value='arc').tag(sync=True)
directed = Bool(True).tag(sync=True)
colors = List(trait=Color(default_value=None, allow_none=True),
default_value=CATEGORY10).tag(sync=True,
display_name='Colors')
interactions = Dict({'hover': 'tooltip', 'click': 'select'}).tag(sync=True)
highlight_links = Bool(True).tag(sync=True)
# Scaled attributes
x = Array([], allow_none=True).tag(sync=True,
scaled=True,
rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_dimension_bounds(1, 1))
y = Array([], allow_none=True).tag(sync=True,
scaled=True,
rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_dimension_bounds(1, 1))
color = Array(None, allow_none=True).tag(sync=True,
scaled=True,
rtype='Color',
atype='bqplot.ColorAxis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
link_color = Array([]).tag(sync=True, rtype='Color',
atype='bqplot.ColorAxis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 2))
hovered_style = Dict().tag(sync=True)
unhovered_style = Dict().tag(sync=True)
hovered_point = Int(None, allow_none=True).tag(sync=True)
# Other attributes
scales_metadata = Dict({
'x': {'orientation': 'horizontal', 'dimension': 'x'},
'y': {'orientation': 'vertical', 'dimension': 'y'},
'color': {'dimension': 'color'},
'link_color': {'dimension': 'link_color'}
}).tag(sync=True)
_model_name = Unicode('GraphModel').tag(sync=True)
_view_name = Unicode('Graph').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.02647821046411991,
-0.0460909865796566,
-0.04157831147313118,
0.04566671699285507,
-0.02883097156882286,
0.0038497543428093195,
-0.09873884916305542,
0.012882334180176258,
-0.0032856701873242855,
-0.022910498082637787,
-0.011349181644618511,
0.00549138430505991,
0.03058590181171894,
0.04026693478226662,
-0.03075946494936943,
-0.017385365441441536,
0.0035436060279607773,
0.027346031740307808,
0.051259346306324005,
0.03257225081324577,
-0.026767484843730927,
-0.030026638880372047,
0.00933872815221548,
0.00997995212674141,
0.019651345908641815,
0.01173488050699234,
0.015456872060894966,
0.008851783350110054,
0.02161840721964836,
0.023701179772615433,
-0.06838436424732208,
-0.058896180242300034,
-0.01735643856227398,
0.024164019152522087,
0.052262164652347565,
-0.058973319828510284,
0.017751779407262802,
0.05021796002984047,
-0.03862771764397621,
-0.0006327868322841823,
0.002791493898257613,
-0.01483011245727539,
0.047248080372810364,
-0.0459367074072361,
0.032803669571876526,
0.017076807096600533,
-0.013026971369981766,
0.056466277688741684,
-0.0870136097073555,
-0.09511328488588333,
0.03988123685121536,
-0.05253215134143829,
0.008731252513825893,
0.09580753743648529,
-0.04666953533887863,
0.038029883056879044,
0.008398587815463543,
0.10583570599555969,
0.0037581510841846466,
0.013788726180791855,
0.02354690060019493,
0.028715262189507484,
0.03359435126185417,
-0.04049835726618767,
-0.03153086453676224,
0.0009003652376122773,
-0.027693161740899086,
-0.009753353893756866,
0.0025745383463799953,
0.03305437043309212,
0.008904816582798958,
0.01986347883939743,
0.032745812088251114,
0.005592630244791508,
0.017983198165893555,
-0.047248080372810364,
-0.01717323064804077,
0.012159149162471294,
-0.02665177546441555,
-0.04508816823363304,
0.029737364500761032,
0.023759035393595695,
0.053612109273672104,
-0.05407494679093361,
0.03083660453557968,
-0.04377679526805878,
0.034751445055007935,
0.07810397446155548,
-0.02221624180674553,
-0.04963941499590874,
-0.03972695767879486,
0.013403027318418026,
-0.012882334180176258,
0.03224440664052963,
-0.024279728531837463,
-0.015109743922948837,
0.011648098938167095,
-0.07914535701274872,
0.011030980385839939,
0.01496510673314333,
0.002347940346226096,
-0.04084548354148865,
-0.0360628217458725,
0.001672967802733183,
-0.05557917058467865,
-0.04150117188692093,
-0.045628149062395096,
-0.00033778761280700564,
-0.030778750777244568,
0.006026540882885456,
-0.029313094913959503,
0.047479499131441116,
0.006151893176138401,
0.012486993335187435,
0.014145497232675552,
0.007111318409442902,
-0.028946682810783386,
-0.013547664508223534,
0.011002053506672382,
-0.03745133802294731,
-0.025436824187636375,
0.04535815864801407,
-0.029158815741539,
0.018957087770104408,
-0.00935319159179926,
0.010625997558236122,
0.036737795919179916,
0.056273430585861206,
-0.0242990143597126,
-0.0681915208697319,
-0.01311375293880701,
-0.024511147290468216,
-0.02605394273996353,
0.04231113940477371,
0.037586331367492676,
-0.013104110956192017,
-0.013711586594581604,
-0.0049080150201916695,
-0.057623375207185745,
0.057469096034765244,
0.03980409726500511,
-0.02044202759861946,
0.02096272073686123,
-0.03964981809258461,
-0.07536551356315613,
-0.021811258047819138,
-0.032398685812950134,
-0.053689248859882355,
-0.0581633523106575,
-0.02958308532834053,
0.02497398667037487,
-0.02732674777507782,
0.018735310062766075,
0.019304215908050537,
0.0031241588294506073,
0.013644088990986347,
-0.042542558163404465,
-0.02582252211868763,
0.021425558254122734,
0.0340186171233654,
-0.06645587086677551,
-0.0388784222304821,
0.04902229458093643,
-0.00752112315967679,
-0.03270724415779114,
0.014675832353532314,
0.03964981809258461,
-0.0725884810090065,
-0.06448881328105927,
0.041038334369659424,
-0.024260442703962326,
-0.07644546777009964,
-0.0581633523106575,
0.038107022643089294,
-0.007005251478403807,
0.062406037002801895,
0.022428374737501144,
0.045898135751485825,
0.023836174979805946,
0.007019714917987585,
-0.016806818544864655,
-0.021676262840628624,
-0.01219771895557642,
-0.003273617010563612,
-0.0024009740445762873,
-0.008692682720720768,
0.012091651558876038,
-0.041616883128881454,
0.06367884576320648,
0.03374863043427467,
0.022274095565080643,
0.03162728622555733,
0.006740083452314138,
0.025783952325582504,
0.006185641512274742,
-0.021483413875102997,
-0.0013089646818116307,
-0.025128265842795372,
-0.013779083266854286,
0.030894460156559944,
0.054267797619104385,
-0.02331548184156418,
0.02489684708416462,
0.0032278152648359537,
0.020249178633093834,
0.005269607529044151,
0.014145497232675552,
0.0151290288195014,
-0.02757745236158371,
0.011407037265598774,
-0.04146260395646095,
-0.018552104011178017,
-0.0033652205020189285,
0.00246244459412992,
0.03748990595340729,
-0.053689248859882355,
-0.004895961843430996,
0.04651525616645813,
-0.039765529334545135,
-0.006465273443609476,
0.0819995254278183,
-0.02499327063560486,
-0.00649420078843832,
-0.014347989112138748,
-0.03721991926431656,
-0.029486659914255142,
0.07706258445978165,
-0.00997030921280384,
0.030026638880372047,
-0.06873149424791336,
0.028599552810192108,
-0.03627495467662811,
-0.0006701513775624335,
0.03839629888534546,
0.013701943680644035,
-0.030065208673477173,
0.025436824187636375,
0.03804916888475418,
-0.06186605989933014,
0.029062392190098763,
-0.011426322162151337,
0.0028927396051585674,
0.006021719891577959,
-0.00980156660079956,
0.02580323815345764,
0.010847773402929306,
0.07440126687288284,
-0.0028927396051585674,
-0.059127599000930786,
-0.05974471569061279,
-0.05615771934390068,
-0.05530918389558792,
0.012091651558876038,
-0.0002311178541276604,
0.017125019803643227,
-0.03664137050509453,
0.006985966581851244,
-0.033652205020189285,
0.02329619787633419,
-0.020885581150650978,
-0.01902458444237709,
-0.04821232706308365,
0.002144243335351348,
0.08315662294626236,
0.07991675287485123,
0.013682658784091473,
0.00783932488411665,
0.04663096368312836,
-0.06298458576202393,
0.011860232800245285,
0.03559998422861099,
0.04535815864801407,
-0.011725238524377346,
0.02580323815345764,
-0.014000860042870045,
-0.0037557403557002544,
-0.008538403548300266,
-0.013171607628464699,
-0.01059706974774599,
-0.008957850746810436,
-0.019043870270252228,
-0.05970614776015282,
0.0013704354641959071,
0.009584611281752586,
0.006527949124574661,
-0.08608793467283249,
0.007043821271508932,
0.004476514644920826,
-0.017664996907114983,
-0.025706812739372253,
-0.0014258796581998467,
0.02950594574213028,
-0.01870638318359852,
-0.0348864421248436,
0.03388362377882004,
0.0007274035015143454,
0.0022418731823563576,
0.06414168328046799,
0.0007364433258771896,
-0.009165163151919842,
0.0504879504442215,
-0.04585956782102585,
0.14872539043426514,
0.006267602555453777,
-0.005375674460083246,
-0.018957087770104408,
0.062483176589012146,
-0.0034303071442991495,
0.05149076506495476,
0.0021623228676617146,
0.013634446077048779,
0.04188686981797218,
0.01584257185459137,
0.04250399023294449,
-0.08099671453237534,
-0.002803546842187643,
-0.0032422791700810194,
-0.02129056490957737,
0.050912220031023026,
0.08485370129346848,
-0.052686430513858795,
-0.04994797334074974,
-0.047248080372810364,
-0.03789488971233368,
0.029293810948729515,
-0.01080920360982418,
0.03201298415660858,
-0.008282878436148167,
0.017472147941589355,
0.03729705885052681,
0.02632393129169941,
-0.00398233812302351,
0.006122965831309557,
0.015823286026716232,
-0.03988123685121536,
-0.01165774092078209,
-0.026632489636540413,
-0.02917810156941414,
0.0028879183810204268,
-0.05137505754828453,
0.007362022530287504,
-0.005693876184523106,
-0.018320685252547264,
0.03363291919231415,
0.008331090211868286,
-0.008181632496416569,
0.02113628387451172,
-0.013229463249444962,
-0.029062392190098763,
0.0649130791425705,
0.012380925938487053,
0.08045673370361328,
-0.02113628387451172,
0.072125643491745,
0.019468137994408607,
-0.035252854228019714,
-0.016276482492685318,
-0.06884720176458359,
-0.028850257396697998,
0.045126739889383316,
0.005129791796207428,
-0.0035267318598926067,
0.0017476968932896852,
0.03797202929854393,
0.014068357646465302,
-0.010510287247598171,
-0.020345602184534073,
0.004143849480897188,
0.09434188157320023,
-0.045126739889383316,
0.008229844272136688,
-0.04188686981797218,
-0.045126739889383316,
-0.016700750216841698,
0.008953029289841652,
0.013923720456659794,
-0.01644040457904339,
0.014849397353827953,
0.029235955327749252,
-0.040112655609846115,
0.003114516381174326,
-0.0030084492173045874,
0.04420106112957001,
0.030798034742474556,
0.004293307662010193,
-0.020904865115880966,
0.040344078093767166,
0.008562509901821613,
0.0027119433507323265,
-0.006875078193843365,
0.030277341604232788,
-0.04948513209819794,
-0.0023865101393312216,
-0.033729344606399536,
-0.08477655798196793,
-0.019979188218712807,
0.05272500216960907,
0.060978952795267105,
-0.024761851876974106,
-0.06456594914197922,
-0.01867745630443096,
-0.03957267850637436,
0.012564132921397686,
0.010838131420314312,
0.006257960107177496,
-0.025764668360352516,
0.056697696447372437,
0.03694992884993553,
0.02119413949549198,
0.10776419937610626,
0.026613205671310425,
-0.020152753219008446,
-0.030277341604232788,
0.010298153385519981,
0.014068357646465302,
-0.02940952032804489,
0.03143443912267685,
-0.013007686473429203,
0.03556141257286072,
-0.0008865041891112924,
0.007482553366571665,
0.05870332941412926,
0.061750348657369614,
-0.001087188022211194,
0.03953411057591438,
-0.041192613542079926,
-0.03916769474744797,
0.016864672303199768,
-0.013460882008075714,
0.05179932713508606,
0.0340186171233654,
-0.02447257749736309,
-0.018262829631567,
-0.04188686981797218,
-0.007092033512890339,
0.005144255235791206,
0.006812402047216892,
-0.046900954097509384,
0.04501102864742279,
-0.014531196095049381,
0.03812630847096443,
-0.014704760164022446,
0.028059575706720352,
-0.05156790465116501,
-0.046900954097509384,
-0.026131082326173782,
-0.05322641134262085,
0.005346747115254402,
0.014887967146933079,
-0.02624679170548916,
0.0007557282224297523,
0.08361946046352386,
0.04115404188632965,
-0.022486230358481407,
-0.04767234995961189,
-0.04192544147372246,
0.021811258047819138,
-0.0823080837726593,
-0.0019959902856498957,
0.029120245948433876,
0.01928493194282055,
-0.04099976271390915,
-0.09164199233055115,
-0.010008879005908966,
0.00492488918825984,
-0.0025745383463799953,
0.029370950534939766,
-0.014251564629375935,
-0.059050459414720535,
-0.03201298415660858,
0.05689054727554321,
-0.04570528864860535,
-0.01803141087293625,
-0.03334364667534828,
-0.00486462377011776,
0.024029023945331573,
-0.030875174328684807,
-0.029197385534644127,
-0.08809356391429901,
-0.030065208673477173,
-0.01575578935444355,
-0.06406453996896744,
0.006985966581851244,
0.017568573355674744,
0.005004439502954483,
0.046978093683719635,
0.043583944439888,
-0.03311222791671753,
0.011783093214035034,
0.005081579554826021,
-0.0578547939658165,
-0.0018814861541613936,
0.0034158434718847275,
0.019149936735630035,
0.0022008928935974836,
0.06634016335010529,
0.04099976271390915,
-0.015823286026716232,
-0.014106927439570427,
-0.0481351874768734,
-0.005399780813604593,
-0.049330852925777435,
-0.013605519197881222,
-0.02750031277537346,
0.06279173493385315,
-0.028059575706720352,
-0.011677025817334652,
0.016141487285494804,
-0.018986014649271965,
0.007453626021742821,
-0.028522413223981857,
-0.008909638039767742,
0.07960819453001022,
0.02622750587761402,
0.009999237023293972,
-0.00609885947778821,
-0.02624679170548916,
0.03654494509100914,
0.03471287712454796,
-0.044393911957740784,
0.025938233360648155,
0.035503558814525604,
-0.004131796304136515,
-0.04960084334015846,
-0.03413432836532593,
0.0388784222304821,
-0.004288486670702696,
-0.02966022491455078,
0.024183303117752075,
0.012486993335187435,
0.032900091260671616,
-0.02356618642807007,
-0.0009859420824795961,
0.03303508833050728,
-0.0079164644703269,
0.0485980287194252,
0.04350680485367775,
0.03145372122526169,
0.02942880429327488,
-0.022756218910217285,
0.00863482803106308,
-0.004941763821989298,
-0.03789488971233368,
-0.016700750216841698,
0.018069980666041374,
-0.00012279077782295644,
0.06406453996896744,
0.02329619787633419,
0.01576543226838112,
-0.021309848874807358,
0.01480118464678526,
0.032398685812950134,
0.03438503295183182,
-0.001912824111059308,
0.04944656416773796,
-0.003825648222118616,
-0.006166356615722179,
-0.026420356705784798,
0.06244460865855217,
0.021676262840628624,
-0.02412544935941696,
0.030778750777244568,
-0.04026693478226662,
-0.04335252568125725,
0.02237052097916603,
0.023816891014575958,
-0.0044644614681601524,
0.006585803814232349,
-0.012930546887218952,
-0.008446799591183662,
0.010249940678477287,
0.003167550079524517,
0.023624040186405182,
0.013653730973601341,
0.05824049189686775,
0.026111796498298645,
-0.005669769831001759,
0.025629673153162003,
-0.043391093611717224,
-0.06626302748918533,
0.016131844371557236,
0.07181708514690399,
0.025610389187932014,
-0.03330507501959801,
0.028098145499825478,
0.007419877219945192,
-0.01952599361538887,
0.0279824361205101,
0.043892502784729004,
-0.045319586992263794,
-0.030990883708000183,
0.0006484558107331395,
-0.030142348259687424,
-0.0053563895635306835,
-0.01060671266168356,
0.03436574712395668,
0.018542461097240448,
-0.03369077667593956,
0.006715977564454079,
0.0033025445882230997,
-0.03413432836532593,
0.03403790295124054,
0.006108501926064491,
-0.0039389473386108875,
0.003919662442058325,
-0.00674972590059042,
0.009632823057472706,
-0.047556642442941666,
-0.0205384511500597,
-0.032745812088251114,
0.011995227076113224,
0.03556141257286072,
-0.022486230358481407,
-0.059629008173942566,
0.003427896648645401,
-0.0829252079129219,
-0.0625603199005127,
0.09148771315813065,
0.010491002351045609,
0.019680272787809372,
0.044393911957740784,
-0.015823286026716232,
0.02329619787633419,
-0.018291756510734558,
-0.038685571402311325,
0.013624804094433784,
0.003116927109658718,
-0.07625261694192886,
0.011918087489902973,
0.009931739419698715,
0.04423963278532028,
-0.050256531685590744,
0.023932600393891335,
-0.06533734500408173,
0.06074753403663635,
-0.05723767727613449,
0.02146412804722786,
0.010047448799014091,
-0.0010443995706737041,
0.03737419843673706,
-0.01366337388753891,
-0.014955463819205761,
-0.010674209333956242,
0.01333552971482277,
-0.02314191684126854,
-0.0030470192432403564,
0.026555350050330162,
-0.019632060080766678,
0.039437685161828995,
0.03396076336503029,
-0.04134689271450043,
0.041539743542671204,
0.006932932883501053,
-0.03185870498418808,
0.004650079179555178,
0.06668729335069656,
-0.04551243782043457,
-0.021329134702682495,
0.007173994556069374,
-0.037007782608270645,
-0.02447257749736309,
0.022196955978870392,
0.008827676996588707,
-0.011792735196650028,
0.0026492674369364977,
-0.020596306771039963,
0.02815599925816059,
0.050989359617233276,
0.04466390237212181,
0.03351721167564392,
-0.04801947996020317,
0.03463573753833771,
-0.004729629494249821,
-0.03882056847214699,
0.003934125881642103,
-0.028734548017382622,
0.030373767018318176,
-0.009623181074857712,
0.011869874782860279,
-0.043969642370939255,
0.0121495071798563,
0.04022836685180664,
-0.06452737748622894,
0.054846346378326416,
-0.009377297945320606,
0.025436824187636375,
0.011715595610439777,
-0.03168514370918274,
-0.0009467696072533727,
0.010953840799629688,
0.012409853748977184,
0.004406606778502464,
0.05932044982910156,
-0.023836174979805946,
0.009107308462262154,
-0.029370950534939766,
-0.05307213217020035,
-0.04400821402668953,
0.015640079975128174,
-0.05044937878847122,
0.054190658032894135,
-0.03613996133208275,
-0.040536925196647644,
0.055772021412849426,
0.013509094715118408,
0.04088405519723892,
-0.045126739889383316,
0.02019132301211357,
0.0039148409850895405,
-0.00498515460640192,
0.021695546805858612,
0.035908542573451996,
0.055772021412849426,
-0.014135854318737984,
0.0047031124122440815,
-0.041771162301301956,
0.008943387307226658,
0.009960667230188847,
-0.04508816823363304,
0.0350407212972641,
-0.03251439332962036,
0.03060518577694893,
0.017481790855526924,
0.026632489636540413,
-0.01496510673314333,
0.0487523078918457,
-0.00795985572040081,
-0.04528101906180382,
0.004642846994102001,
-0.055193472653627396,
-0.000579150568228215,
0.06892434507608414,
-0.007998425513505936,
0.04636097326874733,
-0.03413432836532593,
-0.018137477338314056,
0.009661750867962837,
-0.008287698961794376,
0.005824049469083548,
0.04628383368253708,
-0.010934555903077126,
-0.05122077837586403,
-0.08871068060398102,
-0.005549238994717598,
0.005525132641196251,
0.002108084037899971,
-0.0037557403557002544,
0.07686973363161087,
0.012747339904308319,
-0.014724045060575008,
0.06001470610499382,
0.03853129222989082,
-0.05507776513695717,
0.02028774842619896,
0.07096854597330093,
-0.02850312925875187,
0.05978328734636307,
-0.015466514974832535,
0.008726431056857109,
-0.12272930145263672,
0.014145497232675552,
-0.015254381112754345,
-0.018658170476555824,
0.007636833004653454,
0.04709380120038986,
0.050989359617233276,
-0.03446217253804207,
0.051182206720113754
]
|
33,376 | bqplot.marks | GridHeatMap | GridHeatMap mark.
Alignment: The tiles can be aligned so that the data matches either the
start, the end or the midpoints of the tiles. This is controlled by the
align attribute.
Suppose the data passed is a m-by-n matrix. If the scale for the rows is
Ordinal, then alignment is by default the mid points. For a non-ordinal
scale, the data cannot be aligned to the mid points of the rectangles.
If it is not ordinal, then two cases arise. If the number of rows passed
is m, then align attribute can be used. If the number of rows passed
is m+1, then the data are the boundaries of the m rectangles.
If rows and columns are not passed, and scales for them are also
not passed, then ordinal scales are generated for the rows and columns.
Attributes
----------
row_align: Enum(['start', 'end'])
This is only valid if the number of entries in `row` exactly match the
number of rows in `color` and the `row_scale` is not `OrdinalScale`.
`start` aligns the row values passed to be aligned with the start
of the tiles and `end` aligns the row values to the end of the tiles.
column_align: Enum(['start', end'])
This is only valid if the number of entries in `column` exactly
match the number of columns in `color` and the `column_scale` is
not `OrdinalScale`. `start` aligns the column values passed to
be aligned with the start of the tiles and `end` aligns the
column values to the end of the tiles.
anchor_style: dict (default: {})
Controls the style for the element which serves as the anchor during
selection.
display_format: string (default: None)
format for displaying values. If None, then values are not displayed
font_style: dict
CSS style for the text of each cell
Data Attributes
color: numpy.ndarray or None (default: None)
color of the data points (2d array). The number of elements in
this array correspond to the number of cells created in the heatmap.
row: numpy.ndarray or None (default: None)
labels for the rows of the `color` array passed. The length of
this can be no more than 1 away from the number of rows in `color`.
This is a scaled attribute and can be used to affect the height of the
cells as the entries of `row` can indicate the start or the end points
of the cells. Refer to the property `row_align`.
If this property is None, then a uniformly spaced grid is generated in
the row direction.
column: numpy.ndarray or None (default: None)
labels for the columns of the `color` array passed. The length of
this can be no more than 1 away from the number of columns in `color`
This is a scaled attribute and can be used to affect the width of the
cells as the entries of `column` can indicate the start or the
end points of the cells. Refer to the property `column_align`.
If this property is None, then a uniformly spaced grid is generated in
the column direction.
| class GridHeatMap(Mark):
"""GridHeatMap mark.
Alignment: The tiles can be aligned so that the data matches either the
start, the end or the midpoints of the tiles. This is controlled by the
align attribute.
Suppose the data passed is a m-by-n matrix. If the scale for the rows is
Ordinal, then alignment is by default the mid points. For a non-ordinal
scale, the data cannot be aligned to the mid points of the rectangles.
If it is not ordinal, then two cases arise. If the number of rows passed
is m, then align attribute can be used. If the number of rows passed
is m+1, then the data are the boundaries of the m rectangles.
If rows and columns are not passed, and scales for them are also
not passed, then ordinal scales are generated for the rows and columns.
Attributes
----------
row_align: Enum(['start', 'end'])
This is only valid if the number of entries in `row` exactly match the
number of rows in `color` and the `row_scale` is not `OrdinalScale`.
`start` aligns the row values passed to be aligned with the start
of the tiles and `end` aligns the row values to the end of the tiles.
column_align: Enum(['start', end'])
This is only valid if the number of entries in `column` exactly
match the number of columns in `color` and the `column_scale` is
not `OrdinalScale`. `start` aligns the column values passed to
be aligned with the start of the tiles and `end` aligns the
column values to the end of the tiles.
anchor_style: dict (default: {})
Controls the style for the element which serves as the anchor during
selection.
display_format: string (default: None)
format for displaying values. If None, then values are not displayed
font_style: dict
CSS style for the text of each cell
Data Attributes
color: numpy.ndarray or None (default: None)
color of the data points (2d array). The number of elements in
this array correspond to the number of cells created in the heatmap.
row: numpy.ndarray or None (default: None)
labels for the rows of the `color` array passed. The length of
this can be no more than 1 away from the number of rows in `color`.
This is a scaled attribute and can be used to affect the height of the
cells as the entries of `row` can indicate the start or the end points
of the cells. Refer to the property `row_align`.
If this property is None, then a uniformly spaced grid is generated in
the row direction.
column: numpy.ndarray or None (default: None)
labels for the columns of the `color` array passed. The length of
this can be no more than 1 away from the number of columns in `color`
This is a scaled attribute and can be used to affect the width of the
cells as the entries of `column` can indicate the start or the
end points of the cells. Refer to the property `column_align`.
If this property is None, then a uniformly spaced grid is generated in
the column direction.
"""
# Scaled attributes
row = Array(None, allow_none=True).tag(sync=True, scaled=True,
rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
column = Array(None, allow_none=True).tag(sync=True, scaled=True,
rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
color = Array(None, allow_none=True).tag(sync=True, scaled=True,
rtype='Color',
atype='bqplot.ColorAxis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 2))
# Other attributes
scales_metadata = Dict({
'row': {'orientation': 'vertical', 'dimension': 'y'},
'column': {'orientation': 'horizontal', 'dimension': 'x'},
'color': {'dimension': 'color'}
}).tag(sync=True)
row_align = Enum(['start', 'end'], default_value='start').tag(sync=True)
column_align = Enum(['start', 'end'], default_value='start').tag(sync=True)
null_color = Color('black', allow_none=True).tag(sync=True)
stroke = Color('black', allow_none=True).tag(sync=True)
opacity = Float(1.0, min=0.2, max=1).tag(sync=True, display_name='Opacity')
anchor_style = Dict().tag(sync=True)
display_format = Unicode(default_value=None, allow_none=True)\
.tag(sync=True)
font_style = Dict().tag(sync=True)
def __init__(self, **kwargs):
# Adding scales in case they are not passed too.
scales = kwargs.pop('scales', {})
if scales.get('row', None) is None:
row_scale = OrdinalScale(reverse=True)
scales['row'] = row_scale
if scales.get('column', None) is None:
column_scale = OrdinalScale()
scales['column'] = column_scale
kwargs['scales'] = scales
super(GridHeatMap, self).__init__(**kwargs)
@validate('row')
def _validate_row(self, proposal):
row = proposal.value
if row is None:
return row
color = np.asarray(self.color)
n_rows = color.shape[0]
if len(row) != n_rows and len(row) != n_rows + 1 and len(row) != n_rows - 1:
raise TraitError('row must be an array of size color.shape[0]')
return row
@validate('column')
def _validate_column(self, proposal):
column = proposal.value
if column is None:
return column
color = np.asarray(self.color)
n_columns = color.shape[1]
if len(column) != n_columns and len(column) != n_columns + 1 and len(column) != n_columns - 1:
raise TraitError('column must be an array of size color.shape[1]')
return column
_view_name = Unicode('GridHeatMap').tag(sync=True)
_model_name = Unicode('GridHeatMapModel').tag(sync=True)
| (**kwargs) | [
0.05573783442378044,
-0.04930027574300766,
-0.015360499732196331,
0.03976617380976677,
-0.0221443809568882,
-0.03636404871940613,
-0.04298495128750801,
0.024181582033634186,
-0.04031621664762497,
-0.04608149826526642,
-0.0021072302479296923,
0.03815678507089615,
0.053537655621767044,
0.01688840053975582,
-0.014097434468567371,
-0.016806911677122116,
0.004586250055581331,
-0.011000888422131538,
0.06026042252779007,
-0.018039420247077942,
0.0331248976290226,
-0.07183172553777695,
0.037688229233026505,
0.020667409524321556,
0.020555363968014717,
0.020555363968014717,
0.006758416071534157,
0.019811784848570824,
0.05247830972075462,
-0.019475646317005157,
-0.05793801322579384,
-0.04031621664762497,
-0.014922501519322395,
0.04966697469353676,
0.036588139832019806,
-0.1094384640455246,
0.037158556282520294,
0.01575775444507599,
-0.006432463880628347,
0.01897653192281723,
0.018131094053387642,
0.0002933251962531358,
0.06343845278024673,
-0.0517856627702713,
0.060178931802511215,
0.02911161072552204,
-0.00634078960865736,
-0.004357064608484507,
-0.0719132125377655,
-0.047385308891534805,
0.03021169826388359,
-0.058752890676259995,
0.02155359275639057,
0.06816476583480835,
-0.06849071383476257,
0.05700089782476425,
0.03526395931839943,
0.06380515545606613,
-0.0062134647741913795,
-0.054026585072278976,
-0.005724536255002022,
0.02465013787150383,
-0.0026636410038918257,
-0.027196640148758888,
-0.039501339197158813,
-0.011398142203688622,
-0.012090791016817093,
-0.013201066292822361,
0.026116924360394478,
0.016715237870812416,
-0.002760407980531454,
0.05871214717626572,
0.03836050629615784,
-0.020300712436437607,
-0.03652702271938324,
-0.0004882917273789644,
-0.061075299978256226,
0.033532336354255676,
0.041477423161268234,
-0.04157928377389908,
0.0034174055326730013,
0.05321170389652252,
0.06453854590654373,
-0.02713552489876747,
0.026952175423502922,
-0.04665191471576691,
0.028907889500260353,
0.0960744246840477,
-0.02355005033314228,
-0.018273698166012764,
-0.014362270943820477,
-0.002704384969547391,
0.006447742693126202,
0.01466785091906786,
0.01897653192281723,
-0.0132214380428195,
0.022572193294763565,
-0.004112600814551115,
-0.0251594390720129,
-0.013058462180197239,
0.0309247188270092,
-0.06629053503274918,
0.03819752857089043,
-0.0210442915558815,
-0.06136050820350647,
-0.03361382335424423,
-0.05113375931978226,
0.02968202717602253,
-0.044696200639009476,
0.015615149401128292,
-0.012325068935751915,
0.02788928896188736,
-0.02966165356338024,
-0.03438796103000641,
0.019516389816999435,
-0.03941984847187996,
-0.030374674126505852,
-0.0003733808407559991,
-0.0017545397859066725,
-0.013588134199380875,
0.004211914259940386,
-0.03669000044465065,
0.00522032892331481,
-0.00038547671283595264,
-0.0028902797494083643,
0.022022148594260216,
-0.0030965462792664766,
0.0629495307803154,
-0.021675825119018555,
-0.06413110345602036,
-0.006824625190347433,
-0.02784854546189308,
-0.029539423063397408,
0.013374228030443192,
0.020534992218017578,
-0.02915235422551632,
0.04942250996828079,
0.027298500761389732,
-0.02841896191239357,
0.09069621562957764,
0.08808859437704086,
-0.015869800001382828,
0.0008581711445003748,
-0.02014792338013649,
-0.005342560820281506,
-0.03872720152139664,
0.02823561243712902,
0.011540746316313744,
-0.010929586365818977,
-0.0031016392167657614,
-0.014851199463009834,
-0.006615811958909035,
0.03180071711540222,
0.026768827810883522,
0.0320248082280159,
-0.007400134578347206,
0.00909610465168953,
-0.026157667860388756,
0.06796104460954666,
0.03819752857089043,
-0.040540311485528946,
-0.016531890258193016,
0.027257757261395454,
0.01943490281701088,
-0.027665195986628532,
0.05284500867128372,
0.003618579125031829,
-0.08311782032251358,
-0.0035701957531273365,
0.004749225918203592,
-0.025403903797268867,
-0.03558991104364395,
-0.0266262236982584,
0.022042520344257355,
0.0045073083601891994,
0.06718690693378448,
-0.016185566782951355,
0.020779455080628395,
0.004446192178875208,
0.010231845080852509,
-0.033369362354278564,
0.002951395697891712,
0.015574405901134014,
0.024222325533628464,
-0.03836050629615784,
0.028317101299762726,
0.05019664391875267,
-0.0435553677380085,
0.019648808985948563,
0.011204608716070652,
0.024772370234131813,
-0.021370243281126022,
-0.017244910821318626,
0.02465013787150383,
0.01386315654963255,
0.012162093073129654,
-0.004446192178875208,
-0.0210442915558815,
-0.009019710123538971,
-0.004942760337144136,
-0.03400089219212532,
-0.036588139832019806,
0.026585480198264122,
0.0077515519224107265,
0.016073519363999367,
-0.0316581130027771,
0.04530736058950424,
-0.01203986071050167,
-0.031006207689642906,
0.011724094860255718,
-0.04567405954003334,
-0.02462976612150669,
-0.0347750298678875,
0.03169885650277138,
0.05663420259952545,
-0.06409036368131638,
-0.018069976940751076,
0.02265368029475212,
-0.03259522467851639,
0.015869800001382828,
0.06457928568124771,
-0.004372343886643648,
0.040560681372880936,
0.007002880331128836,
0.039827290922403336,
-0.02078964188694954,
0.041457049548625946,
0.009523916989564896,
0.028480077162384987,
-0.01394464448094368,
-0.007089461199939251,
-0.05463774502277374,
0.015655893832445145,
0.03595660626888275,
-0.02194065973162651,
-0.02984500303864479,
0.017682909965515137,
0.0219610333442688,
-0.002365700202062726,
0.03536581993103027,
0.004082042723894119,
0.05948628485202789,
-0.02660585194826126,
-0.01061381958425045,
0.009427149780094624,
-0.042903464287519455,
0.04047919437289238,
0.06767583638429642,
-0.06079009175300598,
-0.049952182918787,
-0.0741133913397789,
-0.0015482731396332383,
0.011601862497627735,
0.02159433625638485,
-0.006101418752223253,
-0.047059353440999985,
-0.011408329010009766,
0.006534324027597904,
0.019282111898064613,
-0.04310718551278114,
-0.0015571858966723084,
-0.0678795576095581,
0.04388131946325302,
0.07386893033981323,
0.0755801796913147,
0.006982508115470409,
-0.01750974729657173,
0.048648372292518616,
-0.04225156083703041,
0.037871576845645905,
-0.008342340588569641,
0.07419487833976746,
-0.024690883234143257,
0.027746684849262238,
0.014077062718570232,
0.022938888520002365,
0.03328787162899971,
-0.053659889847040176,
-0.010410100221633911,
0.005454607307910919,
-0.030863603577017784,
-0.05537113919854164,
-0.005907884333282709,
-0.0025133974850177765,
0.028704170137643814,
-0.07562091946601868,
-0.029967235401272774,
-0.023122237995266914,
0.012905671261250973,
-0.002090678084641695,
-0.04388131946325302,
-0.0041202399879693985,
-0.03905315324664116,
-0.02304074913263321,
0.02446679025888443,
-0.07183172553777695,
0.01645040325820446,
0.014708595350384712,
-0.03654739633202553,
-0.06710541993379593,
0.07052791863679886,
-0.049952182918787,
0.1200319156050682,
-0.002028288785368204,
-0.01195837277919054,
0.030170954763889313,
0.024364929646253586,
0.0045760637149214745,
0.04934101924300194,
0.006310231518000364,
0.04371834546327591,
0.043433137238025665,
-0.013078833930194378,
-0.012538975104689598,
-0.02407972142100334,
-0.007807574700564146,
0.028276357799768448,
0.011907442472875118,
0.03954208269715309,
0.05239682272076607,
-0.04176263138651848,
-0.0730133056640625,
-0.03290080651640892,
-0.02951904945075512,
0.04278123378753662,
-0.021186895668506622,
0.03512135520577431,
-0.013435344211757183,
0.010471215471625328,
0.04196635261178017,
-0.006427370943129063,
0.016531890258193016,
0.016022590920329094,
0.03143401816487312,
-0.0038146597798913717,
-0.04600001126527786,
-0.0406217984855175,
0.032839689403772354,
-0.0277263130992651,
-0.09085918962955475,
0.003924159333109856,
0.008301596157252789,
-0.02627990022301674,
0.012661207467317581,
0.0223277285695076,
-0.022959262132644653,
0.011438886635005474,
-0.0033461034763604403,
-0.03314526751637459,
0.07590612769126892,
0.03542693331837654,
0.008836361579596996,
-0.019628437235951424,
0.00007723063026787713,
0.030680254101753235,
-0.014158550649881363,
0.014963245019316673,
-0.08499205112457275,
0.013649250380694866,
0.032493364065885544,
0.050481852144002914,
-0.062338367104530334,
-0.008449293673038483,
0.01672542467713356,
-0.033308245241642,
-0.0029641282744705677,
-0.04624447599053383,
0.014087248593568802,
0.0532524473965168,
0.0010918127372860909,
0.05129673331975937,
-0.019750669598579407,
-0.008174271322786808,
-0.002215456683188677,
-0.006580160930752754,
-0.017856070771813393,
-0.04844465106725693,
0.02733924426138401,
-0.04298495128750801,
-0.07509125024080276,
0.035712141543626785,
-0.006875555031001568,
-0.0014451398747041821,
0.039664313197135925,
-0.02375376969575882,
-0.052641287446022034,
0.04783349111676216,
0.006096325349062681,
-0.03772897273302078,
-0.03025244176387787,
0.005077724810689688,
-0.030313558876514435,
0.04987069219350815,
-0.028357844799757004,
-0.04762976989150047,
0.012997345998883247,
0.032819315791130066,
0.0689796432852745,
0.013588134199380875,
-0.026870688423514366,
-0.02894863300025463,
-0.05663420259952545,
0.041457049548625946,
-0.025852087885141373,
0.006371347699314356,
-0.021268384531140327,
0.05239682272076607,
0.00990079902112484,
0.03793269395828247,
0.07602836191654205,
0.0036414978094398975,
0.01654207706451416,
-0.01661337912082672,
-0.015340127050876617,
-0.028174497187137604,
-0.06853146106004715,
-0.02267405390739441,
-0.02304074913263321,
-0.03962356969714165,
-0.003936891909688711,
-0.0305580236017704,
0.03347122296690941,
0.009508637711405754,
0.0327582024037838,
0.00853587407618761,
-0.06466078013181686,
-0.03701595216989517,
0.007339018397033215,
-0.013353856280446053,
0.01890522986650467,
-0.0212276391685009,
-0.041620027273893356,
-0.013659436255693436,
-0.00629495270550251,
0.004527680575847626,
-0.015105849131941795,
-0.008092783391475677,
-0.019078392535448074,
0.024222325533628464,
-0.02591320313513279,
0.026320643723011017,
-0.026666967198252678,
0.032982293516397476,
-0.044533226639032364,
-0.027196640148758888,
-0.021288756281137466,
-0.07647654414176941,
0.017285654321312904,
0.010736051946878433,
-0.015778126195073128,
0.04665191471576691,
0.07949160039424896,
-0.0015266279224306345,
-0.010287867859005928,
0.005806024186313152,
-0.07562091946601868,
-0.045062899589538574,
-0.04852614179253578,
0.020433131605386734,
0.026116924360394478,
-0.0035880212672054768,
0.009860055521130562,
-0.054434023797512054,
-0.00836271233856678,
0.009518824517726898,
-0.012701951898634434,
0.024935346096754074,
-0.042373791337013245,
-0.04481843486428261,
-0.028480077162384987,
0.015696637332439423,
-0.06633128225803375,
0.0011293735587969422,
-0.004308681003749371,
-0.00986514799296856,
0.03141364827752113,
0.0005395400803536177,
0.03186183050274849,
-0.049218788743019104,
-0.0223277285695076,
0.0409884937107563,
-0.02499646320939064,
0.02949867770075798,
0.0011121847201138735,
0.003962357062846422,
0.05553411319851875,
0.05097078159451485,
-0.0342249870300293,
-0.008897477760910988,
0.005632862448692322,
-0.10039328783750534,
0.004616808146238327,
0.03567139804363251,
0.08295484632253647,
-0.019536763429641724,
0.014728967100381851,
0.06775732338428497,
-0.0393383614718914,
-0.003710253397002816,
-0.03595660626888275,
0.03882906213402748,
0.008999337442219257,
0.01330292597413063,
0.00701815914362669,
0.04677414894104004,
-0.0633162260055542,
0.018691323697566986,
0.03567139804363251,
-0.0032136854715645313,
-0.021349871531128883,
-0.04718158766627312,
-0.024914974346756935,
0.08328080177307129,
-0.016460588201880455,
0.005064992234110832,
-0.015655893832445145,
-0.05504518374800682,
-0.030456162989139557,
0.006870462093502283,
-0.01791718788444996,
0.019954388961195946,
0.049381766468286514,
0.018823742866516113,
-0.015615149401128292,
-0.031739600002765656,
0.08332154154777527,
0.09224448353052139,
-0.007542738690972328,
0.0038350317627191544,
0.010970329865813255,
-0.014138178899884224,
-0.02982463128864765,
0.04064217209815979,
0.016898587346076965,
-0.016766168177127838,
0.019567320123314857,
-0.014005760662257671,
-0.017051376402378082,
0.0212276391685009,
-0.023244470357894897,
-0.017153237015008926,
0.0012968061491847038,
0.05072631686925888,
-0.07134279608726501,
0.014769711531698704,
0.016348542645573616,
0.05137822404503822,
-0.012620463036000729,
-0.007894155569374561,
-0.03471391275525093,
0.015268824994564056,
0.04068291559815407,
0.03398052230477333,
-0.008245573379099369,
0.0011064551072195172,
0.0316581130027771,
-0.022022148594260216,
-0.03343047574162483,
0.02593357488512993,
0.014392828568816185,
0.0046269940212368965,
0.03744376450777054,
0.02157396450638771,
-0.012834369204938412,
-0.037891946732997894,
0.015065105631947517,
-0.03161736950278282,
0.05374137684702873,
-0.03666962683200836,
-0.01330292597413063,
-0.015146593563258648,
0.003998008091002703,
-0.0038044739048928022,
0.009157220833003521,
-0.006432463880628347,
0.0007028345135040581,
-0.010073961690068245,
-0.010043403133749962,
-0.010970329865813255,
-0.09053323417901993,
0.010858284309506416,
0.039134640246629715,
0.006625997833907604,
-0.05899735540151596,
0.02318335324525833,
0.0353250727057457,
-0.0517856627702713,
0.07655803114175797,
-0.01897653192281723,
-0.044859178364276886,
0.016735611483454704,
0.0038273923564702272,
-0.00040362056461162865,
-0.009977194480597973,
-0.002768047619611025,
0.03133216127753258,
0.02467050962150097,
-0.019679367542266846,
0.027970777824521065,
-0.0052712587639689445,
-0.017428258433938026,
0.028704170137643814,
-0.03882906213402748,
-0.01052214577794075,
0.0196691807359457,
-0.06250134110450745,
0.06470151990652084,
-0.031576622277498245,
-0.020626666024327278,
-0.02607617899775505,
0.023488933220505714,
0.009982287883758545,
-0.02359079383313656,
-0.03870682790875435,
0.0017252550460398197,
-0.08539948612451553,
-0.08140657097101212,
0.05378212034702301,
0.04604075476527214,
-0.003065988188609481,
-0.0011319201439619064,
0.026137296110391617,
-0.008561339229345322,
0.0025681471452116966,
-0.001893324195407331,
-0.007435785606503487,
0.012253766879439354,
-0.029274586588144302,
0.0037127998657524586,
-0.016185566782951355,
0.022246241569519043,
0.011428700760006905,
0.039134640246629715,
-0.040540311485528946,
0.02428344264626503,
-0.008978965692222118,
0.014810455031692982,
0.007023252081125975,
0.02375376969575882,
0.02481311373412609,
0.022755540907382965,
-0.04176263138651848,
0.02375376969575882,
0.0678795576095581,
-0.0036873347125947475,
-0.011275910772383213,
0.03946059197187424,
-0.036445535719394684,
0.015105849131941795,
-0.003305359510704875,
-0.010135077871382236,
0.05683792382478714,
0.009192871861159801,
-0.03669000044465065,
-0.031230298802256584,
0.06567937880754471,
-0.07020196318626404,
-0.03848273679614067,
-0.037178926169872284,
-0.007807574700564146,
-0.03434721753001213,
0.03972543030977249,
-0.033756427466869354,
-0.009641055949032307,
0.019220996648073196,
-0.037178926169872284,
0.04204783961176872,
0.041273701936006546,
0.03611958399415016,
0.06474226713180542,
-0.05647122487425804,
-0.011601862497627735,
-0.014403014443814754,
-0.05231533572077751,
0.007542738690972328,
-0.012131535448133945,
0.01819220930337906,
-0.002028288785368204,
-0.00696213636547327,
0.005449513904750347,
0.055126674473285675,
0.02623915486037731,
-0.08156955242156982,
0.11783173680305481,
0.03754562512040138,
0.01973029598593712,
0.013109391555190086,
-0.05072631686925888,
0.012141721323132515,
0.017214352265000343,
0.06502747535705566,
-0.004318867344409227,
0.0415385402739048,
-0.010226751677691936,
0.005212689284235239,
-0.035508424043655396,
-0.090044304728508,
-0.01601240411400795,
0.025994691997766495,
0.0037408112548291683,
0.00972763728350401,
-0.031026579439640045,
-0.066616490483284,
0.06327547878026962,
0.0038273923564702272,
0.0349583774805069,
-0.02660585194826126,
0.028643053025007248,
0.01870151050388813,
0.0029692212119698524,
0.023122237995266914,
0.09395573288202286,
0.051541198045015335,
-0.027278129011392593,
-0.04261825606226921,
-0.031943321228027344,
0.01132684014737606,
0.03131178766489029,
-0.026544736698269844,
0.010038310661911964,
-0.01105181872844696,
0.01860983669757843,
-0.013567762449383736,
-0.024792741984128952,
-0.036608509719371796,
0.042088583111763,
-0.03927724435925484,
-0.04571480304002762,
-0.021635079756379128,
-0.035508424043655396,
0.002514670602977276,
0.024242697283625603,
-0.011296282522380352,
0.08458460867404938,
0.0006977415177971125,
0.00727790268138051,
0.007593668531626463,
-0.0016743249725550413,
-0.020107179880142212,
0.02179805561900139,
-0.02988574653863907,
-0.04852614179253578,
-0.04408504068851471,
-0.024935346096754074,
0.005480071995407343,
0.0733800008893013,
0.01332329772412777,
0.06246059760451317,
-0.004056577570736408,
0.018823742866516113,
0.044696200639009476,
0.04514438658952713,
-0.06922410428524017,
0.017407886683940887,
0.07761737704277039,
-0.049911435693502426,
0.04286272078752518,
-0.021859172731637955,
0.007130205165594816,
-0.07252437621355057,
0.0012719776714220643,
-0.024792741984128952,
-0.05492295324802399,
0.013435344211757183,
0.03825864568352699,
0.049707718193531036,
0.0036338581703603268,
0.06429407745599747
]
|
33,381 | bqplot.marks | __init__ | null | def __init__(self, **kwargs):
# Adding scales in case they are not passed too.
scales = kwargs.pop('scales', {})
if scales.get('row', None) is None:
row_scale = OrdinalScale(reverse=True)
scales['row'] = row_scale
if scales.get('column', None) is None:
column_scale = OrdinalScale()
scales['column'] = column_scale
kwargs['scales'] = scales
super(GridHeatMap, self).__init__(**kwargs)
| (self, **kwargs) | [
0.019122129306197166,
-0.03529966622591019,
0.03643492981791496,
-0.004851486533880234,
-0.06467466056346893,
0.00005370061262510717,
-0.017729656770825386,
0.04973882436752319,
-0.03274531662464142,
-0.004962352570146322,
0.008687443099915981,
0.10834690928459167,
-0.005294949747622013,
0.0019589983858168125,
0.003875867696478963,
-0.00019928124675061554,
-0.007973466999828815,
-0.012753999792039394,
0.033224258571863174,
-0.023858316242694855,
0.030776340514421463,
-0.05690518766641617,
0.010181913152337074,
0.09387227147817612,
0.036009207367897034,
0.04438178986310959,
-0.01059876848012209,
0.011246224865317345,
0.04406249523162842,
-0.03343712165951729,
-0.03973429650068283,
0.020523473620414734,
-0.01803121156990528,
0.07961050420999527,
0.024461425840854645,
-0.07134434580802917,
0.00020634893735405058,
-0.003858129261061549,
-0.06769020855426788,
0.05388963967561722,
0.0618719756603241,
-0.02036382630467415,
0.0004664677835535258,
-0.043565817177295685,
0.06729996204376221,
0.03895379975438118,
0.007055498193949461,
-0.04863903671503067,
-0.018607713282108307,
-0.030386094003915787,
-0.0047273170202970505,
-0.025259660556912422,
0.028026869520545006,
0.04172101244330406,
-0.09614280611276627,
0.06385868787765503,
0.02694481983780861,
0.09351750463247299,
-0.023609977215528488,
-0.02996036969125271,
-0.05857260897755623,
0.012638699263334274,
-0.0627589002251625,
-0.051370769739151,
-0.005543289240449667,
-0.0324615016579628,
-0.04505585506558418,
0.0030998073052614927,
0.010953539051115513,
0.03111337311565876,
0.010439122095704079,
0.04502037540078163,
-0.013667533174157143,
-0.007680781185626984,
-0.01439481321722269,
-0.0036142244935035706,
-0.04693613573908806,
0.06421346217393875,
0.004572104662656784,
0.01073180790990591,
-0.030261924490332603,
-0.00023309531388804317,
0.007392530329525471,
0.007037759758532047,
-0.00600449088960886,
-0.08393870294094086,
0.018607713282108307,
0.03008453920483589,
0.005915798246860504,
0.004352590534836054,
-0.05477656424045563,
-0.01117527112364769,
0.021676477044820786,
0.005982317496091127,
0.05144172161817551,
0.002527739852666855,
0.0113349175080657,
0.020009055733680725,
-0.003995602950453758,
-0.042040303349494934,
0.03097146563231945,
-0.07776569575071335,
0.03435952216386795,
-0.03689613193273544,
-0.03835069015622139,
-0.01864318922162056,
-0.002869206480681896,
-0.028292948380112648,
-0.0702800378203392,
0.030297400429844856,
-0.013649795204401016,
0.05736638978123665,
0.006204049102962017,
0.021729692816734314,
-0.04186291992664337,
-0.02407117933034897,
-0.024958105757832527,
-0.010297213681042194,
0.01670082099735737,
0.006368130445480347,
-0.05016455054283142,
0.02025739662349224,
0.032106731086969376,
0.023201990872621536,
0.003991167992353439,
0.04108242318034172,
-0.014341597445309162,
0.009472372010350227,
-0.025986939668655396,
0.0022461407352238894,
0.031361714005470276,
-0.03597372770309448,
-0.054137978702783585,
-0.0002121693833032623,
0.014385944232344627,
-0.06233317777514458,
0.07797855883836746,
0.049313098192214966,
0.01591145619750023,
0.08408060669898987,
0.06240412965416908,
0.015246262773871422,
0.011813857592642307,
0.003968995064496994,
0.013348240405321121,
0.037215426564216614,
0.04743281751871109,
0.031343974173069,
-0.012257320806384087,
-0.031343974173069,
-0.01780947856605053,
0.01882057450711727,
0.016479089856147766,
0.01835937425494194,
0.020239656791090965,
-0.06925120204687119,
-0.0024346124846488237,
-0.008119809441268444,
0.057153526693582535,
0.02591598592698574,
0.020204180851578712,
0.03622206673026085,
0.02424856461584568,
-0.024816196411848068,
-0.053818684071302414,
0.02137492224574089,
0.00584040954709053,
-0.11608090996742249,
0.024284040555357933,
0.027938177809119225,
-0.019068915396928787,
-0.05303819105029106,
-0.0024567856453359127,
0.009294986724853516,
0.006612035445868969,
0.03448369354009628,
-0.002394700888544321,
0.0076275658793747425,
0.007104279473423958,
0.05417345464229584,
0.008851524442434311,
-0.016399266198277473,
0.0018514585681259632,
0.01071406900882721,
-0.008780569769442081,
-0.00566745875403285,
0.032993655651807785,
-0.015476862899959087,
-0.03613337501883507,
0.017543401569128036,
0.060630280524492264,
0.02396474778652191,
-0.041437193751335144,
-0.009153079241514206,
0.04030193015933037,
0.0118936812505126,
0.020665381103754044,
-0.06662590056657791,
-0.047645676881074905,
0.05843070149421692,
-0.04360129311680794,
-0.03771210461854935,
0.03459012508392334,
-0.0004672992799896747,
0.02657231129705906,
-0.0007333771209232509,
0.04065670073032379,
-0.011042231693863869,
0.00031818478601053357,
0.021942555904388428,
-0.004594278056174517,
-0.017099937424063683,
-0.019583331421017647,
0.001273847883567214,
-0.002022191882133484,
-0.01650569774210453,
-0.0784752368927002,
-0.007250621914863586,
-0.000307375390548259,
0.006855939980596304,
0.071025051176548,
0.019955839961767197,
0.027743052691221237,
0.01048346795141697,
0.03102467954158783,
0.001493362127803266,
0.06616470217704773,
-0.017312800511717796,
0.009357072412967682,
0.0491357147693634,
-0.05587635561823845,
-0.051264338195323944,
0.0056585893034935,
0.013348240405321121,
-0.010722937993705273,
-0.003924648743122816,
0.017099937424063683,
0.010678592137992382,
-0.00449671596288681,
0.0037539154291152954,
0.006190745159983635,
0.045268714427948,
-0.03742828965187073,
-0.0358140803873539,
-0.014811668545007706,
-0.028257470577955246,
-0.012319405563175678,
0.07045742124319077,
-0.04257246106863022,
-0.027104467153549194,
0.000535204540938139,
0.007640869822353125,
0.008075463585555553,
0.02962333709001541,
-0.02096693590283394,
-0.058856427669525146,
-0.03852807730436325,
-0.021587785333395004,
-0.02781400829553604,
-0.06510038673877716,
-0.02059442736208439,
-0.03710899502038956,
-0.015157570131123066,
0.0859963670372963,
0.05314462259411812,
-0.019583331421017647,
-0.017366016283631325,
0.03686065599322319,
-0.027565667405724525,
0.019317254424095154,
0.05757925286889076,
0.03251471742987633,
-0.001267195912078023,
0.03315330296754837,
0.05012907087802887,
0.017232976853847504,
0.03159231320023537,
-0.10458634048700333,
-0.028434855863451958,
0.0302264466881752,
0.004594278056174517,
-0.04381415620446205,
-0.007361487951129675,
-0.00455436622723937,
0.03315330296754837,
-0.0550958588719368,
-0.021392662078142166,
-0.01333050150424242,
-0.029694290831685066,
0.007636434864252806,
-0.01096240896731615,
0.02847033366560936,
-0.05197387933731079,
0.0294814296066761,
0.007374791894108057,
-0.07968145608901978,
0.03611563891172409,
0.014518982730805874,
-0.02313103713095188,
-0.005033306311815977,
0.05012907087802887,
-0.08635114133358002,
0.0937303677201271,
0.013694141060113907,
0.03616885095834732,
0.013995696790516376,
0.001508883317001164,
0.009472372010350227,
0.04125981032848358,
0.042040303349494934,
0.07365035265684128,
0.06903833895921707,
-0.02818651683628559,
-0.004179640207439661,
-0.05871451646089554,
0.0012040024157613516,
0.045552533119916916,
-0.01659438945353031,
0.00303107057698071,
0.031131111085414886,
-0.039485957473516464,
-0.05410250276327133,
-0.04548157751560211,
-0.02350354567170143,
0.018625451251864433,
0.026182062923908234,
0.026040155440568924,
-0.03937952592968941,
0.022013509646058083,
0.05318009853363037,
-0.013853788375854492,
0.020275134593248367,
0.024887150153517723,
0.006306045688688755,
-0.04136624187231064,
-0.04835521802306175,
0.0047184475697577,
0.07875905185937881,
-0.029694290831685066,
-0.04803592711687088,
-0.0011541127460077405,
-0.015884850174188614,
-0.02921535074710846,
0.023574499413371086,
-0.0027805138379335403,
-0.004745055455714464,
0.01222184393554926,
-0.05690518766641617,
-0.01901569962501526,
0.012319405563175678,
-0.006408042274415493,
-0.056408509612083435,
-0.018119903281331062,
-0.001406886731274426,
0.052612464874982834,
0.033366166055202484,
0.02341485396027565,
-0.055060382932424545,
0.0253128744661808,
0.008177460171282291,
0.10096768289804459,
-0.05303819105029106,
-0.044807516038417816,
-0.011902550235390663,
0.002058777492493391,
0.002483393531292677,
0.014013434760272503,
0.01614205725491047,
0.04910023882985115,
0.017747394740581512,
0.0407986082136631,
-0.01835937425494194,
-0.00244569918140769,
0.04512680694460869,
0.0024501336738467216,
-0.009419157169759274,
-0.05144172161817551,
0.004980091005563736,
-0.03370319679379463,
-0.06098505109548569,
-0.0009102080948650837,
-0.042075783014297485,
0.014802799560129642,
0.0026896039489656687,
-0.03129075840115547,
-0.026377186179161072,
0.022474711760878563,
0.012195236049592495,
-0.003339277347549796,
-0.06233317777514458,
-0.007401399780064821,
-0.007192972116172314,
0.04761020094156265,
-0.025578953325748444,
-0.03361450508236885,
0.0094368951395154,
0.0635039210319519,
0.04150814935564995,
0.026377186179161072,
0.0027206463273614645,
-0.024514641612768173,
-0.07925572991371155,
0.027299590408802032,
-0.012035589665174484,
0.021339446306228638,
-0.0169757679104805,
0.0332774743437767,
0.01678064465522766,
0.08571255207061768,
0.028434855863451958,
0.02694481983780861,
0.020736336708068848,
0.00039967114571481943,
-0.0407276526093483,
-0.02698029763996601,
-0.04001811146736145,
-0.0207718126475811,
-0.011636472307145596,
-0.027335066348314285,
-0.026767434552311897,
-0.02068312093615532,
0.06925120204687119,
-0.030545739457011223,
0.013862657360732555,
0.06733544170856476,
-0.05151267722249031,
-0.011751772835850716,
-0.03318877890706062,
0.011148663237690926,
0.043743204325437546,
-0.08046194911003113,
-0.02976524457335472,
-0.005804932210594416,
-0.011600995436310768,
0.05208031088113785,
-0.003929083235561848,
0.014483505859971046,
-0.00578275928273797,
-0.03803139925003052,
-0.02295365184545517,
0.02286495827138424,
-0.05034193396568298,
0.03175196051597595,
-0.028718672692775726,
-0.01145021803677082,
-0.00672290101647377,
-0.05956596881151199,
0.02059442736208439,
0.026643265038728714,
-0.04136624187231064,
0.04604921117424965,
0.01488262228667736,
-0.01488262228667736,
-0.022173156961798668,
0.047823064029216766,
-0.08557064831256866,
-0.10515397787094116,
-0.0049268752336502075,
0.04253698140382767,
0.005507811903953552,
-0.02504679746925831,
-0.025241920724511147,
-0.019405946135520935,
-0.06517133861780167,
-0.004343721549957991,
0.04548157751560211,
0.0332065187394619,
-0.026590049266815186,
-0.026182062923908234,
-0.03184065222740173,
-0.0028669892344623804,
0.01451011374592781,
0.00399781996384263,
-0.048106878995895386,
-0.04714899882674217,
-0.000542410823982209,
0.021552307531237602,
0.025259660556912422,
-0.01821746490895748,
-0.021587785333395004,
0.017703048884868622,
-0.0016585520934313536,
0.07208936661481857,
0.009481241926550865,
-0.01488262228667736,
0.015636509284377098,
-0.0006064358167350292,
-0.04033740609884262,
-0.025561215355992317,
0.025667645037174225,
-0.04580087214708328,
0.034802984446287155,
-0.003055460983887315,
0.0937303677201271,
-0.001010541571304202,
0.023751884698867798,
0.052009355276823044,
-0.02444368787109852,
-0.007246187422424555,
0.024230824783444405,
0.012700784020125866,
0.013924742117524147,
-0.004696274641901255,
0.026696480810642242,
0.010217390023171902,
-0.028452593833208084,
0.005365903954952955,
0.04558800905942917,
-0.022368280217051506,
0.00013581058010458946,
-0.021960293874144554,
-0.026235278695821762,
0.02651909552514553,
0.031734220683574677,
0.01521078497171402,
0.017463577911257744,
-0.09891001880168915,
-0.02878962643444538,
-0.008851524442434311,
0.035352881997823715,
0.041295286267995834,
0.039627864956855774,
0.0430336631834507,
-0.0063592614606022835,
-0.012949123047292233,
0.03547704964876175,
0.10217390209436417,
-0.010430253110826015,
0.02689160406589508,
0.05871451646089554,
-0.012372621335089207,
-0.058856427669525146,
-0.028346162289381027,
0.061552681028842926,
-0.027565667405724525,
0.039947159588336945,
-0.031929343938827515,
-0.025791816413402557,
0.007822689600288868,
-0.05193840339779854,
-0.026696480810642242,
-0.01522852387279272,
0.11409419029951096,
-0.08216484636068344,
0.01590258814394474,
-0.03450142964720726,
-0.011370394378900528,
0.03318877890706062,
0.030173230916261673,
-0.029871676117181778,
-0.00827945675700903,
-0.0021485788747668266,
0.0052905152551829815,
-0.014022303745150566,
-0.05303819105029106,
0.024408210068941116,
-0.03824425861239433,
-0.043104615062475204,
-0.006217353045940399,
0.015290608629584312,
0.013046685606241226,
0.016062233597040176,
0.07975240796804428,
0.057614728808403015,
-0.0769142434000969,
-0.02091372199356556,
-0.027459237724542618,
0.06992526352405548,
-0.03203577548265457,
0.007148625794798136,
-0.024035701528191566,
-0.03487394005060196,
-0.020275134593248367,
0.013108770363032818,
-0.0430336631834507,
-0.0059956214390695095,
0.053996071219444275,
-0.008133113384246826,
-0.029800722375512123,
-0.0665549486875534,
-0.021179798990488052,
0.028026869520545006,
-0.02086050622165203,
-0.007450180593878031,
-0.0013115422334522009,
0.044346313923597336,
-0.020186441019177437,
0.05083861202001572,
-0.025703122839331627,
-0.037534717470407486,
0.058537133038043976,
-0.014873753301799297,
0.03182291239500046,
-0.0022284022998064756,
-0.01938820816576481,
-0.005308253690600395,
-0.004204030614346266,
-0.03824425861239433,
0.009747319854795933,
-0.011326048523187637,
-0.03219542279839516,
0.05754377692937851,
-0.05133529007434845,
0.019352730363607407,
0.004753924906253815,
-0.08400965481996536,
0.05697614327073097,
0.015299477614462376,
-0.04934857785701752,
0.0001318609865847975,
0.03338390588760376,
0.004935744684189558,
0.004709578584879637,
0.019068915396928787,
0.01011095941066742,
-0.06687424331903458,
-0.053818684071302414,
-0.011858204379677773,
0.052151262760162354,
-0.021853862330317497,
-0.07173459231853485,
0.008558838628232479,
-0.017268454656004906,
0.049774300307035446,
-0.025951461866497993,
0.00811094045639038,
0.03524645045399666,
-0.023805100470781326,
-0.01571633294224739,
-0.0018115468556061387,
0.026962557807564735,
-0.04409797489643097,
0.010075482539832592,
-0.029410474002361298,
-0.016816122457385063,
0.0057960632257163525,
-0.01121961697936058,
-0.0009395874803885818,
0.040372882038354874,
0.024887150153517723,
0.02467428892850876,
-0.014802799560129642,
0.04243055358529091,
0.021339446306228638,
-0.01228392869234085,
-0.0302264466881752,
0.006159702781587839,
-0.009534457698464394,
-0.007583219558000565,
-0.020186441019177437,
0.005011133383959532,
0.018066687509417534,
0.01650569774210453,
0.00352996657602489,
-0.009374810382723808,
0.05924667418003082,
-0.02657231129705906,
-0.012461313977837563,
0.027601145207881927,
-0.02249244973063469,
-0.03576086834073067,
0.018944744020700455,
-0.0017184196040034294,
0.018022341653704643,
0.03223089873790741,
-0.03430630639195442,
-0.008918043226003647,
-0.000005097227585793007,
-0.018838314339518547,
0.03806687518954277,
-0.027015773579478264,
-0.03668326884508133,
-0.02392926998436451,
-0.031219804659485817,
-0.004159684292972088,
0.02740602195262909,
-0.02522418275475502,
-0.011361525394022465,
0.020718596875667572,
0.004811575170606375,
0.01953011564910412,
-0.002527739852666855,
-0.07946859300136566,
0.08833785355091095,
0.0024213087745010853,
0.01449237484484911,
-0.033951535820961,
0.0028891623951494694,
0.00901560578495264,
0.03157457336783409,
0.07106053084135056,
-0.05094504356384277,
0.007334880065172911,
-0.005436858162283897,
4.936991899739951e-7,
-0.03205351531505585,
-0.08649304509162903,
-0.03553026542067528,
0.03599146753549576,
0.01864318922162056,
-0.013578840531408787,
0.005197387654334307,
-0.08365488797426224,
0.08493205904960632,
-0.004878094419836998,
-0.00577388983219862,
0.0022949217818677425,
-0.004598712548613548,
0.04395606368780136,
0.01674516685307026,
0.0026119977701455355,
0.09408513456583023,
0.05034193396568298,
-0.03515775501728058,
-0.022190894931554794,
0.02847033366560936,
0.03703803941607475,
0.020097749307751656,
-0.03955690935254097,
-0.028292948380112648,
0.009640888310968876,
-0.01850128173828125,
-0.016283966600894928,
0.016053365543484688,
0.02651909552514553,
-0.010181913152337074,
-0.016576651483774185,
-0.021268490701913834,
-0.010013397783041,
-0.04707804694771767,
-0.007707389071583748,
-0.01807555742561817,
-0.023397114127874374,
0.027015773579478264,
0.005849278531968594,
0.010199652053415775,
0.021410400047898293,
0.011849334463477135,
-0.01073180790990591,
0.03343712165951729,
-0.019281776621937752,
-0.029268566519021988,
-0.009077690541744232,
0.020204180851578712,
0.0275834072381258,
0.029605599120259285,
0.015255131758749485,
0.05094504356384277,
0.01835937425494194,
0.050519321113824844,
0.03450142964720726,
0.015175308100879192,
-0.03237280994653702,
0.007401399780064821,
0.03955690935254097,
-0.08883453160524368,
-0.005051045212894678,
-0.018066687509417534,
0.007924686186015606,
-0.03455464541912079,
-0.034288570284843445,
-0.05616017058491707,
-0.03565443679690361,
-0.01702011562883854,
0.04562348499894142,
0.0301909688860178,
0.07322463393211365,
0.011272832751274109
]
|
33,441 | bqplot.marks | HeatMap | HeatMap mark.
Attributes
----------
Data Attributes
color: numpy.ndarray or None (default: None)
color of the data points (2d array).
x: numpy.ndarray or None (default: None)
labels for the columns of the `color` array passed. The length of
this has to be the number of columns in `color`.
This is a scaled attribute.
y: numpy.ndarray or None (default: None)
labels for the rows of the `color` array passed. The length of this has
to be the number of rows in `color`.
This is a scaled attribute.
| class HeatMap(Mark):
"""HeatMap mark.
Attributes
----------
Data Attributes
color: numpy.ndarray or None (default: None)
color of the data points (2d array).
x: numpy.ndarray or None (default: None)
labels for the columns of the `color` array passed. The length of
this has to be the number of columns in `color`.
This is a scaled attribute.
y: numpy.ndarray or None (default: None)
labels for the rows of the `color` array passed. The length of this has
to be the number of rows in `color`.
This is a scaled attribute.
"""
# Scaled attributes
x = Array(None, allow_none=True).tag(sync=True, scaled=True,
rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
y = Array(None, allow_none=True).tag(sync=True, scaled=True,
rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
color = Array(None, allow_none=True).tag(sync=True, scaled=True,
rtype='Color',
atype='bqplot.ColorAxis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(2, 2))
# Other attributes
scales_metadata = Dict({
'x': {'orientation': 'horizontal', 'dimension': 'x'},
'y': {'orientation': 'vertical', 'dimension': 'y'},
'color': {'dimension': 'color'}
}).tag(sync=True)
null_color = Color('black', allow_none=True).tag(sync=True)
def __init__(self, **kwargs):
data = kwargs['color']
kwargs.setdefault('x', range(data.shape[1]))
kwargs.setdefault('y', range(data.shape[0]))
scales = kwargs.pop('scales', {})
# Adding default x and y data if they are not passed.
# Adding scales in case they are not passed too.
if scales.get('x', None) is None:
x_scale = LinearScale()
scales['x'] = x_scale
if scales.get('y', None) is None:
y_scale = LinearScale()
scales['y'] = y_scale
kwargs['scales'] = scales
super(HeatMap, self).__init__(**kwargs)
_view_name = Unicode('HeatMap').tag(sync=True)
_model_name = Unicode('HeatMapModel').tag(sync=True)
| (**kwargs) | [
0.030585572123527527,
-0.07867550104856491,
-0.010973162017762661,
0.026294181123375893,
-0.018436042591929436,
-0.021080518141388893,
-0.05518578365445137,
0.03918717801570892,
-0.013975254260003567,
-0.04020356014370918,
0.024110842496156693,
0.05330359563231468,
0.03574277088046074,
0.014059952460229397,
-0.012149530462920666,
-0.007284071762114763,
0.0025574243627488613,
0.003190310439094901,
0.059627749025821686,
-0.010568492114543915,
0.03510282561182976,
-0.04009062796831131,
0.02264273539185524,
0.02044057287275791,
0.02064761333167553,
0.024054376408457756,
-0.0029503314290195704,
0.01693970151245594,
0.045210182666778564,
-0.005345417186617851,
-0.083945631980896,
-0.02230394072830677,
-0.025729523971676826,
0.04626420885324478,
0.05906309187412262,
-0.10562845319509506,
0.03171488642692566,
0.0161962378770113,
-0.016647962853312492,
0.018511328846216202,
0.034500524401664734,
-0.03291948884725571,
0.05891251936554909,
-0.05081910640001297,
0.058121997863054276,
0.017485536634922028,
-0.013401186093688011,
0.0405423529446125,
-0.0650484561920166,
-0.06226281449198723,
0.02851516380906105,
-0.05469641461968422,
-0.003072673687711358,
0.08048240840435028,
-0.06790938228368759,
0.05740676820278168,
0.036834441125392914,
0.09147439152002335,
-0.010690834373235703,
0.018897177651524544,
-0.007806379348039627,
0.04596305638551712,
0.028383411467075348,
-0.05334123969078064,
-0.03425583988428116,
-0.002917393110692501,
-0.02096758596599102,
0.004121994134038687,
0.005975950509309769,
0.03491460904479027,
0.02921157516539097,
0.018153714016079903,
-0.00829104334115982,
0.03540397807955742,
-0.0021280499640852213,
-0.01817253604531288,
-0.05153433606028557,
0.01927361637353897,
-0.005415998864918947,
-0.016864413395524025,
0.012638899497687817,
0.03190310671925545,
0.026764728128910065,
-0.06553782522678375,
0.005627745296806097,
-0.043365634977817535,
0.03877309337258339,
0.06199930980801582,
-0.020835833624005318,
0.006178285460919142,
-0.04178459942340851,
0.04298919811844826,
0.00750993425026536,
0.024411993101239204,
0.02350854128599167,
-0.04615127667784691,
-0.010126177221536636,
-0.005481875501573086,
-0.020346464589238167,
0.026727084070444107,
0.027724646031856537,
-0.07965423911809921,
0.02719763293862343,
0.00650296313688159,
-0.0499909408390522,
-0.002971505979076028,
-0.02313210442662239,
0.01491634827107191,
-0.06305333226919174,
0.0029573896899819374,
0.0020433515310287476,
0.04121994227170944,
-0.021532243117690086,
-0.0016327990451827645,
-0.01808783784508705,
-0.016459744423627853,
-0.0153492521494627,
-0.0015351604670286179,
0.020929941907525063,
-0.03235483169555664,
-0.040354132652282715,
0.023207390680909157,
-0.009133322164416313,
-0.006884106434881687,
-0.012064832262694836,
0.020026491954922676,
0.018078425899147987,
0.04261276125907898,
-0.04242454096674919,
-0.05992890149354935,
-0.0165538527071476,
-0.013937610201537609,
-0.03922482207417488,
0.01634681224822998,
0.048861630260944366,
-0.03626978397369385,
0.06339212507009506,
-0.007058209273964167,
-0.03743674233555794,
0.07291600853204727,
0.053642388433218,
-0.015170443803071976,
0.013749390840530396,
0.002072760835289955,
-0.04257511720061302,
-0.032637160271406174,
0.020572327077388763,
-0.0332394577562809,
-0.014050541445612907,
-0.02045939490199089,
-0.03568630665540695,
-0.00009727094584377483,
-0.0016586791025474668,
0.006060648709535599,
0.01621505804359913,
-0.020741723477840424,
-0.017730221152305603,
-0.007989892736077309,
0.05255071818828583,
0.037869643419981,
-0.04743116348981857,
-0.006324155256152153,
0.02215336635708809,
-0.0025950681883841753,
-0.04844754561781883,
0.04246218502521515,
0.02012060210108757,
-0.07291600853204727,
-0.007185257039964199,
0.03201603516936302,
-0.00806517992168665,
-0.049878012388944626,
-0.010192054323852062,
0.03487696498632431,
0.036815617233514786,
0.04114465415477753,
-0.012949461117386818,
0.01888776756823063,
0.026934126392006874,
0.026632975786924362,
-0.00726054422557354,
-0.0035973337944597006,
-0.017777275294065475,
-0.00010021186608355492,
-0.034500524401664734,
-0.002362147206440568,
0.030830256640911102,
-0.021513421088457108,
0.023715581744909286,
0.03339003399014473,
0.04042942076921463,
-0.007359359413385391,
-0.010417916812002659,
0.026105962693691254,
0.01585744321346283,
0.0006228869315236807,
-0.0032632453367114067,
-0.04825932905077934,
-0.01098257303237915,
0.012300105765461922,
-0.026821194216609,
-0.008921576663851738,
0.030811434611678123,
-0.005246601998806,
0.02684001624584198,
-0.006921750493347645,
0.06184873357415199,
0.0034397004637867212,
-0.07679331302642822,
0.006747647654265165,
-0.03777553513646126,
-0.030642038211226463,
-0.051760200411081314,
0.0066158948466181755,
0.06056884303689003,
-0.06538724899291992,
0.01150017511099577,
0.02364029549062252,
-0.06023005023598671,
0.0032750091049820185,
0.07412060350179672,
-0.0051007322035729885,
0.028308123350143433,
0.0597030371427536,
-0.012733008712530136,
0.0002826224663294852,
0.07148554176092148,
0.004067881032824516,
0.025466017425060272,
-0.038998957723379135,
-0.0322607196867466,
-0.03035970963537693,
0.007467585150152445,
0.006884106434881687,
-0.03841548040509224,
-0.011791914701461792,
0.04810875281691551,
0.0015316313365474343,
-0.01929243840277195,
0.016647962853312492,
0.016309168189764023,
0.04953921586275101,
-0.015725689008831978,
-0.01700557768344879,
0.0037902581971138716,
-0.046188920736312866,
0.040165916085243225,
0.05032973736524582,
-0.06162286922335625,
-0.049727436155080795,
-0.039864763617515564,
-0.014389335177838802,
0.018483096733689308,
0.014652841724455357,
0.031790174543857574,
-0.0597030371427536,
0.017607878893613815,
-0.038151971995830536,
0.009194493293762207,
-0.019075985997915268,
-0.014681074768304825,
-0.04935099929571152,
0.05906309187412262,
0.112630195915699,
0.06267689913511276,
0.004161990713328123,
-0.003011502558365464,
0.04362914338707924,
-0.058611366897821426,
0.023376788944005966,
0.04329035058617592,
0.040354132652282715,
-0.006507668644189835,
-0.004251394420862198,
-0.010530848056077957,
0.01995120383799076,
0.03743674233555794,
-0.06851167976856232,
0.0021409899927675724,
0.010380272753536701,
-0.03201603516936302,
-0.10201464593410492,
0.02247333712875843,
0.025390731170773506,
0.04430673271417618,
-0.0696786418557167,
-0.006780586205422878,
0.010850819759070873,
0.020515860989689827,
-0.004580777604132891,
-0.031074941158294678,
0.01981945149600506,
-0.05537400394678116,
-0.030472641810774803,
0.0003446758782956749,
-0.058649010956287384,
0.015904497355222702,
0.04031648859381676,
-0.009495643898844719,
-0.0550728514790535,
0.06004182994365692,
-0.05029209330677986,
0.09930429607629776,
0.013909377157688141,
0.00019395370327401906,
-0.01040850579738617,
0.03476403281092644,
-0.0022962705697864294,
0.03602509945631027,
0.016798537224531174,
0.05010387301445007,
0.05010387301445007,
-0.021174626424908638,
0.002423318335786462,
-0.07336772978305817,
0.009067445993423462,
0.03224189952015877,
0.012629488483071327,
0.023941444233059883,
0.06222517043352127,
-0.03922482207417488,
-0.10306867212057114,
-0.028232837095856667,
-0.0335029661655426,
0.05315301939845085,
-0.018963055685162544,
0.0219651460647583,
-0.038660164922475815,
0.0228121317923069,
0.005999477580189705,
0.005787731613963842,
0.0033738238271325827,
0.012958872132003307,
0.014558732509613037,
-0.031413733959198,
-0.030943188816308975,
-0.038660164922475815,
0.021212270483374596,
-0.027442317456007004,
-0.06651656329631805,
-0.015640990808606148,
-0.00036673276918008924,
-0.04675357788801193,
0.049915652722120285,
-0.009843848645687103,
-0.016629140824079514,
0.009787383489310741,
-0.03515929356217384,
-0.013805856928229332,
0.07558871060609818,
0.02162635326385498,
0.004119641147553921,
0.009053329937160015,
0.0219651460647583,
0.0587242990732193,
-0.030453819781541824,
-0.003213837742805481,
-0.058799587190151215,
-0.021871037781238556,
0.03640153631567955,
0.058799587190151215,
-0.04649006947875023,
-0.02181457169353962,
0.013184734620153904,
-0.042386896908283234,
-0.01729731820523739,
-0.02262391336262226,
0.0175325907766819,
0.047355879098176956,
-0.005274835042655468,
0.028966890648007393,
-0.01621505804359913,
-0.03745556250214577,
0.01483165007084608,
0.018229002133011818,
-0.013975254260003567,
-0.03171488642692566,
0.031639598309993744,
-0.025748346000909805,
-0.04517253860831261,
0.009293308481574059,
-0.02217218652367592,
0.0024727259296923876,
0.009881492704153061,
-0.017410248517990112,
-0.02147577702999115,
0.018229002133011818,
-0.016440922394394875,
0.010549670085310936,
-0.00980620551854372,
0.041859883815050125,
-0.0560515895485878,
0.000764639291446656,
-0.02987034060060978,
-0.07622865587472916,
-0.008309864439070225,
0.035441622138023376,
0.05119554325938225,
0.007109969388693571,
-0.019151274114847183,
-0.00856395997107029,
-0.06459672749042511,
0.030623216181993484,
-0.002325679874047637,
0.01995120383799076,
-0.021739283576607704,
0.03483932092785835,
0.0011222552275285125,
0.02853398583829403,
0.0932060033082962,
0.023903802037239075,
0.001959829358384013,
-0.021362846717238426,
-0.0049078078009188175,
-0.005703032948076725,
-0.06071941927075386,
-0.013598816469311714,
-0.05379296466708183,
-0.017146741971373558,
0.01382467895746231,
-0.024619033560156822,
0.07125967741012573,
0.030585572123527527,
-0.003922011703252792,
0.022868597880005836,
-0.05221192538738251,
-0.036815617233514786,
0.0029809169936925173,
0.02951272390782833,
0.02702823467552662,
-0.014888115227222443,
-0.03807668387889862,
-0.04649006947875023,
-0.008060474880039692,
-0.0161962378770113,
0.0041266996413469315,
0.007284071762114763,
-0.04110701009631157,
0.021569887176156044,
-0.03205367922782898,
0.005001917481422424,
-0.014963403344154358,
0.059778325259685516,
-0.04377971962094307,
-0.031639598309993744,
-0.015226909890770912,
-0.0898180603981018,
0.028138726949691772,
0.03994005173444748,
-0.026783550158143044,
0.04615127667784691,
0.08944162726402283,
0.017080865800380707,
-0.012271872721612453,
0.023866157978773117,
-0.07698153704404831,
-0.024543745443224907,
-0.07242663949728012,
0.03937539458274841,
0.023075638338923454,
-0.020327642560005188,
-0.009067445993423462,
-0.06670477986335754,
-0.0509696789085865,
0.029738588258624077,
-0.009528581984341145,
0.046715933829545975,
-0.03730498626828194,
-0.04543604329228401,
-0.04961450397968292,
0.04396793618798256,
-0.020760545507073402,
0.031771350651979446,
-0.0030256188474595547,
-0.017146741971373558,
0.03367236256599426,
-0.011236668564379215,
0.03391704708337784,
-0.0368909053504467,
-0.0316772423684597,
0.04265040531754494,
-0.021532243117690086,
0.01846427470445633,
0.005877135321497917,
0.001977474894374609,
0.04344092309474945,
0.04344092309474945,
-0.03739909827709198,
0.011236668564379215,
0.01248832419514656,
-0.0898180603981018,
0.024393171072006226,
0.0066582439467310905,
0.043704431504011154,
-0.024223772808909416,
0.030265599489212036,
0.08763471990823746,
-0.01198954414576292,
-0.012140119448304176,
-0.0343499518930912,
0.008041652850806713,
-0.02330150082707405,
-0.014615198597311974,
-0.0306985042989254,
0.030152669176459312,
-0.05153433606028557,
0.005477169994264841,
0.03444406017661095,
-0.022078078240156174,
-0.006102998275309801,
-0.047205302864313126,
-0.04272569343447685,
0.0696786418557167,
-0.0010840232716873288,
0.019668875262141228,
-0.0161303598433733,
-0.06207459419965744,
0.01057790219783783,
0.0020574680529534817,
-0.019499478861689568,
0.00039673017454333603,
0.0815364345908165,
0.025240154936909676,
-0.023546185344457626,
-0.03770024701952934,
0.022266296669840813,
0.04844754561781883,
-0.009928547777235508,
0.006248867604881525,
0.0368909053504467,
-0.0044066752307116985,
-0.05401882529258728,
0.011283723637461662,
0.013090625405311584,
-0.0025950681883841753,
0.025258976966142654,
-0.021268736571073532,
0.005848902743309736,
0.03971419110894203,
-0.029399793595075607,
-0.00615946389734745,
-0.010831997729837894,
0.04340327903628349,
-0.05164726823568344,
0.012563612312078476,
-0.012460092082619667,
0.025936566293239594,
0.0323924757540226,
0.020327642560005188,
-0.009881492704153061,
0.0085545489564538,
0.029588012024760246,
0.03862252086400986,
0.017316140234470367,
-0.006220635026693344,
0.0100697111338377,
-0.02228511869907379,
-0.03440641611814499,
0.009340363554656506,
0.04091878980398178,
-0.014201116748154163,
0.06821053475141525,
0.04272569343447685,
0.0075475783087313175,
-0.03233600780367851,
0.03707912564277649,
-0.04193517193198204,
0.04426908865571022,
-0.03881073743104935,
-0.02785639837384224,
0.006855873856693506,
0.020082958042621613,
0.022755665704607964,
0.03626978397369385,
0.019518300890922546,
0.04257511720061302,
0.013043570332229137,
-0.007349948398768902,
-0.03892366960644722,
-0.06023005023598671,
-0.012987104244530201,
0.07325480133295059,
-0.0019657111261039972,
-0.04091878980398178,
0.029625656083226204,
0.01927361637353897,
-0.03005855903029442,
0.049878012388944626,
-0.003451464232057333,
-0.006032416131347418,
0.0049078078009188175,
-0.007241722662001848,
-0.010803765617311,
0.011584874242544174,
0.027950508520007133,
0.02064761333167553,
0.02484489604830742,
-0.06271453946828842,
0.004157285206019878,
-0.012262461706995964,
0.00620651850476861,
0.03440641611814499,
-0.03945068269968033,
-0.017156153917312622,
0.004728999920189381,
-0.03672150894999504,
0.03655211254954338,
-0.018012549728155136,
-0.0463394969701767,
-0.030905544757843018,
0.0089780418202281,
0.014492856338620186,
-0.0007628747844137251,
0.009490938857197762,
0.01700557768344879,
-0.08680655807256699,
-0.05706797167658806,
0.04475845769047737,
0.033634718507528305,
0.01551864854991436,
0.028214015066623688,
-0.003027971601113677,
0.016911469399929047,
0.013617637567222118,
-0.013758801855146885,
-0.03653328865766525,
0.017965495586395264,
-0.05966539308428764,
-0.006102998275309801,
-0.01836075447499752,
0.05725619196891785,
-0.006601778324693441,
0.014257581904530525,
-0.06188637763261795,
0.04701708257198334,
0.00554304663091898,
-0.012111886404454708,
0.02565423771739006,
0.014794006012380123,
0.04498431831598282,
-0.004569014068692923,
-0.03468874469399452,
0.030736148357391357,
0.039488326758146286,
0.0017116157105192542,
-0.014182294718921185,
0.0066158948466181755,
-0.017099687829613686,
0.007284071762114763,
0.015499827452003956,
-0.026425935328006744,
0.01607389561831951,
0.016337400302290916,
-0.0014939876273274422,
-0.0005761263309977949,
0.0791272297501564,
-0.05925131216645241,
-0.051609624177217484,
-0.029606834053993225,
-0.03476403281092644,
-0.048560477793216705,
0.012111886404454708,
-0.036458004266023636,
-0.0029197458643466234,
0.010173232294619083,
-0.04204810410737991,
-0.0003740850661415607,
0.04566190764307976,
0.015490416437387466,
0.05285187065601349,
-0.03540397807955742,
0.02211572229862213,
-0.030924366787075996,
-0.060644131153821945,
-0.01677030511200428,
-0.02667061984539032,
0.015565703622996807,
0.00028629860025830567,
0.0005099556292407215,
-0.0100697111338377,
0.0674576535820961,
0.011133148334920406,
-0.06414500623941422,
0.13506588339805603,
0.024939006194472313,
0.02753642573952675,
0.02518369071185589,
-0.05221192538738251,
-0.0276681799441576,
0.012761241756379604,
0.0737818107008934,
-0.010013245977461338,
0.03625096008181572,
-0.021024052053689957,
0.01905716396868229,
-0.03926246240735054,
-0.08703242242336273,
-0.060644131153821945,
0.03382293879985809,
-0.03344649821519852,
0.004371384158730507,
-0.008004008792340755,
-0.05951481685042381,
0.05304008722305298,
0.010248519480228424,
0.06391914188861847,
-0.0507061742246151,
0.02350854128599167,
0.030246779322624207,
0.001385761657729745,
0.027969330549240112,
0.09260370582342148,
0.050932034850120544,
-0.02684001624584198,
-0.0165538527071476,
-0.06896340847015381,
0.00045995996333658695,
0.005552457645535469,
-0.01030498556792736,
0.023583829402923584,
-0.0015092804096639156,
0.030754970386624336,
0.006837051827460527,
0.0037879054434597492,
-0.03216661140322685,
0.024769607931375504,
-0.02753642573952675,
-0.03487696498632431,
-0.033785294741392136,
-0.05085675045847893,
-0.008239282295107841,
0.013561172410845757,
-0.02249215915799141,
0.05048030987381935,
0.008145173080265522,
-0.014464623294770718,
-0.026727084070444107,
-0.020214710384607315,
0.029926806688308716,
0.01886894553899765,
-0.026275359094142914,
-0.053943537175655365,
-0.0533788837492466,
0.023696759715676308,
0.02164517529308796,
0.02533426508307457,
0.01525514293462038,
0.0633544847369194,
0.013542350381612778,
0.027931686490774155,
0.021946324035525322,
0.04133287072181702,
-0.10464971512556076,
0.03711676970124245,
0.10683305561542511,
-0.047694671899080276,
0.022925062105059624,
-0.019537122920155525,
0.010747299529612064,
-0.07287836074829102,
0.0021351082250475883,
-0.02064761333167553,
-0.027084700763225555,
-0.022435693070292473,
0.046188920736312866,
0.05706797167658806,
-0.01108609326183796,
0.04073057323694229
]
|
33,446 | bqplot.marks | __init__ | null | def __init__(self, **kwargs):
data = kwargs['color']
kwargs.setdefault('x', range(data.shape[1]))
kwargs.setdefault('y', range(data.shape[0]))
scales = kwargs.pop('scales', {})
# Adding default x and y data if they are not passed.
# Adding scales in case they are not passed too.
if scales.get('x', None) is None:
x_scale = LinearScale()
scales['x'] = x_scale
if scales.get('y', None) is None:
y_scale = LinearScale()
scales['y'] = y_scale
kwargs['scales'] = scales
super(HeatMap, self).__init__(**kwargs)
| (self, **kwargs) | [
0.02389090321958065,
-0.05271853879094124,
0.04201627895236015,
-0.004634943325072527,
-0.040899209678173065,
0.017638910561800003,
-0.01319765206426382,
0.02473771572113037,
-0.027134012430906296,
0.0073240213096141815,
0.006022273097187281,
0.08129393309354782,
0.0007612297777086496,
-0.004468283616006374,
0.036593079566955566,
0.00013907082029618323,
-0.02619711309671402,
-0.0018940657610073686,
0.0273862536996603,
-0.006499730981886387,
0.034070663154125214,
-0.045547664165496826,
0.00895458459854126,
0.07113219052553177,
0.029800567775964737,
0.05873630940914154,
-0.02338641881942749,
0.032593246549367905,
0.045223355293273926,
-0.0243773702532053,
-0.06197941675782204,
0.02771056443452835,
-0.0125129958614707,
0.0776904821395874,
0.05343922972679138,
-0.066952183842659,
0.0022667981684207916,
-0.0061709159053862095,
-0.045547664165496826,
0.04266490042209625,
0.03401660919189453,
-0.01021579373627901,
-0.033277902752161026,
-0.0056574237532913685,
0.07552840560674667,
0.02354857511818409,
-0.03372833505272865,
-0.004544856958091259,
-0.046844907104969025,
-0.06039389595389366,
-0.015071447938680649,
-0.0385209284722805,
-0.01607140712440014,
0.03050324134528637,
-0.024431420490145683,
0.09080705046653748,
0.019602792337536812,
0.11163502186536789,
-0.002662051934748888,
-0.009666266851127148,
-0.0497276708483696,
0.028305135667324066,
-0.023008055984973907,
-0.0802849680185318,
-0.030899621546268463,
-0.02787272073328495,
-0.028106944635510445,
0.008905037306249142,
0.01708037406206131,
0.0461602509021759,
0.032286953181028366,
0.06860977411270142,
-0.025422371923923492,
-0.0067339553497731686,
0.03205272927880287,
0.011585106141865253,
-0.04169197008013725,
0.053691472858190536,
-0.0051574441604316235,
0.01871994510293007,
-0.03248514235019684,
-0.0070402491837739944,
-0.011711226776242256,
0.004639447666704655,
-0.009013140574097633,
-0.04043075814843178,
-0.000003958873548981501,
0.03104376047849655,
-0.02189098671078682,
0.014287697151303291,
-0.052502330392599106,
0.00015033161616884172,
-0.015449810773134232,
0.003912000451236963,
0.02587280236184597,
-0.007959130220115185,
0.034431006759405136,
0.04576387256383896,
0.0334760919213295,
-0.0014695337740704417,
0.026431338861584663,
-0.0988067239522934,
0.0273862536996603,
-0.024485472589731216,
-0.040070414543151855,
-0.021674778312444687,
-0.01708037406206131,
0.019494688138365746,
-0.07632116228342056,
0.028593411669135094,
0.013233686797320843,
0.056285958737134933,
0.010359931737184525,
0.022593660280108452,
-0.07538426667451859,
0.0008287945529446006,
-0.023584609851241112,
-0.0318545363843441,
-0.0030066324397921562,
-0.01725153811275959,
-0.06280820816755295,
0.027314184233546257,
0.04107937961816788,
0.03273738548159599,
0.00572048407047987,
0.04183610528707504,
-0.036899372935295105,
-0.003238604636862874,
-0.027728581801056862,
-0.03180048614740372,
0.010098680853843689,
-0.014080498367547989,
-0.04248472675681114,
-0.00687809381633997,
0.022305382415652275,
-0.06360097229480743,
0.03686333820223808,
0.05819578841328621,
-0.0019154612673446536,
0.0471331849694252,
0.06385321170091629,
-0.0004341036546975374,
-0.011864373460412025,
-0.0077113923616707325,
-0.0020336995366960764,
0.0010787842329591513,
0.04475490376353264,
0.013467910699546337,
-0.016143476590514183,
-0.0058466047048568726,
-0.022683745250105858,
0.05203388258814812,
0.00878792442381382,
-0.009864456951618195,
0.025638578459620476,
-0.06774494051933289,
-0.001971765188500285,
-0.02951229177415371,
0.06633959710597992,
0.043205417692661285,
-0.005504276603460312,
0.016017355024814606,
0.008864497765898705,
-0.020341500639915466,
-0.041187483817338943,
0.016783088445663452,
-0.00030967185739427805,
-0.10817570239305496,
0.023260299116373062,
0.020161326974630356,
-0.004357927944511175,
-0.06846563518047333,
0.012503987178206444,
0.05196181312203407,
-0.003628228325396776,
0.003767861984670162,
-0.016620934009552002,
-0.003432290395721793,
0.021854951977729797,
0.03437695652246475,
-0.013666100800037384,
0.013053514063358307,
-0.0076978798024356365,
0.007184387184679508,
-0.0040291124023497105,
-0.021692795678973198,
0.010188767686486244,
0.0013907082611694932,
-0.017981238663196564,
0.013783213682472706,
0.05297078192234039,
-0.003979565110057592,
-0.04641249403357506,
-0.004121451172977686,
0.03001677617430687,
0.01924244686961174,
0.029620395973324776,
-0.07711392641067505,
-0.010053638368844986,
0.02405305951833725,
-0.034268852323293686,
-0.057799410074949265,
0.010477043688297272,
-0.0069321454502642155,
0.006211454514414072,
-0.002948076231405139,
0.047673702239990234,
0.019116325303912163,
0.0014762902865186334,
-0.010395966470241547,
0.0016125459223985672,
-0.029404189437627792,
-0.008864497765898705,
0.02071986347436905,
0.016323648393154144,
-0.018810031935572624,
-0.0494033619761467,
-0.0361606664955616,
-0.017188478261232376,
0.020629776641726494,
0.07091598212718964,
0.0022780587896704674,
0.04133162274956703,
0.0554211288690567,
-0.004747551400214434,
0.017674943432211876,
0.05243026092648506,
-0.011332863941788673,
0.009085210040211678,
0.035061612725257874,
-0.02753039263188839,
-0.056826476007699966,
0.024989956989884377,
0.032449107617139816,
-0.02540435455739498,
-0.02538633719086647,
0.050015948712825775,
0.013954377733170986,
-0.014332740567624569,
0.01061217300593853,
0.00008994559902930632,
0.03844885900616646,
-0.006270010955631733,
-0.03471928462386131,
0.025602543726563454,
-0.023584609851241112,
-0.0011148187331855297,
0.07970841228961945,
-0.03333195298910141,
-0.040899209678173065,
-0.03133203834295273,
0.017116408795118332,
-0.004788090009242296,
0.03711558133363724,
-0.034106697887182236,
-0.06071820855140686,
-0.018665894865989685,
-0.01418860163539648,
-0.008080746978521347,
-0.05527698993682861,
-0.032773420214653015,
-0.018954170867800713,
0.00854469183832407,
0.1032029390335083,
0.037908341735601425,
-0.026647545397281647,
-0.026431338861584663,
0.023458488285541534,
-0.039205584675073624,
0.018296539783477783,
0.08114979416131973,
0.04525939002633095,
0.043565765023231506,
0.02140451967716217,
0.014179592952132225,
0.023638661950826645,
0.02172883041203022,
-0.1295081526041031,
0.0547725073993206,
0.0036777756176888943,
0.007774453144520521,
-0.042232487350702286,
-0.009269886650145054,
-0.0015934024704620242,
0.03545799106359482,
-0.04673680290579796,
0.0053150951862335205,
-0.0076978798024356365,
-0.006670895032584667,
-0.0012690916191786528,
-0.03098970837891102,
0.014711102470755577,
-0.05686251074075699,
0.02985461987555027,
-0.005382660310715437,
-0.04882680997252464,
0.04450266435742378,
0.05693458020687103,
-0.029115911573171616,
-0.04612421616911888,
0.05041232705116272,
-0.10738294571638107,
0.07253754138946533,
0.003812905168160796,
-0.007238439284265041,
-0.01592726819217205,
0.010873423889279366,
0.0007291365182027221,
0.018026281148195267,
0.015566923655569553,
0.07855530828237534,
0.06197941675782204,
-0.0420883484184742,
-0.009864456951618195,
-0.07289788126945496,
-0.00288276351056993,
0.06558287143707275,
-0.03034108690917492,
0.0026530432514846325,
0.05286267772316933,
-0.026449356228113174,
-0.09340153634548187,
-0.03455713018774986,
-0.05279060825705528,
0.048682671040296555,
0.061619073152542114,
0.05106094852089882,
-0.03169238194823265,
0.06298838555812836,
0.0833839401602745,
-0.010332905687391758,
-0.0010489430278539658,
0.012125624343752861,
-0.00987346563488245,
-0.021440554410219193,
-0.050664570182561874,
-0.03468324989080429,
0.05610578507184982,
-0.023620644584298134,
-0.05174560472369194,
-0.03891730681061745,
-0.006175420247018337,
-0.020017189905047417,
0.02007124200463295,
0.010332905687391758,
-0.02504400908946991,
-0.003806148888543248,
-0.07041150331497192,
-0.018503738567233086,
0.03565618023276329,
-0.012918384745717049,
-0.016990287229418755,
-0.02075589820742607,
-0.0033106738701462746,
0.043565765023231506,
0.03035910427570343,
0.028323153033852577,
-0.03931368887424469,
0.030305052176117897,
0.011567088775336742,
0.08295152336359024,
-0.01499937940388918,
-0.03333195298910141,
-0.017683953046798706,
0.0034885944332927465,
0.0031169881112873554,
0.0016080415807664394,
-0.001931226346641779,
0.048322323709726334,
0.018503738567233086,
0.04846646264195442,
-0.009152774699032307,
-0.042412661015987396,
0.025134094059467316,
0.01757584884762764,
-0.04742145910859108,
-0.022179262712597847,
0.008751889690756798,
-0.013612049631774426,
-0.04990784451365471,
-0.03430488705635071,
-0.0328274704515934,
0.005382660310715437,
-0.008409561589360237,
-0.02935013733804226,
-0.011089631356298923,
-0.025332285091280937,
0.019458653405308723,
-0.009801396168768406,
-0.006567295640707016,
-0.010161741636693478,
-0.017873134464025497,
0.040538862347602844,
-0.019134342670440674,
-0.018449686467647552,
-0.012476961128413677,
0.08605049550533295,
0.0378723070025444,
0.006450183689594269,
0.0017848360585048795,
-0.021350467577576637,
-0.07920392602682114,
0.021134261041879654,
-0.023116160184144974,
0.032935574650764465,
-0.022197280079126358,
0.006846563424915075,
-0.014215627685189247,
0.05120508745312691,
0.06547477096319199,
0.06864580512046814,
0.016494812443852425,
0.017017314210534096,
-0.015251620672643185,
-0.03798041120171547,
-0.04446662962436676,
-0.03219686448574066,
-0.040358688682317734,
-0.013648083433508873,
-0.00929691269993782,
-0.01871994510293007,
0.015521880239248276,
-0.012377866543829441,
-0.003957043401896954,
0.031205914914608,
-0.021314432844519615,
-0.016720028594136238,
-0.04075507074594498,
0.031944625079631805,
0.018665894865989685,
-0.07480771839618683,
-0.01843166910111904,
-0.01260308176279068,
-0.012071572244167328,
0.03169238194823265,
0.0004405786166898906,
-0.004011095035821199,
0.0001615924120415002,
-0.014530929736793041,
-0.021999089047312737,
0.01773800514638424,
-0.05621388927102089,
0.045367490500211716,
-0.009657258167862892,
-0.06298838555812836,
-0.021098226308822632,
-0.05603371560573578,
0.025314267724752426,
0.02106219157576561,
-0.021206330507993698,
0.029764533042907715,
0.03801644593477249,
-0.004488552920520306,
-0.008085250854492188,
0.04788991063833237,
-0.05668233707547188,
-0.11055397987365723,
-0.0021395510993897915,
0.07610496133565903,
-0.005743005778640509,
-0.023926937952637672,
-0.051169052720069885,
-0.056141819804906845,
-0.0700511559844017,
-0.005409685894846916,
0.023008055984973907,
0.040394723415374756,
-0.029620395973324776,
-0.010206785053014755,
-0.03945782780647278,
-0.016837140545248985,
0.01807132363319397,
0.0035313854459673166,
-0.03133203834295273,
-0.037259720265865326,
0.04082714021205902,
0.0024751226883381605,
0.02008925937116146,
0.006549278274178505,
-0.01990908570587635,
0.009184304624795914,
0.006364601664245129,
0.062411829829216,
0.00035302594187669456,
-0.01908029057085514,
0.025350302457809448,
0.0030494234524667263,
-0.037259720265865326,
-0.0318545363843441,
0.05239422619342804,
-0.05470043793320656,
0.003191309282556176,
-0.011927434243261814,
0.050015948712825775,
-0.024449437856674194,
0.038052480667829514,
0.06774494051933289,
-0.01790015958249569,
0.0073735686019063,
0.028395220637321472,
0.002677817130461335,
0.029404189437627792,
-0.003639488946646452,
-0.005076366476714611,
0.01822447031736374,
-0.043385591357946396,
-0.022503573447465897,
0.05304285138845444,
-0.02207115851342678,
0.006535765714943409,
-0.009251869283616543,
-0.01871994510293007,
0.046196285635232925,
0.002799433656036854,
0.03562014922499657,
-0.019458653405308723,
-0.07949220389127731,
-0.00659882603213191,
-0.03715161606669426,
-0.020611759275197983,
0.012458943761885166,
0.07942013442516327,
0.04367386922240257,
0.007229430601000786,
-0.022449521347880363,
0.0420883484184742,
0.07181684672832489,
-0.0019458654569461942,
0.004105685744434595,
0.04374593868851662,
-0.013476919382810593,
-0.04594404622912407,
-0.033908504992723465,
0.04064696654677391,
-0.008580725640058517,
0.01875597983598709,
-0.01077432930469513,
-0.01693623512983322,
-0.010702259838581085,
-0.04623232036828995,
-0.010071654804050922,
0.004382701590657234,
0.1160312369465828,
-0.08237496763467789,
-0.027800651267170906,
-0.03751195967197418,
-0.007287986576557159,
0.053979746997356415,
0.006400635931640863,
-0.029224015772342682,
0.016323648393154144,
0.008454605005681515,
-0.01161213219165802,
0.023620644584298134,
-0.038412824273109436,
0.0164137352257967,
-0.04169197008013725,
-0.037728168070316315,
-0.02888168767094612,
0.01161213219165802,
-0.021314432844519615,
0.04064696654677391,
0.046376459300518036,
0.05661027133464813,
-0.0757446140050888,
-0.01760287582874298,
-0.028827635571360588,
0.04028661921620369,
-0.054664403200149536,
-0.0381966158747673,
-0.015368733555078506,
0.006441175006330013,
-0.022143227979540825,
0.022107193246483803,
-0.008864497765898705,
0.022827884182333946,
0.05012405291199684,
-0.034917473793029785,
-0.027242116630077362,
-0.050160087645053864,
-0.023008055984973907,
0.030467208474874496,
-0.01987305097281933,
-0.012215710245072842,
-0.0033804906997829676,
0.03554807975888252,
-0.021440554410219193,
0.0385209284722805,
-0.03733178973197937,
-0.031584277749061584,
0.08633876591920853,
0.0013681866694241762,
-0.008112276904284954,
0.009567171335220337,
-0.04886284098029137,
-0.0004766131460200995,
0.030449191108345985,
-0.03497152402997017,
0.02785470336675644,
0.016197528690099716,
-0.015864208340644836,
0.03826868534088135,
-0.07415909320116043,
0.007233934942632914,
-0.015296664088964462,
-0.07444737106561661,
0.056502167135477066,
0.03743989020586014,
-0.048178184777498245,
-0.03284548595547676,
0.033079713582992554,
0.005788048729300499,
0.010098680853843689,
0.01026984490454197,
0.0025089052505791187,
-0.04500714689493179,
-0.044394560158252716,
0.026503408327698708,
0.05059250071644783,
0.033908504992723465,
-0.027728581801056862,
-0.0040403734892606735,
-0.00870234239846468,
0.06936649978160858,
-0.007472663652151823,
-0.009134757332503796,
0.026845736429095268,
-0.015332698822021484,
-0.03084556944668293,
-0.014350757002830505,
0.0170623566955328,
-0.0005686701624654233,
-0.009161783382296562,
-0.039241619408130646,
0.00846811756491661,
0.010224802419543266,
-0.009783378802239895,
0.008332988247275352,
0.033223848789930344,
0.048682671040296555,
0.025278232991695404,
-0.014368774369359016,
0.05653820186853409,
0.017837099730968475,
0.019963137805461884,
-0.022107193246483803,
0.011990495026111603,
0.013368816114962101,
-0.0008620138978585601,
-0.014080498367547989,
-0.017629900947213173,
-0.00029784804792143404,
0.012666142545640469,
0.03576428443193436,
-0.0005889395833946764,
0.054628368467092514,
-0.03630480542778969,
-0.04904301464557648,
0.009477085433900356,
-0.017116408795118332,
-0.05145733058452606,
0.05653820186853409,
0.032593246549367905,
0.029314102604985237,
0.014449852518737316,
-0.047493528574705124,
0.01987305097281933,
-0.010242819786071777,
-0.015846190974116325,
0.06576304137706757,
-0.04161990061402321,
-0.013639074750244617,
-0.03700747713446617,
-0.014729119837284088,
0.010630190372467041,
0.008639282546937466,
-0.009323938749730587,
-0.026935821399092674,
0.012350840494036674,
0.01126980409026146,
0.04644852876663208,
-0.00567994499579072,
-0.0560697503387928,
0.09419430047273636,
0.019116325303912163,
0.048682671040296555,
-0.010558121837675571,
-0.04133162274956703,
0.011495019309222698,
0.06071820855140686,
0.06904219090938568,
-0.012846315279603004,
-0.007139344234019518,
-0.03297160938382149,
-0.01118872594088316,
-0.03960196301341057,
-0.11293226480484009,
-0.046196285635232925,
0.03870110213756561,
-0.010684242472052574,
-0.0242152139544487,
0.005824083462357521,
-0.07999669015407562,
0.07761841267347336,
-0.0003442988090682775,
-0.021458571776747704,
-0.014882266521453857,
0.0019458654569461942,
0.06615942716598511,
0.007625810336321592,
0.01839563436806202,
0.0541238859295845,
0.05711475387215614,
-0.029097894206643105,
-0.03271936625242233,
-0.0005407996941357851,
-0.0023422453086823225,
-0.003968304023146629,
-0.01594528555870056,
0.006891606841236353,
0.023332368582487106,
-0.009287904016673565,
-0.02353055775165558,
0.02569263055920601,
0.01577412150800228,
-0.02706194296479225,
-0.008850985206663609,
-0.04659266769886017,
-0.0030426669400185347,
-0.03646695986390114,
-0.006139385513961315,
-0.008134798146784306,
0.006959171500056982,
0.0560697503387928,
0.0060132648795843124,
0.015269638039171696,
-0.010621181689202785,
0.015693044289946556,
0.00820686761289835,
0.04897094517946243,
-0.0268997885286808,
-0.058808378875255585,
-0.0235665924847126,
0.02470168098807335,
0.0032048223074525595,
0.011576097458600998,
0.005238521844148636,
0.05080870911478996,
-0.001797222881577909,
0.04792594537138939,
0.011125666089355946,
0.030070828273892403,
-0.06666390597820282,
0.0342148020863533,
0.016665976494550705,
-0.08244703710079193,
-0.011711226776242256,
-0.03653902933001518,
0.025908837094902992,
-0.028737548738718033,
-0.01319765206426382,
-0.025007974356412888,
-0.024161161854863167,
-0.04612421616911888,
0.05340319499373436,
0.05455629900097847,
0.04792594537138939,
0.020593741908669472
]
|
33,506 | bqplot.marks | Hist | Histogram mark.
In the case of the Hist mark, scales for 'sample' and 'count' MUST be
provided.
Attributes
----------
icon: string (class-level attribute)
font-awesome icon for that mark
name: string (class-level attribute)
user-friendly name of the mark
bins: nonnegative int (default: 10)
number of bins in the histogram
normalized: bool (default: False)
Boolean attribute to return normalized values which
sum to 1 or direct counts for the `count` attribute. The scale of
`count` attribute is determined by the value of this flag.
colors: list of colors (default: ['steelblue'])
List of colors of the Histogram. If the list is shorter than the number
of bins, the colors are reused.
stroke: Color or None (default: None)
Stroke color of the histogram
opacities: list of floats (default: [])
Opacity for the bins of the histogram. Defaults to 1 when the list
is too short, or the element of the list is set to None.
midpoints: list (default: [])
midpoints of the bins of the histogram. It is a read-only attribute.
Data Attributes
sample: numpy.ndarray (default: [])
sample of which the histogram must be computed.
count: numpy.ndarray (read-only)
number of sample points per bin. It is a read-only attribute.
Notes
-----
The fields which can be passed to the default tooltip are:
midpoint: mid-point of the bin related to the rectangle hovered on
count: number of elements in the bin hovered on
bin_start: start point of the bin
bin-end: end point of the bin
index: index of the bin
| class Hist(Mark):
"""Histogram mark.
In the case of the Hist mark, scales for 'sample' and 'count' MUST be
provided.
Attributes
----------
icon: string (class-level attribute)
font-awesome icon for that mark
name: string (class-level attribute)
user-friendly name of the mark
bins: nonnegative int (default: 10)
number of bins in the histogram
normalized: bool (default: False)
Boolean attribute to return normalized values which
sum to 1 or direct counts for the `count` attribute. The scale of
`count` attribute is determined by the value of this flag.
colors: list of colors (default: ['steelblue'])
List of colors of the Histogram. If the list is shorter than the number
of bins, the colors are reused.
stroke: Color or None (default: None)
Stroke color of the histogram
opacities: list of floats (default: [])
Opacity for the bins of the histogram. Defaults to 1 when the list
is too short, or the element of the list is set to None.
midpoints: list (default: [])
midpoints of the bins of the histogram. It is a read-only attribute.
Data Attributes
sample: numpy.ndarray (default: [])
sample of which the histogram must be computed.
count: numpy.ndarray (read-only)
number of sample points per bin. It is a read-only attribute.
Notes
-----
The fields which can be passed to the default tooltip are:
midpoint: mid-point of the bin related to the rectangle hovered on
count: number of elements in the bin hovered on
bin_start: start point of the bin
bin-end: end point of the bin
index: index of the bin
"""
# Mark decoration
icon = 'fa-signal'
name = 'Histogram'
# Scaled attributes
sample = Array([]).tag(sync=True, display_name='Sample',
scaled=True, rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze, array_dimension_bounds(1, 1))
count = Array([], read_only=True).tag(sync=True,
display_name='Count',
scaled=True,
rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze)
normalized = Bool().tag(sync=True)
# Other attributes
scales_metadata = Dict({
'sample': {'orientation': 'horizontal', 'dimension': 'x'},
'count': {'orientation': 'vertical', 'dimension': 'y'}
}).tag(sync=True)
bins = Int(10).tag(sync=True, display_name='Number of bins')
midpoints = List(read_only=True).tag(sync=True, display_name='Mid points')
# midpoints is a read-only attribute that is set when the mark is drawn
colors = List(trait=Color(default_value=None, allow_none=True),
default_value=['steelblue'])\
.tag(sync=True, display_name='Colors')
stroke = Color(None, allow_none=True).tag(sync=True)
opacities = List(trait=Float(1.0, min=0, max=1, allow_none=True))\
.tag(sync=True, display_name='Opacities')
_view_name = Unicode('Hist').tag(sync=True)
_model_name = Unicode('HistModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.002518214751034975,
-0.05207299813628197,
-0.03194615989923477,
0.015982521697878838,
0.00844911765307188,
-0.004611613694578409,
-0.04493609070777893,
0.04308577999472618,
0.0211652759462595,
-0.03515588119626045,
0.0007215971709229052,
0.07624030858278275,
0.011073536239564419,
-0.011224581860005856,
-0.06211753562092781,
-0.0005209895898588002,
0.042859211564064026,
0.022430283948779106,
0.02716934122145176,
0.03392863646149635,
-0.007509802468121052,
-0.006178712472319603,
-0.02059885486960411,
0.008788970299065113,
0.024393877014517784,
0.019371608272194862,
0.0077882930636405945,
-0.050373733043670654,
0.019390489906072617,
0.021316321566700935,
-0.042028460651636124,
-0.0686502605676651,
-0.01780450902879238,
0.002766024088487029,
0.057246312499046326,
-0.09636714309453964,
-0.009317630901932716,
0.053017035126686096,
-0.034098561853170395,
0.04761715233325958,
0.0509779192507267,
-0.06072036549448967,
0.07831718772649765,
-0.02681060880422592,
0.043387871235609055,
0.024563804268836975,
0.02762247994542122,
0.03744044899940491,
-0.04557803273200989,
-0.07556059956550598,
0.03017137572169304,
-0.031965043395757675,
0.017124803736805916,
0.0439920537173748,
-0.0735592469573021,
0.03840336576104164,
0.06778174638748169,
0.08284855633974075,
-0.0030822758562862873,
0.06812160462141037,
0.016945436596870422,
0.07242640107870102,
0.044822804629802704,
-0.07065162062644958,
-0.025262389332056046,
-0.013140974566340446,
0.01011062040925026,
-0.00046257738722488284,
-0.023449841886758804,
0.032418180257081985,
0.026999415829777718,
-0.010714802891016006,
0.015217852778732777,
0.06502516567707062,
-0.01718144677579403,
-0.04402981698513031,
-0.02733926847577095,
0.03621320053935051,
0.02071213908493519,
-0.005777497310191393,
0.062381867319345474,
0.02894412912428379,
0.05365897715091705,
-0.03789358586072922,
0.010035097599029541,
-0.03715723752975464,
0.02339320071041584,
0.028849724680185318,
0.020542211830615997,
0.017644023522734642,
-0.05883229151368141,
0.0509779192507267,
0.05294151231646538,
0.014745834283530712,
-0.009449795819818974,
-0.07884584367275238,
-0.027735764160752296,
-0.022789016366004944,
0.016964318230748177,
-0.0015682789962738752,
-0.0069150603376328945,
-0.03079443797469139,
0.0160297229886055,
0.024450520053505898,
-0.0481080487370491,
0.013688514940440655,
-0.01923944428563118,
-0.0023376678582280874,
-0.03802575170993805,
0.015378338284790516,
0.006202313117682934,
0.04961850494146347,
0.016209090128540993,
-0.026942772790789604,
-0.007457880303263664,
-0.002040296792984009,
-0.020995350554585457,
-0.0051591540686786175,
0.026565158739686012,
-0.028660917654633522,
-0.04157532379031181,
0.03238041698932648,
-0.0062919966876506805,
0.0009286949061788619,
-0.02531903237104416,
0.030190255492925644,
0.011337866075336933,
0.039687253534793854,
-0.05010940507054329,
-0.00809510424733162,
0.0009098142036236823,
-0.014641990885138512,
-0.035873349756002426,
0.015019604936242104,
0.07042504847049713,
-0.04723953828215599,
0.07733538746833801,
0.021788340061903,
-0.0472772978246212,
0.060078419744968414,
0.051770906895399094,
-0.002065077656880021,
0.027433671057224274,
-0.00720299081876874,
-0.06812160462141037,
0.004115995019674301,
0.019598176702857018,
-0.022883420810103416,
0.016388457268476486,
-0.04531370475888252,
-0.033532142639160156,
-0.02416730858385563,
0.0077552516013383865,
0.024035144597291946,
0.032493703067302704,
0.0001960348745342344,
-0.03139862045645714,
-0.015925878658890724,
0.007018904201686382,
0.033532142639160156,
-0.022430283948779106,
0.023751933127641678,
0.04263264313340187,
-0.03745932877063751,
-0.06793279200792313,
0.08088496327400208,
0.013631872832775116,
-0.014708072878420353,
-0.02901965193450451,
0.032663628458976746,
-0.022090431302785873,
-0.031757354736328125,
0.00044576177606359124,
0.05052477866411209,
-0.015453861095011234,
0.06834816932678223,
-0.005074190907180309,
0.05739735811948776,
0.022807897999882698,
0.0337020680308342,
0.014528706669807434,
-0.04588012397289276,
-0.01997579075396061,
-0.03192728012800217,
-0.042406074702739716,
-0.04814581200480461,
0.03477826714515686,
-0.021146396175026894,
0.02475261129438877,
0.017398575320839882,
0.002017875900492072,
-0.012215819209814072,
0.013650753535330296,
0.010667601600289345,
0.009959574788808823,
-0.01040327176451683,
-0.031795114278793335,
-0.025092463940382004,
0.012876644730567932,
-0.014037808403372765,
0.027395909652113914,
0.038214556872844696,
0.013301460072398186,
-0.017209766432642937,
0.034513939172029495,
-0.00970468483865261,
0.039158593863248825,
0.011337866075336933,
-0.08080943673849106,
0.00010037752508651465,
-0.034344010055065155,
-0.04538922756910324,
-0.04089561849832535,
0.02639523334801197,
0.014434303157031536,
-0.026338590309023857,
0.024356115609407425,
0.01599196158349514,
-0.016784951090812683,
-0.0026362191420048475,
0.08164019137620926,
-0.021184157580137253,
0.008609604090452194,
0.06087141111493111,
-0.008203668519854546,
0.011422829702496529,
0.11940161138772964,
0.0027046618051826954,
0.04542698711156845,
-0.04048024117946625,
-0.006348638795316219,
-0.013329781591892242,
0.016171328723430634,
0.0014974763616919518,
-0.046144455671310425,
0.012678396888077259,
0.04161308705806732,
0.030039209872484207,
-0.01965481974184513,
0.03666633740067482,
0.023279916495084763,
0.052224043756723404,
-0.0031365579925477505,
0.012083654291927814,
-0.01883350871503353,
-0.029774880036711693,
0.04897656291723251,
0.02754695527255535,
-0.0439920537173748,
-0.06423217803239822,
-0.028226662427186966,
-0.005668933037668467,
0.002810865640640259,
-0.035042598843574524,
0.0748431384563446,
-0.003502371720969677,
-0.013782918453216553,
-0.06959430128335953,
0.01775730773806572,
-0.011913727968931198,
-0.01673774980008602,
-0.07801509648561478,
0.036118797957897186,
0.07899688929319382,
0.04723953828215599,
0.01475527510046959,
0.025791050866246223,
0.027603598311543465,
-0.032248254865407944,
0.02733926847577095,
-0.009378992952406406,
0.011252903379499912,
-0.037176117300987244,
-0.043765485286712646,
-0.018880710005760193,
0.026244187727570534,
0.04765491187572479,
-0.01993802934885025,
-0.015331136994063854,
0.014000046998262405,
-0.02039116621017456,
-0.05520719662308693,
0.043765485286712646,
0.005352681502699852,
0.06623353064060211,
-0.032739151269197464,
-0.008873933926224709,
0.003695898922160268,
-0.01566154882311821,
-0.018673023208975792,
0.010941371321678162,
0.03034130111336708,
-0.0587945319712162,
-0.044256385415792465,
0.022505806758999825,
-0.022581329569220543,
0.021467367187142372,
0.007221871521323919,
-0.0143871009349823,
-0.018550297245383263,
0.02918957732617855,
-0.0559246651828289,
0.08541633188724518,
0.0019553336314857006,
-0.03264474868774414,
0.004543170798569918,
0.07748643308877945,
-0.029076293110847473,
0.042859211564064026,
-0.0050175487995147705,
0.03443841636180878,
0.09425250440835953,
0.018399251624941826,
0.026319710537791252,
-0.06321261823177338,
0.02010795660316944,
0.011791003867983818,
-0.030265778303146362,
0.0020851383451372385,
0.052639421075582504,
-0.052148520946502686,
-0.03857329115271568,
-0.02499805949628353,
-0.04395429417490959,
0.04780595749616623,
-0.0032002804800868034,
-0.036194320768117905,
0.0014479145174846053,
-0.015057366341352463,
-0.0019966349937021732,
-0.02039116621017456,
0.0011411028681322932,
0.03440065309405327,
0.0219960268586874,
-0.04066905006766319,
-0.005989905446767807,
-0.000024117156499414705,
0.026659563183784485,
-0.030473466962575912,
-0.06797055900096893,
-0.010205023922026157,
-0.037515971809625626,
-0.04297249764204025,
0.06849921494722366,
-0.009407313540577888,
-0.00504586985334754,
0.03513700142502785,
-0.01087528932839632,
0.014198293909430504,
0.08383035659790039,
0.020749900490045547,
0.026829488575458527,
0.0126406354829669,
0.0185030959546566,
0.06838592886924744,
-0.06963206082582474,
-0.0025677764788269997,
-0.05936095118522644,
-0.04591788724064827,
0.0030515948310494423,
0.021240798756480217,
-0.04319906607270241,
-0.0024474121164530516,
0.02314775064587593,
-0.043727725744247437,
-0.013386423699557781,
-0.00875592976808548,
0.03942292183637619,
0.0023624489549547434,
-0.005484846420586109,
0.027188222855329514,
-0.033437736332416534,
-0.04697520658373833,
0.019390489906072617,
0.03460834175348282,
-0.0026102582924067974,
-0.04588012397289276,
-0.01796499639749527,
-0.025394555181264877,
-0.04278368875384331,
0.005819979123771191,
0.017172005027532578,
-0.013188175857067108,
0.024563804268836975,
-0.021637294441461563,
-0.004786259960383177,
0.004370884504169226,
-0.03789358586072922,
0.02639523334801197,
-0.0203534048050642,
0.033362213522195816,
-0.056793175637722015,
-0.01755906082689762,
-0.05195971578359604,
-0.08987218141555786,
-0.041462041437625885,
0.02716934122145176,
0.024393877014517784,
0.02597985789179802,
-0.03158742934465408,
-0.004743778612464666,
-0.02639523334801197,
0.028585394844412804,
0.006858417764306068,
0.018219884485006332,
-0.03062451258301735,
0.031436383724212646,
-0.008359434083104134,
-0.008293352089822292,
0.030114732682704926,
-0.003266362939029932,
-0.0083263935521245,
-0.029548311606049538,
0.0023058068472892046,
0.053130317479372025,
-0.06574263423681259,
0.019352728500962257,
-0.07692001014947891,
-0.03949844464659691,
-0.018673023208975792,
-0.013037130236625671,
0.07586269080638885,
0.050298210233449936,
0.022128192707896233,
0.04822133481502533,
-0.018569178879261017,
-0.03662857785820961,
-0.0018326089484617114,
0.015283934772014618,
0.031153172254562378,
0.016822712495923042,
-0.026546278968453407,
-0.04259488359093666,
0.004179717041552067,
-0.02754695527255535,
-0.010601518675684929,
-0.028849724680185318,
-0.041084423661231995,
0.009969014674425125,
-0.01792723499238491,
-0.01632237434387207,
0.0016792031237855554,
0.07012295722961426,
-0.009445074945688248,
0.014566468074917793,
0.0038752658292651176,
-0.060531556606292725,
0.010865848511457443,
0.04319906607270241,
-0.0780906155705452,
0.012395186349749565,
0.04814581200480461,
0.023072227835655212,
-0.010535436682403088,
0.004675335716456175,
-0.0883617252111435,
-0.030926603823900223,
-0.07129356265068054,
0.018201004713773727,
0.04697520658373833,
-0.022147072479128838,
0.03995158150792122,
-0.08322617411613464,
-0.05830363184213638,
-0.01874854601919651,
-0.03555237874388695,
0.06755518168210983,
-0.03813903406262398,
-0.03725164011120796,
-0.0101767024025321,
0.06068260222673416,
-0.014623110182583332,
0.020410047844052315,
0.005102511961013079,
-0.02681060880422592,
0.011092416942119598,
0.00970468483865261,
-0.016917116940021515,
-0.07718434184789658,
-0.025092463940382004,
0.057321835309267044,
-0.024884775280952454,
0.005598130635917187,
0.04414309933781624,
-0.002023776061832905,
0.03540133312344551,
0.006905619986355305,
-0.01796499639749527,
0.04217950627207756,
0.011791003867983818,
-0.04297249764204025,
0.001338170375674963,
-0.005952144041657448,
0.04346339404582977,
-0.0002814405888784677,
0.029586073011159897,
0.10452361404895782,
-0.017993316054344177,
-0.022958943620324135,
-0.04689968377351761,
-0.001847949461080134,
-0.07016071677207947,
-0.003938988316804171,
-0.028585394844412804,
0.026905011385679245,
-0.04161308705806732,
-0.020070195198059082,
0.007368197198957205,
-0.031058767810463905,
-0.037629254162311554,
-0.04871223121881485,
-0.04297249764204025,
0.07597597688436508,
0.01915447972714901,
0.00894001591950655,
-0.049391936510801315,
-0.032871317118406296,
0.005664213094860315,
0.013858441263437271,
0.0028297463431954384,
0.008888094685971737,
0.012763360515236855,
-0.033645424991846085,
-0.06528949737548828,
-0.010705363005399704,
-0.03538244962692261,
0.001158213592134416,
-0.03272027149796486,
0.025337914004921913,
0.013735716231167316,
0.013169295154511929,
-0.022581329569220543,
0.01903175562620163,
0.01607692427933216,
0.002622058615088463,
0.05513167381286621,
-0.01342418510466814,
-0.0037832222878932953,
0.08043182641267776,
0.009100502356886864,
0.003344245720654726,
-0.01023334451019764,
0.0060795885510742664,
-0.016624465584754944,
0.061928730458021164,
0.03238041698932648,
0.012536791153252125,
0.014519265852868557,
0.07665568590164185,
-0.008623763918876648,
0.024393877014517784,
0.009997336193919182,
0.03211608901619911,
-0.039725013077259064,
0.010157821699976921,
0.027716882526874542,
-0.008005420677363873,
-0.020296763628721237,
0.02951055020093918,
0.04874999448657036,
-0.03485378995537758,
0.058643486350774765,
0.03275803104043007,
-0.00482166139408946,
-0.022751254960894585,
0.039687253534793854,
-0.015510503202676773,
0.007443720009177923,
-0.02552672103047371,
-0.03802575170993805,
0.019097838550806046,
0.019919149577617645,
0.009454515762627125,
0.019126160070300102,
0.018059398978948593,
0.05849244073033333,
0.010412711650133133,
-0.015406659804284573,
-0.04504937306046486,
-0.01883350871503353,
-0.01389620266854763,
0.052110761404037476,
-0.029812641441822052,
-0.06589367985725403,
0.03285243734717369,
0.0702740028500557,
-0.04467175900936127,
0.053998831659555435,
-0.0005351501167751849,
0.010186143219470978,
-0.027905689552426338,
0.0073540364392101765,
-0.0016567823477089405,
-0.03691178932785988,
0.06072036549448967,
0.02384633757174015,
-0.007986539974808693,
-0.11373739689588547,
-0.03613767772912979,
-0.020051313564181328,
0.035420212894678116,
0.043387871235609055,
-0.0493164137005806,
0.003301764139905572,
0.026905011385679245,
-0.025224627926945686,
0.0439920537173748,
-0.050675828009843826,
-0.04901432245969772,
-0.033079005777835846,
-0.02203378826379776,
0.030756676569581032,
-0.013556350022554398,
0.012083654291927814,
0.021863862872123718,
-0.06343918293714523,
-0.029114054515957832,
-0.016105245798826218,
0.03400415927171707,
0.03373982757329941,
0.024809252470731735,
-0.0201457180082798,
0.012527351267635822,
0.004295361693948507,
-0.021429605782032013,
-0.08269751071929932,
0.005069470498710871,
-0.0361754409968853,
-0.0000806117823231034,
-0.048447903245687485,
0.045615795999765396,
-0.023525364696979523,
0.04312354326248169,
-0.0690656378865242,
0.06596919894218445,
0.003160158870741725,
-0.00585774052888155,
0.0021583011839538813,
0.020315643399953842,
0.03893202543258667,
-0.003214441007003188,
-0.06355246901512146,
0.006202313117682934,
0.025432316586375237,
-0.004658815450966358,
-0.012612313963472843,
-0.004262320231646299,
0.009426194243133068,
0.013358102180063725,
-0.0031153170857578516,
0.04119770973920822,
-0.008392475545406342,
-0.017256969586014748,
-0.003766701789572835,
-0.02835882641375065,
0.05237508937716484,
0.008704007603228092,
-0.02059885486960411,
-0.013594111427664757,
-0.031021006405353546,
-0.03983829915523529,
0.0072124311700463295,
-0.017087042331695557,
0.03487267345190048,
-0.008434956893324852,
-0.01611468568444252,
-0.019541535526514053,
0.050298210233449936,
0.02412954717874527,
0.02314775064587593,
0.005296039395034313,
0.040631286799907684,
-0.049845073372125626,
-0.054489728063344955,
-0.032248254865407944,
-0.017275849357247353,
0.027698002755641937,
0.03662857785820961,
0.0022350039798766375,
-0.03957396745681763,
0.02594209648668766,
-0.01358467061072588,
-0.037138357758522034,
0.05698198452591896,
0.049429699778556824,
0.06056931987404823,
0.013433624990284443,
-0.04633326455950737,
-0.047466106712818146,
0.007745811250060797,
0.006216473877429962,
-0.0402914360165596,
0.0513932928442955,
-0.03647753223776817,
0.010639280080795288,
-0.007793013006448746,
-0.07627806812524796,
-0.06226858124136925,
0.026055380702018738,
-0.06638457626104355,
0.05105344206094742,
-0.021486248821020126,
-0.017445776611566544,
0.047012969851493835,
-0.008803131058812141,
0.04674863815307617,
-0.06359022855758667,
-0.018795747309923172,
0.028094496577978134,
0.01424549613147974,
-0.004106554668396711,
0.09493221342563629,
0.01903175562620163,
-0.027358148247003555,
0.02080654352903366,
-0.03753485158085823,
-0.00041626064921729267,
0.01180044375360012,
-0.023544246330857277,
0.00042658604797907174,
0.00018954463303089142,
0.024922536686062813,
0.023733053356409073,
0.016888795420527458,
-0.04625774174928665,
0.01044103316962719,
0.02310998924076557,
0.01857861876487732,
-0.0464465469121933,
-0.06483636051416397,
-0.004894824232906103,
0.004927865229547024,
-0.024695968255400658,
-0.00670265220105648,
0.004722537472844124,
-0.01042215246707201,
0.023204393684864044,
-0.015283934772014618,
0.05709526687860489,
-0.030888842418789864,
-0.0018267086707055569,
-0.037553731352090836,
-0.055396005511283875,
0.040140390396118164,
0.041990701109170914,
-0.008505759760737419,
-0.01091305073350668,
0.03309788554906845,
0.022354761138558388,
-0.022883420810103416,
0.046673115342855453,
0.04021591320633888,
-0.07333267480134964,
0.009676364250481129,
0.08277302980422974,
-0.03613767772912979,
0.04410533979535103,
0.01825764589011669,
0.016832152381539345,
-0.04406757652759552,
0.018569178879261017,
-0.013697954826056957,
0.010318308137357235,
-0.037138357758522034,
0.052563898265361786,
0.04410533979535103,
-0.035288047045469284,
0.012923846021294594
]
|
33,571 | bqplot.marks | Image | Image mark, based on the ipywidgets image
If no scales are passed, uses the parent Figure scales.
Attributes
----------
image: Instance of ipywidgets.Image
Image to be displayed
Data Attributes
x: tuple (default: (0, 1))
abscissas of the left and right-hand side of the image
in the format (x0, x1)
y: tuple (default: (0, 1))
ordinates of the bottom and top side of the image
in the format (y0, y1)
| class Image(Mark):
"""Image mark, based on the ipywidgets image
If no scales are passed, uses the parent Figure scales.
Attributes
----------
image: Instance of ipywidgets.Image
Image to be displayed
Data Attributes
x: tuple (default: (0, 1))
abscissas of the left and right-hand side of the image
in the format (x0, x1)
y: tuple (default: (0, 1))
ordinates of the bottom and top side of the image
in the format (y0, y1)
"""
_view_name = Unicode('Image').tag(sync=True)
_model_name = Unicode('ImageModel').tag(sync=True)
image = Instance(widgets.Image).tag(sync=True, **widget_serialization)
pixelated = Bool(True).tag(sync=True)
x = Array(default_value=(0, 1)).tag(sync=True, scaled=True,
rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze, shape(2))
y = Array(default_value=(0, 1)).tag(sync=True, scaled=True,
rtype='Number',
atype='bqplot.Axis',
**array_serialization)\
.valid(array_squeeze, shape(2))
scales_metadata = Dict({
'x': {'orientation': 'horizontal', 'dimension': 'x'},
'y': {'orientation': 'vertical', 'dimension': 'y'},
}).tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.043363675475120544,
-0.12098284065723419,
-0.025292454287409782,
0.07489759474992752,
-0.021935850381851196,
-0.007697505876421928,
-0.04702872410416603,
-0.003748962190002203,
0.006014668848365545,
-0.006014668848365545,
0.05682637169957161,
0.05178239941596985,
0.039553478360176086,
0.008799741975963116,
-0.03418291360139847,
-0.018597392365336418,
0.005102943163365126,
0.016084477305412292,
0.033928900957107544,
-0.015249861404299736,
-0.0019697360694408417,
-0.0013811965472996235,
0.040823545306921005,
-0.017971431836485863,
0.0730106383562088,
0.05236300081014633,
0.044778890907764435,
-0.01218356005847454,
0.010015375912189484,
-0.004227504599839449,
-0.06557168066501617,
-0.0389728769659996,
0.032985422760248184,
0.001319961273111403,
0.08571130037307739,
-0.05606433376669884,
0.00019320308638270944,
-0.004776354879140854,
-0.012564579956233501,
0.010024447925388813,
0.045214343816041946,
-0.02991912141442299,
0.10400024801492691,
-0.06056399643421173,
-0.0075296759605407715,
0.041803307831287384,
-0.02424011379480362,
-0.0072303032502532005,
-0.050621192902326584,
-0.0488068163394928,
0.03632388263940811,
-0.042891938239336014,
0.005529322195798159,
0.047282736748456955,
-0.02756042778491974,
0.08904975652694702,
0.031679071485996246,
0.0787440836429596,
0.004785426426678896,
0.002521987771615386,
-0.014143089763820171,
0.02042991667985916,
0.03164278343319893,
-0.05620948597788811,
-0.018216373398900032,
0.00032460386864840984,
-0.03316686302423477,
-0.009244265034794807,
-0.05047604441642761,
0.04419828951358795,
-0.00016301068535540253,
-0.008196460083127022,
-0.007116904482245445,
0.028703486546874046,
-0.03977120295166969,
-0.04626668244600296,
-0.024276399984955788,
0.06568054854869843,
0.004175341222435236,
-0.02658066339790821,
0.04753674939274788,
0.04027923196554184,
0.02955624647438526,
-0.06840211898088455,
0.04731902480125427,
-0.06753121316432953,
0.011666461825370789,
0.05682637169957161,
0.004975936375558376,
-0.004708315245807171,
-0.011530383490025997,
0.013190540485084057,
0.04623039439320564,
0.0009015199611894786,
0.01464204490184784,
0.002669406123459339,
0.0009689921862445772,
-0.045395780354738235,
-0.021137524396181107,
0.002106948522850871,
-0.018152868375182152,
-0.038029398769140244,
0.03258626163005829,
-0.023078911006450653,
-0.024675564840435982,
0.01603911630809307,
-0.00459945248439908,
0.024602988734841347,
-0.06353957951068878,
0.0028689878527075052,
0.060999445617198944,
0.014578540809452534,
-0.028903068974614143,
0.010804631747305393,
-0.014850698411464691,
-0.002159111900255084,
-0.06074543297290802,
-0.007434420753270388,
0.06281382590532303,
-0.03795682266354561,
-0.10879021137952805,
0.041476719081401825,
-0.003946275915950537,
-0.016311272978782654,
0.01171182096004486,
0.01581231877207756,
0.04448859021067619,
0.03505381569266319,
-0.10980626195669174,
-0.06451934576034546,
-0.040351804345846176,
-0.0226616021245718,
-0.07678455114364624,
0.02549203485250473,
0.012818592600524426,
-0.052000124007463455,
0.06883756816387177,
0.016111692413687706,
-0.0658256933093071,
0.11459622532129288,
0.031207332387566566,
0.013598776422441006,
-0.007057937327772379,
0.04140414670109749,
-0.033439017832279205,
0.03149763122200966,
0.036287594586610794,
0.000698536226991564,
0.03882772475481033,
-0.0676763653755188,
-0.049024540930986404,
-0.0235869362950325,
0.035961005836725235,
0.0294292401522398,
0.05631834641098976,
-0.027124976739287376,
-0.0023178700357675552,
0.019250569865107536,
0.03759394958615303,
0.04561350494623184,
-0.021808844059705734,
-0.020502490922808647,
0.009970016777515411,
-0.028522050008177757,
-0.0447063185274601,
0.06633372604846954,
-0.034709084779024124,
-0.01812565326690674,
-0.003231863956898451,
0.041767019778490067,
-0.003944008145481348,
-0.08970293402671814,
-0.014968632720410824,
-0.001923242467455566,
-0.02126453071832657,
0.09006580710411072,
-0.010196814313530922,
0.04993173107504845,
-0.008364290930330753,
0.020048895850777626,
-0.017871640622615814,
0.008073990233242512,
0.004173073451966047,
0.010559690184891224,
-0.07475244253873825,
0.001672631362453103,
0.03401961922645569,
-0.004994080401957035,
0.025909341871738434,
-0.011303585954010487,
0.055955469608306885,
0.06506365537643433,
-0.021609263494610786,
-0.045105479657649994,
-0.022915616631507874,
-0.019305000081658363,
-0.0016556214541196823,
-0.04699243605136871,
0.029138939455151558,
0.03126176446676254,
0.025582754984498024,
-0.01432452816516161,
0.026671381667256355,
0.011784396134316921,
0.02280675247311592,
-0.003968955483287573,
-0.008105741813778877,
0.00177128822542727,
-0.049822866916656494,
0.02046620287001133,
-0.037993110716342926,
0.010242173448204994,
-0.06426533311605453,
0.03467279672622681,
0.03581585735082626,
-0.005697152577340603,
-0.00035635550739243627,
0.036124300211668015,
-0.038029398769140244,
0.018615536391735077,
0.05504827946424484,
0.005334276240319014,
0.0030254782177507877,
0.038174550980329514,
0.02015775814652443,
-0.0031933083664625883,
0.1095159575343132,
0.014932345598936081,
0.06121717393398285,
-0.04503290355205536,
-0.07370010763406754,
-0.028249893337488174,
-0.0013982063392177224,
0.03821083903312683,
0.00593755766749382,
0.002094474621117115,
0.02598191797733307,
-0.011040500365197659,
-0.04056953266263008,
0.017009809613227844,
-0.007175871636718512,
0.017853496596217155,
-0.03654160723090172,
-0.01761762797832489,
-0.036450888961553574,
-0.07642167806625366,
0.001977673964574933,
0.059874530881643295,
-0.03273141011595726,
-0.06263238936662674,
0.05047604441642761,
-0.00958899687975645,
0.010396395809948444,
-0.028667200356721878,
0.05541115626692772,
-0.013444554060697556,
-0.05573774501681328,
-0.09964573383331299,
0.02676210179924965,
-0.015077495947480202,
0.030300142243504524,
-0.05345162749290466,
-0.0032568115275353193,
0.051383234560489655,
0.015204502269625664,
0.009815794415771961,
-0.0013233632780611515,
0.03254997357726097,
-0.046665847301483154,
0.052000124007463455,
0.09209791570901871,
0.02516544610261917,
-0.021990282461047173,
0.01935943216085434,
0.022117288783192635,
0.022607171908020973,
0.0324048213660717,
-0.007570499554276466,
-0.02186327613890171,
-0.0365053191781044,
0.017826281487941742,
-0.05504827946424484,
-0.015150071121752262,
0.0046493480913341045,
0.05697152391076088,
-0.08353403955698013,
0.03919060155749321,
0.036124300211668015,
-0.015603666193783283,
0.004281936213374138,
-0.02897564508020878,
0.07780060172080994,
-0.033892612904310226,
-0.03278584033250809,
-0.0588584803044796,
-0.022552739828824997,
-0.021173812448978424,
0.018869549036026,
-0.01478719525039196,
-0.03900916501879692,
0.019704163074493408,
-0.016492711380124092,
0.058749616146087646,
0.04641183465719223,
0.03467279672622681,
0.02124638669192791,
0.016637861728668213,
0.0024380728136748075,
-0.002105814404785633,
0.004619864281266928,
0.04731902480125427,
0.10146011412143707,
-0.04721016064286232,
0.0083053233101964,
-0.03699520230293274,
-0.02676210179924965,
0.045250631868839264,
0.003538040444254875,
0.0004439560289029032,
0.04630297049880028,
0.002821360481902957,
-0.0664425864815712,
-0.055955469608306885,
-0.05366935208439827,
0.060201119631528854,
-0.017735561355948448,
0.0011192455422133207,
0.02438526414334774,
-0.005347884260118008,
0.07446214556694031,
0.018923981115221977,
0.024784427136182785,
0.009035611525177956,
0.023060766980051994,
-0.033439017832279205,
-0.03195122629404068,
-0.004073282703757286,
-0.024766283109784126,
-0.02140968106687069,
-0.021518543362617493,
-0.022153576835989952,
-0.04064210504293442,
-0.05094778165221214,
0.022570883855223656,
-0.01788071170449257,
0.00235869362950325,
0.03294913470745087,
-0.06713204830884933,
0.03086259961128235,
0.04401685297489166,
0.006785780191421509,
0.0141521617770195,
0.004009779077023268,
-0.041004981845617294,
0.021482255309820175,
-0.013217756524682045,
-0.04456116631627083,
-0.035634417086839676,
-0.031388770788908005,
-0.021464113146066666,
0.04198474809527397,
-0.03679561987519264,
-0.01354434434324503,
0.03759394958615303,
-0.01464204490184784,
-0.006250538397580385,
0.0229700468480587,
-0.028576480224728584,
0.02924780175089836,
0.02594562992453575,
0.012383141554892063,
-0.021808844059705734,
-0.04158558323979378,
-0.01935943216085434,
0.03792053833603859,
0.029465526342391968,
-0.02469370886683464,
-0.0006928662769496441,
0.008591088466346264,
-0.03496309742331505,
-0.015703456476330757,
0.003830609144642949,
0.027505997568368912,
0.01478719525039196,
0.004182145465165377,
0.00837789848446846,
-0.007588643115013838,
0.003039086004719138,
0.0037036025896668434,
-0.043980564922094345,
0.004662956111133099,
-0.0553748682141304,
0.010251245461404324,
-0.015776032581925392,
-0.03347530588507652,
-0.10363736748695374,
0.023967957124114037,
0.06814810633659363,
0.01935943216085434,
-0.039118025451898575,
-0.0029120794497430325,
-0.037739098072052,
0.05570145696401596,
0.03086259961128235,
0.027614859864115715,
-0.021010518074035645,
-0.016329417005181313,
0.03303985670208931,
-0.012410357594490051,
0.028068454936146736,
-0.008677271194756031,
-0.06778522580862045,
-0.027814442291855812,
-0.010468970984220505,
0.03919060155749321,
-0.014850698411464691,
0.0013539808569476008,
-0.04452487826347351,
-0.05428624153137207,
-0.005112014710903168,
-0.03592471778392792,
0.06691432744264603,
0.013607848435640335,
0.01242850162088871,
-0.02908450737595558,
-0.0648096427321434,
0.00845047365874052,
0.009416630491614342,
0.010015375912189484,
0.025854911655187607,
0.002646726556122303,
-0.010976997204124928,
-0.014696476049721241,
0.017463404685258865,
-0.014823482371866703,
-0.04956885427236557,
-0.016184266656637192,
-0.03380189463496208,
0.021772556006908417,
-0.03810197487473488,
0.010677624493837357,
-0.010831846855580807,
0.04042438045144081,
-0.009507349692285061,
0.004021119326353073,
-0.0016522195655852556,
-0.06085429713129997,
0.08476781845092773,
-0.030735593289136887,
-0.03460022062063217,
0.051238082349300385,
0.07373639196157455,
-0.003091249382123351,
-0.00510747916996479,
0.037702810019254684,
-0.09500092267990112,
0.02360508032143116,
-0.09122700989246368,
0.037521373480558395,
0.010296604596078396,
-0.0199944656342268,
-0.012827664613723755,
-0.07380896806716919,
-0.07925210893154144,
0.029374808073043823,
-0.01369856670498848,
0.02817731723189354,
-0.013045390136539936,
-0.010986069217324257,
-0.015694385394454002,
0.032005660235881805,
-0.015358724631369114,
0.007271126843988895,
-0.001067649107426405,
0.017218463122844696,
0.024421552196145058,
0.0179442148655653,
0.039263177663087845,
-0.015948398038744926,
-0.03338458761572838,
-0.008854173123836517,
-0.045395780354738235,
0.004334099590778351,
0.02091979794204235,
-0.03695891425013542,
-0.001772422227077186,
0.01870625466108322,
-0.026344792917370796,
0.02551017887890339,
-0.002125092316418886,
-0.02516544610261917,
0.06607971340417862,
-0.02848576195538044,
0.04895196482539177,
-0.02645365707576275,
0.01218356005847454,
0.04089611768722534,
-0.02315148524940014,
-0.026816532015800476,
-0.06350328773260117,
0.00875891838222742,
-0.037049632519483566,
-0.008958499878644943,
0.003526700660586357,
0.0652088075876236,
-0.029864691197872162,
-0.0007728123455308378,
0.02188142016530037,
0.007878944277763367,
-0.04750046133995056,
-0.021935850381851196,
-0.018216373398900032,
0.04797219857573509,
0.009285088628530502,
0.006858355365693569,
-0.04071468114852905,
-0.04154929518699646,
0.016329417005181313,
0.010877206921577454,
-0.00853212084621191,
0.004082354251295328,
-0.023224061354994774,
0.0017792261205613613,
-0.024276399984955788,
0.00990651361644268,
0.0016329417703673244,
-0.027034258469939232,
-0.005910342093557119,
-0.00898117944598198,
0.03503567352890968,
0.005538394208997488,
-0.03164278343319893,
-0.0007195149664767087,
-0.015050279907882214,
-0.030953317880630493,
0.05464911833405495,
-0.03162463754415512,
0.04027923196554184,
0.03919060155749321,
-0.012156344018876553,
-0.024965865537524223,
0.006994433701038361,
-0.011348945088684559,
0.03679561987519264,
0.07961498200893402,
0.03839227557182312,
-0.010441754944622517,
-0.00913540180772543,
0.07729257643222809,
-0.013635063543915749,
0.002950635040178895,
0.04009779170155525,
0.03347530588507652,
-0.013326618820428848,
0.004853465594351292,
0.040533244609832764,
0.026090780273079872,
-0.03962605446577072,
-0.03695891425013542,
0.010722984559834003,
0.0013165592681616545,
0.05479426681995392,
0.05838673934340477,
-0.007652146741747856,
-0.01843409799039364,
-0.014306384138762951,
0.008191924542188644,
0.0022679746616631746,
0.009725075215101242,
-0.03730364888906479,
0.015295221470296383,
0.001754278433509171,
0.0389728769659996,
-0.015086567960679531,
0.00813295692205429,
0.0453232042491436,
0.012727874331176281,
-0.0025492035783827305,
-0.05370564013719559,
-0.04848022758960724,
0.0035153606440871954,
0.013508057221770287,
0.028921213001012802,
-0.038464851677417755,
-0.016002830117940903,
-0.00041900831274688244,
-0.01874254271388054,
0.06451934576034546,
-0.031878650188446045,
0.00951642170548439,
0.005610969383269548,
0.006695061456412077,
-0.0027261055074632168,
0.044162001460790634,
0.037085920572280884,
0.0182526595890522,
-0.01667414978146553,
-0.06335814297199249,
0.006613414268940687,
-0.05080263316631317,
0.05588289722800255,
0.017916999757289886,
-0.05769727751612663,
0.03541669249534607,
-0.005756119731813669,
-0.005384171847254038,
0.034836091101169586,
-0.020048895850777626,
-0.051238082349300385,
-0.01751783676445484,
0.03262254595756531,
0.053923364728689194,
0.008495832793414593,
-0.02563718520104885,
0.0055565377697348595,
-0.031098468229174614,
-0.04314595088362694,
0.06216064840555191,
0.01812565326690674,
0.020339196547865868,
0.019450150430202484,
0.018053079023957253,
0.005887662060558796,
-0.014306384138762951,
-0.012256135232746601,
-0.0529073141515255,
0.01818915642797947,
0.00016882237105164677,
0.02251645177602768,
-0.02991912141442299,
0.04441601783037186,
-0.00238137342967093,
0.04499661922454834,
-0.07562334835529327,
0.025709761306643486,
0.02910265140235424,
-0.011067716404795647,
0.009031075052917004,
-0.01808936521410942,
0.03278584033250809,
0.06226951256394386,
-0.034364353865385056,
-0.007207623682916164,
0.029864691197872162,
0.028286179527640343,
-0.028213605284690857,
-0.008191924542188644,
-0.020974230021238327,
-0.02407681941986084,
0.007670290302485228,
-0.008237283676862717,
0.01872439868748188,
0.021173812448978424,
-0.01849760115146637,
0.03839227557182312,
0.05203641206026077,
-0.006613414268940687,
-0.0276874341070652,
-0.012319638393819332,
-0.03619687631726265,
-0.028721630573272705,
-0.0033293869346380234,
-0.022879328578710556,
0.07518789917230606,
0.004685635678470135,
-0.03229596093297005,
0.017100529745221138,
0.024004243314266205,
0.026090780273079872,
0.02251645177602768,
0.005139230750501156,
0.009276016615331173,
-0.06328556686639786,
-0.020720217376947403,
0.00238137342967093,
-0.04419828951358795,
0.03919060155749321,
-0.02877606265246868,
-0.019631588831543922,
0.019286856055259705,
-0.028884924948215485,
-0.034872379153966904,
-0.0430733747780323,
0.07990528643131256,
0.021427825093269348,
0.0016851051477715373,
0.06876499205827713,
-0.02803216688334942,
-0.03037271648645401,
0.010813702829182148,
-0.013117965310811996,
-0.007389061618596315,
0.051854971796274185,
-0.07152284681797028,
0.03663232550024986,
-0.048189926892519,
-0.03679561987519264,
-0.029828403145074844,
-0.004236576613038778,
-0.04721016064286232,
0.017871640622615814,
-0.034237343817949295,
-0.0453232042491436,
0.010087951086461544,
0.003944008145481348,
0.051564671099185944,
-0.031044038012623787,
-0.000756936555262655,
0.04452487826347351,
-0.037085920572280884,
-0.03699520230293274,
0.04753674939274788,
0.012691586278378963,
-0.042710497975349426,
0.0194864384829998,
0.012237991206347942,
-0.02186327613890171,
0.010568762198090553,
0.005175518337637186,
-0.010931638069450855,
0.018796974793076515,
0.03861000016331673,
0.013807429932057858,
-0.04535949230194092,
-0.025891199707984924,
0.02924780175089836,
-0.016810229048132896,
0.006014668848365545,
-0.032314103096723557,
-0.027016114443540573,
-0.010323820635676384,
0.030318286269903183,
-0.04031551629304886,
-0.027578571811318398,
-0.0037466941867023706,
-0.01226520724594593,
0.007937910966575146,
-0.029465526342391968,
0.021173812448978424,
-0.016456423327326775,
0.009625284932553768,
-0.0713777020573616,
-0.031860508024692535,
-0.0023564256262034178,
0.04568608105182648,
0.010532474145293236,
-0.008527584373950958,
0.007330093998461962,
0.0026603343430906534,
0.05029460787773132,
0.05036718025803566,
0.026181500405073166,
-0.06923673301935196,
0.027324559167027473,
0.08157451450824738,
-0.06651516258716583,
0.05417737737298012,
0.040533244609832764,
0.02015775814652443,
-0.04071468114852905,
-0.023405497893691063,
-0.019413862377405167,
0.03632388263940811,
-0.049641430377960205,
0.03347530588507652,
0.0232784915715456,
-0.04136785864830017,
0.02233501523733139
]
|
33,685 | bqplot.interacts | Interaction | The base interaction class.
An interaction is a mouse interaction layer for a figure that requires the
capture of all mouse events on the plot area. A consequence is that one can
allow only one interaction at any time on a figure.
An interaction can be associated with features such as selection or
manual change of specific mark. Although, they differ from the so called
'mark interactions' in that they do not rely on knowing whether a specific
element of the mark are hovered by the mouse.
Attributes
----------
types: dict (class-level attribute) representing interaction types
A registry of existing interaction types.
| class Interaction(Widget):
"""The base interaction class.
An interaction is a mouse interaction layer for a figure that requires the
capture of all mouse events on the plot area. A consequence is that one can
allow only one interaction at any time on a figure.
An interaction can be associated with features such as selection or
manual change of specific mark. Although, they differ from the so called
'mark interactions' in that they do not rely on knowing whether a specific
element of the mark are hovered by the mouse.
Attributes
----------
types: dict (class-level attribute) representing interaction types
A registry of existing interaction types.
"""
types = {}
_view_name = Unicode('Interaction').tag(sync=True)
_model_name = Unicode('BaseModel').tag(sync=True)
_view_module = Unicode('bqplot').tag(sync=True)
_model_module = Unicode('bqplot').tag(sync=True)
_view_module_version = Unicode(__frontend_version__).tag(sync=True)
_model_module_version = Unicode(__frontend_version__).tag(sync=True)
# We cannot display an interaction outside of a figure
_ipython_display_ = None
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.013020887970924377,
-0.10594106465578079,
-0.007392990402877331,
0.06077596917748451,
-0.0042907726019620895,
-0.0027718169149011374,
-0.004532475024461746,
0.046052075922489166,
-0.024374250322580338,
-0.021411731839179993,
0.0027474251110106707,
0.05634106323122978,
-0.014723892323672771,
0.03212646767497063,
-0.09905809164047241,
-0.024835480377078056,
-0.007588126230984926,
-0.0358695313334465,
-0.007654649671167135,
-0.04647782817482948,
0.0017961374251171947,
-0.013384549878537655,
0.0008404148975387216,
-0.02825922891497612,
0.02440972998738289,
0.03349241986870766,
-0.03927553817629814,
0.006608011666685343,
-0.009224606677889824,
-0.014014306478202343,
-0.07212933152914047,
-0.06542374938726425,
-0.02009899914264679,
-0.025722462683916092,
0.01695021614432335,
-0.06443033367395401,
0.014697282575070858,
0.05843433737754822,
0.06024378165602684,
-0.00579198868945241,
-0.01263948529958725,
-0.032711874693632126,
0.06659456342458725,
-0.05506380647420883,
-0.0036166668869554996,
0.035532478243112564,
0.006639055907726288,
0.053147926926612854,
-0.03496480733156204,
-0.09785179048776627,
0.03817567974328995,
-0.031842634081840515,
-0.006780973169952631,
0.04296538233757019,
-0.03210872784256935,
0.05424778535962105,
0.008590415120124817,
0.06425293534994125,
-0.02460486628115177,
0.020648928359150887,
-0.06570758670568466,
0.06684292107820511,
0.04537796974182129,
-0.024125894531607628,
-0.0017872676253318787,
-0.001658655353821814,
0.0022019315510988235,
0.006807582452893257,
-0.04151073098182678,
0.009464091621339321,
-0.010803434066474438,
0.00025694744545035064,
0.0018316167406737804,
0.01823633909225464,
0.03436166048049927,
-0.06783634424209595,
-0.009535050950944424,
0.026946496218442917,
0.0014834764879196882,
0.014608584344387054,
0.04410071671009064,
-0.00021841918351128697,
-0.01240887027233839,
-0.006195565219968557,
-0.0017750716069713235,
-0.04548440873622894,
-0.017792847007513046,
0.02934134565293789,
0.026130473241209984,
-0.046264953911304474,
-0.04984835907816887,
0.0060846926644444466,
-0.009526181034743786,
0.02738998644053936,
-0.02112789824604988,
0.004696566611528397,
-0.014173963107168674,
-0.06269184499979019,
-0.006572532467544079,
0.0062709590420126915,
-0.01827181689441204,
0.027123892679810524,
-0.027656082063913345,
0.01023576594889164,
-0.02187296189367771,
-0.04640686884522438,
-0.019815165549516678,
0.04044635221362114,
-0.05758283659815788,
-0.02618369273841381,
0.04913877323269844,
0.01251530833542347,
-0.03542603924870491,
0.06102432310581207,
-0.015034335665404797,
-0.004683262202888727,
-0.034414879977703094,
0.00656809750944376,
0.081389419734478,
-0.06393362581729889,
-0.09600687026977539,
0.0320732481777668,
-0.027443205937743187,
-0.0011070637265220284,
0.05981802940368652,
0.04633590951561928,
-0.0015100858872756362,
0.02763834223151207,
-0.05942775681614876,
-0.008098140358924866,
-0.029696138575673103,
-0.04594564065337181,
-0.02978483773767948,
0.018129900097846985,
0.025367669761180878,
0.04523605480790138,
0.012834621593356133,
-0.0001628442551009357,
-0.04622947424650192,
0.10757310688495636,
-0.0035213164519518614,
0.016063233837485313,
0.014138484373688698,
0.06996509432792664,
-0.07869299501180649,
-0.01402317639440298,
-0.03508898615837097,
-0.02859628200531006,
0.008191273547708988,
-0.0210037212818861,
-0.044810302555561066,
-0.012550787068903446,
0.015531045384705067,
0.01363290473818779,
0.021145638078451157,
0.03037024475634098,
-0.03384721279144287,
-0.010918742045760155,
0.006395136006176472,
0.005051359534263611,
-0.014200572855770588,
-0.03386495262384415,
0.07755766063928604,
-0.005290844477713108,
-0.0004160497337579727,
0.050451505929231644,
0.007712303660809994,
-0.053715597838163376,
-0.015025465749204159,
0.03966581076383591,
-0.061591990292072296,
-0.01926523633301258,
0.03230386599898338,
-0.006909585557878017,
-0.015690701082348824,
0.10076109319925308,
-0.011858941987156868,
0.04718741402029991,
0.04023347795009613,
-0.016302719712257385,
0.017429186031222343,
-0.04126237705349922,
-0.07024893164634705,
0.03012189082801342,
-0.004829613957554102,
-0.04488126188516617,
0.05953419581055641,
-0.04104950278997421,
0.05658941715955734,
0.023806581273674965,
0.0003179274208378047,
-0.00399806909263134,
-0.00980114471167326,
-0.025332190096378326,
-0.0407656654715538,
0.00433955667540431,
-0.025580544024705887,
-0.05279313400387764,
0.02503061667084694,
0.06705579906702042,
0.013278111815452576,
-0.026485266163945198,
0.025119313970208168,
0.05229642614722252,
0.05339628458023071,
0.04097854346036911,
0.039346497505903244,
-0.05485093221068382,
-0.019903862848877907,
-0.04665522277355194,
-0.023096997290849686,
-0.029554221779108047,
-0.015069814398884773,
0.03870787099003792,
0.05105465278029442,
0.030902434140443802,
0.0016874822322279215,
0.02236967161297798,
-0.05502833053469658,
0.00718011474236846,
0.04803891479969025,
0.04229127615690231,
-0.03657911345362663,
0.021411731839179993,
0.004581259097903967,
-0.014377969317138195,
0.07251960039138794,
0.036650072783231735,
0.0579376295208931,
-0.07784149050712585,
0.016018884256482124,
-0.04622947424650192,
0.021482691168785095,
0.008395279757678509,
-0.02804635278880596,
-0.0037031476385891438,
0.019212018698453903,
-0.010058369487524033,
-0.03707582503557205,
0.0015400215052068233,
0.01852017268538475,
0.030033191666007042,
0.0037275394424796104,
-0.024516167119145393,
-0.054673537611961365,
-0.042787984013557434,
0.008027181960642338,
0.004372818395495415,
-0.022156797349452972,
-0.042610589414834976,
0.04523605480790138,
-0.021731045097112656,
-0.03132818639278412,
-0.02456938661634922,
0.05602174997329712,
-0.01735822670161724,
-0.03349241986870766,
-0.028649501502513885,
-0.0024347640573978424,
-0.011903290636837482,
0.0025700286496430635,
0.014865809120237827,
-0.006217740010470152,
0.06492704153060913,
0.05949871614575386,
-0.016648640856146812,
-0.000036068267945665866,
0.005876251962035894,
-0.020436052232980728,
0.00241924193687737,
0.06517539918422699,
0.027567382901906967,
0.002405937062576413,
0.01695021614432335,
-0.04917425289750099,
-0.03244578093290329,
0.009774535894393921,
0.021943921223282814,
-0.052722178399562836,
-0.044597428292036057,
0.011734764091670513,
-0.01152188889682293,
-0.0022562590893357992,
0.05066438019275665,
-0.03672103211283684,
-0.07092303782701492,
0.0185556523501873,
0.0506289005279541,
0.016967955976724625,
-0.002762947231531143,
0.05758283659815788,
0.07961545139551163,
0.033918172121047974,
-0.040836624801158905,
-0.01823633909225464,
0.0481453537940979,
-0.0432492159307003,
0.045555368065834045,
-0.0026742490008473396,
0.028330188244581223,
0.05783119052648544,
-0.01653333380818367,
0.00762360543012619,
0.030725037679076195,
0.01595679670572281,
-0.02394849993288517,
0.06854592263698578,
-0.03377625346183777,
0.005024749785661697,
-0.0051711020059883595,
0.031062090769410133,
0.03881430998444557,
-0.04718741402029991,
0.028667239472270012,
-0.07819628715515137,
0.022635767236351967,
0.03340372070670128,
-0.06127267703413963,
-0.006860801484435797,
0.06985865533351898,
-0.02366466447710991,
-0.017748499289155006,
-0.040872104465961456,
-0.02134077437222004,
0.007672389503568411,
-0.035993706434965134,
0.012923319824039936,
0.018945923075079918,
-0.015761660411953926,
-0.02291960082948208,
-0.016790559515357018,
0.0060536484234035015,
-0.004423819947987795,
0.002328326227143407,
-0.05077081918716431,
-0.03191359341144562,
-0.0006353004719130695,
-0.05286409333348274,
-0.00406237505376339,
-0.04587468132376671,
0.04608755558729172,
0.03771445155143738,
-0.02316795475780964,
0.034663233906030655,
0.0036698856856673956,
0.030068671330809593,
0.04367496818304062,
0.009552789852023125,
0.06932646781206131,
-0.044810302555561066,
-0.008772246539592743,
0.02934134565293789,
0.015202862210571766,
-0.009685837663710117,
0.007428469602018595,
-0.009472961537539959,
-0.017464663833379745,
-0.024995137006044388,
-0.05843433737754822,
-0.02440972998738289,
0.06694936007261276,
-0.06936194747686386,
-0.0008869814337231219,
0.033793993294239044,
-0.061804868280887604,
0.000006167292667669244,
0.043568529188632965,
-0.010821173898875713,
0.018750788643956184,
-0.005162232089787722,
-0.00038195637171156704,
-0.028330188244581223,
-0.043533049523830414,
0.015397997573018074,
-0.01620515063405037,
0.024711303412914276,
0.00701158819720149,
0.013792561367154121,
0.010723605751991272,
-0.04672618210315704,
0.0738678127527237,
-0.010324464179575443,
0.015681831166148186,
-0.03223290666937828,
-0.020453792065382004,
-0.03012189082801342,
0.02329213358461857,
0.01591244712471962,
0.009082689881324768,
-0.02742546610534191,
0.040339916944503784,
-0.054176826030015945,
-0.04002060368657112,
-0.003536838572472334,
-0.048216313123703,
-0.09692933410406113,
0.05041602626442909,
0.006714449729770422,
-0.01624063029885292,
-0.0006962804473005235,
0.01102517917752266,
0.01910557970404625,
0.055134765803813934,
-0.01839599572122097,
0.03306666761636734,
0.018378255888819695,
-0.019815165549516678,
0.021979400888085365,
-0.002292847028002143,
-0.06254993379116058,
-0.014324750751256943,
-0.014910157769918442,
-0.053963951766490936,
-0.00023144672741182148,
0.04023347795009613,
-0.022653507068753242,
-0.006395136006176472,
-0.018466953188180923,
-0.07486123591661453,
0.01860886998474598,
-0.015087554231286049,
0.060598570853471756,
0.06113076210021973,
0.007583691272884607,
-0.017881546169519424,
0.006616881582885981,
-0.020489271730184555,
0.016772819682955742,
0.06950386613607407,
0.0184846930205822,
-0.045803721994161606,
0.055383119732141495,
-0.038140203803777695,
-0.030228327959775925,
-0.009313304908573627,
-0.04005608335137367,
-0.0018260730430483818,
-0.049777399748563766,
0.021447211503982544,
0.0037031476385891438,
-0.004093419294804335,
0.015149642713367939,
0.03306666761636734,
-0.007149070501327515,
0.024622604250907898,
-0.03347468003630638,
-0.012914449907839298,
0.06755250692367554,
0.023026037961244583,
-0.017163090407848358,
0.05953419581055641,
0.08060887455940247,
0.03546151891350746,
0.005636767018586397,
0.012329041957855225,
-0.06737510859966278,
0.006364091765135527,
-0.04026895761489868,
0.010040629655122757,
0.01000515092164278,
-0.05981802940368652,
-0.007987268269062042,
-0.05846981704235077,
-0.08238283544778824,
0.021518170833587646,
-0.020826324820518494,
0.02192618139088154,
-0.031062090769410133,
-0.0665590912103653,
0.019921602681279182,
0.048216313123703,
-0.010652647353708744,
0.020826324820518494,
-0.0057387701235711575,
0.01099857036024332,
0.01727839931845665,
0.008528326638042927,
-0.013597426004707813,
-0.02673362009227276,
-0.03973677009344101,
0.008497281931340694,
-0.07344206422567368,
-0.012036338448524475,
0.021908441558480263,
-0.02531445026397705,
0.04168812930583954,
0.04374592378735542,
-0.029394565150141716,
0.013553076423704624,
-0.025757940486073494,
-0.04073018953204155,
0.06315308064222336,
-0.00008488689491059631,
0.004550214856863022,
0.03546151891350746,
0.04591016098856926,
0.047755081206560135,
0.029926754534244537,
-0.020311875268816948,
-0.04218483716249466,
0.02664492279291153,
-0.030033191666007042,
0.04055279120802879,
-0.005991559475660324,
0.06797825545072556,
-0.04151073098182678,
0.017748499289155006,
0.006630186457186937,
-0.007703433744609356,
-0.015894707292318344,
-0.00014032323088031262,
-0.03746609762310982,
0.10466381162405014,
-0.02850758284330368,
0.008772246539592743,
-0.09189128130674362,
0.004142203368246555,
0.05030958727002144,
0.00500257546082139,
-0.03468097373843193,
0.06453677266836166,
-0.021802004426717758,
-0.007082547061145306,
-0.032428041100502014,
-0.004958226345479488,
0.0074728187173604965,
-0.00572990020737052,
-0.000052110161050222814,
-0.02391302026808262,
0.01648898422718048,
0.05151588097214699,
0.03629527986049652,
-0.020365094766020775,
0.020400572568178177,
-0.01852017268538475,
0.030529901385307312,
-0.06730414927005768,
0.039878685027360916,
-0.0002676189469639212,
0.02025865577161312,
-0.02723032981157303,
0.022990558296442032,
-0.026627182960510254,
0.053928472101688385,
0.12183576822280884,
0.015389127656817436,
-0.012710443697869778,
-0.014307010918855667,
-0.002581116044893861,
0.021518170833587646,
0.014182833023369312,
-0.0010810086969286203,
0.004275250714272261,
-0.020240915939211845,
-0.043604008853435516,
0.018050072714686394,
0.048003435134887695,
-0.017340486869215965,
0.05176423862576485,
0.03654363378882408,
-0.0041887699626386166,
0.012887840159237385,
0.016542203724384308,
-0.03375851362943649,
0.05964063107967377,
0.04686810076236725,
0.05460257828235626,
0.0037497140001505613,
-0.012745923362672329,
-0.0456618033349514,
0.025420887395739555,
0.008914163336157799,
0.017917025834321976,
0.01814763993024826,
0.020737625658512115,
0.05357367917895317,
0.04367496818304062,
0.010643777437508106,
-0.0493161678314209,
-0.0531124472618103,
-0.022032618522644043,
0.012195995077490807,
0.004104506690055132,
-0.02540314942598343,
-0.004940486513078213,
0.019903862848877907,
-0.01926523633301258,
0.034627754241228104,
0.005508154630661011,
-0.04587468132376671,
0.0012406653258949518,
-0.005716595333069563,
-0.006825322285294533,
-0.0107945641502738,
0.05527668446302414,
0.055418599396944046,
-0.039346497505903244,
-0.06467868387699127,
0.013455508276820183,
-0.03931101784110069,
-0.028081832453608513,
0.0014901288086548448,
0.006772103253751993,
-0.011708155274391174,
0.018573392182588577,
0.00594721082597971,
-0.01052846945822239,
-0.03021058812737465,
-0.03235708177089691,
-0.022068098187446594,
0.031842634081840515,
-0.012533048167824745,
0.00286495010368526,
-0.007765522692352533,
-0.013686123304069042,
-0.035656653344631195,
-0.009428612887859344,
0.049245208501815796,
0.061591990292072296,
-0.006545923184603453,
0.030352504923939705,
0.006559227593243122,
-0.00907381996512413,
-0.01380143128335476,
-0.015637483447790146,
-0.018715308979153633,
0.015424607321619987,
-0.011051788926124573,
0.031150788068771362,
0.03970129042863846,
0.053147926926612854,
-0.036437198519706726,
0.009996281005442142,
-0.07266151905059814,
0.09004635363817215,
-0.01578827016055584,
-0.007907439954578876,
0.024746783077716827,
-0.026325609534978867,
0.028206009417772293,
0.01599227637052536,
-0.013224893249571323,
0.008355365134775639,
0.01106065884232521,
-0.0005141720757819712,
-0.00623547937721014,
-0.011734764091670513,
0.006820887327194214,
-0.0049493564292788506,
-0.019194278866052628,
0.01208068709820509,
0.01926523633301258,
-0.026981975883245468,
-0.011654935777187347,
-0.010218026116490364,
-0.01383691094815731,
-0.02075536549091339,
-0.024711303412914276,
0.04097854346036911,
0.006927324924618006,
-0.045023176819086075,
0.044526468962430954,
0.014812590554356575,
0.054176826030015945,
0.053183406591415405,
-0.009047211147844791,
-0.03418426588177681,
-0.04608755558729172,
0.050238627940416336,
0.034166526049375534,
0.02407267689704895,
-0.0037097998429089785,
-0.014511016197502613,
0.019531331956386566,
-0.027407726272940636,
-0.043355654925107956,
0.0531124472618103,
-0.01615193299949169,
-0.012089557014405727,
-0.03774993121623993,
-0.0037652363535016775,
-0.00961487926542759,
-0.04647782817482948,
-0.025208013132214546,
0.014351359568536282,
-0.01922975853085518,
0.044313594698905945,
-0.016347067430615425,
-0.008049356751143932,
-0.056128185242414474,
-0.04275250434875488,
0.022139057517051697,
-0.017127612605690956,
-0.027496425434947014,
0.015451217070221901,
-0.08784664422273636,
-0.0357276126742363,
-0.07177454233169556,
0.03874335065484047,
-0.040375396609306335,
0.11488183587789536,
0.024267813190817833,
-0.014209442771971226,
0.05431874468922615,
0.031062090769410133,
0.06748154759407043,
-0.05680229142308235,
-0.033173106610774994,
0.09409099072217941,
-0.06755250692367554,
-0.00579198868945241,
0.027709299698472023,
-0.0018438126426190138,
0.017331616953015327,
0.07273247838020325,
-0.03253448009490967,
0.011131617240607738,
0.03526638075709343,
0.012710443697869778,
-0.014440057799220085,
-0.007131330668926239,
-0.0006480508018285036,
-0.006168955937027931,
0.025970816612243652,
0.0047852648422122,
0.06191130355000496,
-0.04424263536930084,
-0.01898140273988247,
0.023469528183341026,
0.009366524405777454,
-0.04562632739543915,
0.008461803197860718,
-0.06446581333875656,
0.03501802682876587,
0.026006296277046204,
-0.023309871554374695,
-0.00579198868945241,
-0.036366239190101624,
-0.01657768338918686,
-0.01794363558292389,
-0.028188269585371017,
-0.10061917454004288,
-0.022387411445379257,
-0.008506151847541332,
0.006958369631320238,
-0.005889556836336851,
-0.009907582774758339,
0.024427469819784164,
0.024498427286744118,
0.03512446582317352,
0.018697569146752357,
0.03313762694597244,
-0.02022317610681057,
-0.03592274710536003,
0.08075079321861267,
0.004479256458580494,
-0.010909872129559517,
0.028312448412179947,
0.009339914657175541,
-0.028401145711541176,
-0.024019457399845123,
-0.02059570886194706,
0.03856595233082771,
-0.037856366485357285,
0.03037024475634098,
0.03070729784667492,
-0.02071988582611084,
0.01583261974155903
]
|
33,742 | bqplot.marks | Label | Label mark.
Attributes
----------
x_offset: int (default: 0)
horizontal offset in pixels from the stated x location
y_offset: int (default: 0)
vertical offset in pixels from the stated y location
text: string (default: '')
text to be displayed
default_size: string (default: '14px')
font size in px, em or ex
font_weight: {'bold', 'normal', 'bolder'}
font weight of the caption
drag_size: nonnegative float (default: 1.)
Ratio of the size of the dragged label font size to the default
label font size.
align: {'start', 'middle', 'end'}
alignment of the text with respect to the provided location
enable_move: Bool (default: False)
Enable the label to be moved by dragging. Refer to restrict_x,
restrict_y for more options.
restrict_x: bool (default: False)
Restricts movement of the label to only along the x axis. This is valid
only when enable_move is set to True. If both restrict_x and restrict_y
are set to True, the label cannot be moved.
restrict_y: bool (default: False)
Restricts movement of the label to only along the y axis. This is valid
only when enable_move is set to True. If both restrict_x and restrict_y
are set to True, the label cannot be moved.
Data Attributes
x: numpy.ndarray (default: [])
horizontal position of the labels, in data coordinates or in
figure coordinates
y: numpy.ndarray (default: [])
vertical position of the labels, in data coordinates or in
figure coordinates
color: numpy.ndarray or None (default: None)
label colors
size: numpy.ndarray or None (default: None)
label sizes
rotation: numpy.ndarray or None (default: None)
label rotations
opacity: numpy.ndarray or None (default: None)
label opacities
| class Label(_ScatterBase):
"""Label mark.
Attributes
----------
x_offset: int (default: 0)
horizontal offset in pixels from the stated x location
y_offset: int (default: 0)
vertical offset in pixels from the stated y location
text: string (default: '')
text to be displayed
default_size: string (default: '14px')
font size in px, em or ex
font_weight: {'bold', 'normal', 'bolder'}
font weight of the caption
drag_size: nonnegative float (default: 1.)
Ratio of the size of the dragged label font size to the default
label font size.
align: {'start', 'middle', 'end'}
alignment of the text with respect to the provided location
enable_move: Bool (default: False)
Enable the label to be moved by dragging. Refer to restrict_x,
restrict_y for more options.
restrict_x: bool (default: False)
Restricts movement of the label to only along the x axis. This is valid
only when enable_move is set to True. If both restrict_x and restrict_y
are set to True, the label cannot be moved.
restrict_y: bool (default: False)
Restricts movement of the label to only along the y axis. This is valid
only when enable_move is set to True. If both restrict_x and restrict_y
are set to True, the label cannot be moved.
Data Attributes
x: numpy.ndarray (default: [])
horizontal position of the labels, in data coordinates or in
figure coordinates
y: numpy.ndarray (default: [])
vertical position of the labels, in data coordinates or in
figure coordinates
color: numpy.ndarray or None (default: None)
label colors
size: numpy.ndarray or None (default: None)
label sizes
rotation: numpy.ndarray or None (default: None)
label rotations
opacity: numpy.ndarray or None (default: None)
label opacities
"""
# Mark decoration
icon = 'fa-font'
name = 'Labels'
# Other attributes
x_offset = Int(0).tag(sync=True)
y_offset = Int(0).tag(sync=True)
colors = List(trait=Color(default_value=None,
allow_none=True),
default_value=CATEGORY10)\
.tag(sync=True, display_name='Colors')
rotate_angle = Float(0.0).tag(sync=True)
text = Array(None, allow_none=True)\
.tag(sync=True, **array_serialization).valid(array_squeeze)
default_size = Float(16.).tag(sync=True)
drag_size = Float(1.).tag(sync=True)
font_unit = Enum(['px', 'em', 'pt', '%'],
default_value='px').tag(sync=True)
font_weight = Enum(['bold', 'normal', 'bolder'],
default_value='bold').tag(sync=True)
align = Enum(['start', 'middle', 'end'],
default_value='start').tag(sync=True)
_view_name = Unicode('Label').tag(sync=True)
_model_name = Unicode('LabelModel').tag(sync=True)
| (*args: 't.Any', **kwargs: 't.Any') -> 't.Any' | [
0.01751098968088627,
-0.06380793452262878,
-0.02254992350935936,
0.02975105121731758,
-0.015515832230448723,
-0.03296186402440071,
-0.036469630897045135,
0.035096216946840286,
0.0435408391058445,
-0.03823279216885567,
-0.01742747239768505,
-0.01278756931424141,
0.061580777168273926,
-0.012332859449088573,
-0.017446031793951988,
0.034966301172971725,
0.02332942746579647,
-0.04621342197060585,
0.021659061312675476,
-0.015330236405134201,
0.025797855108976364,
-0.01465281005948782,
0.029416978359222412,
-0.004514624364674091,
0.024999791756272316,
0.03246075287461281,
-0.025779295712709427,
-0.0032804107759147882,
0.01409602165222168,
-0.0168521236628294,
-0.04216742888092995,
-0.015330236405134201,
-0.039160773158073425,
-0.005758118350058794,
-0.01507968083024025,
-0.05560458451509476,
-0.0049554151482880116,
0.014949764125049114,
0.01379906851798296,
-0.007437762804329395,
0.017408911138772964,
-0.006996972020715475,
0.023626379668712616,
-0.03075326979160309,
0.01874520443379879,
0.031439974904060364,
-0.048217859119176865,
0.024535801261663437,
-0.05218961834907532,
-0.03173692896962166,
0.012295739725232124,
-0.01690780185163021,
-0.03422391787171364,
0.02995520643889904,
-0.04810650274157524,
0.03795439749956131,
0.06373368948698044,
0.08923459053039551,
-0.028470437973737717,
0.050519250333309174,
0.02602056972682476,
0.07152872532606125,
0.022531364113092422,
-0.035690125077962875,
-0.0642162412405014,
-0.014040343463420868,
0.04057130217552185,
0.0004405006766319275,
-0.009210205636918545,
-0.002248032484203577,
0.01248133648186922,
-0.017288275063037872,
0.02399757318198681,
0.04944279417395592,
-0.0005156091065146029,
-0.025278186425566673,
-0.021584823727607727,
0.017000600695610046,
0.0674084946513176,
-0.05608713626861572,
0.011943107470870018,
0.0058694761246442795,
0.03086462803184986,
-0.022661281749606133,
0.005999393295496702,
-0.03671090304851532,
-0.009771633893251419,
0.051038920879364014,
0.031439974904060364,
0.00996650941669941,
-0.042241666465997696,
0.030716150999069214,
0.003078575013205409,
0.04636190086603165,
-0.06002177298069,
-0.0209723562002182,
0.03956908360123634,
-0.07453538477420807,
0.008203346282243729,
0.04884888604283333,
0.035356052219867706,
-0.044208984822034836,
-0.010142825543880463,
-0.0038719980511814356,
-0.04962839186191559,
-0.019227754324674606,
-0.06718578189611435,
0.04476577416062355,
-0.05723783001303673,
0.017659466713666916,
0.04116521030664444,
0.00619426928460598,
0.004013515077531338,
0.023088151589035988,
-0.01193382777273655,
-0.029287060722708702,
-0.04235302656888962,
-0.034131117165088654,
-0.043392363935709,
-0.04020011052489281,
-0.02050836570560932,
0.011655434034764767,
-0.04320676624774933,
-0.0076790377497673035,
-0.022716959938406944,
0.037193454802036285,
0.04432034492492676,
0.030511995777487755,
-0.013158761896193027,
-0.0314585343003273,
0.017084117978811264,
-0.02384909614920616,
-0.026373201981186867,
0.029416978359222412,
0.07008107751607895,
-0.005823076702654362,
0.05493643879890442,
0.011210002936422825,
-0.05616137385368347,
0.07204839587211609,
0.057126473635435104,
-0.02117651328444481,
0.06206332892179489,
0.03197820484638214,
-0.012991725467145443,
-0.01475488767027855,
0.004059914033859968,
-0.043689318001270294,
-0.03834414854645729,
-0.019060717895627022,
-0.013353637419641018,
0.010152105242013931,
0.009381881915032864,
-0.0038789580576121807,
0.029342738911509514,
0.0029277780558913946,
-0.012119423598051071,
-0.07034091651439667,
0.030437756329774857,
0.0588710755109787,
-0.032609231770038605,
-0.038047194480895996,
0.02136210910975933,
0.004672381095588207,
-0.02345934323966503,
0.035690125077962875,
0.01978454180061817,
-0.02596489153802395,
-0.03684082254767418,
0.033147457987070084,
-0.014847686514258385,
-0.0684107169508934,
0.0070526511408388615,
0.06558965146541595,
-0.025519460439682007,
0.02811780571937561,
0.003549525048583746,
0.07349604368209839,
-0.00281874043866992,
0.005748838651925325,
0.0209723562002182,
0.0216961819678545,
-0.027449660003185272,
-0.013938264921307564,
-0.003131933743134141,
-0.004514624364674091,
0.01474560797214508,
0.016035500913858414,
0.056272730231285095,
0.0084260618314147,
0.05100180208683014,
0.011590475216507912,
-0.02267984114587307,
0.020007256418466568,
-0.024869874119758606,
0.030511995777487755,
-0.0171769168227911,
-0.04116521030664444,
-0.03288762643933296,
-0.003155133221298456,
0.03912365436553955,
0.017520269379019737,
0.04220454767346382,
-0.0038534386549144983,
-0.008964290842413902,
0.012332859449088573,
0.02431308664381504,
0.02876739203929901,
-0.0782473087310791,
-0.06930157542228699,
0.022716959938406944,
-0.009780913591384888,
-0.01531167607754469,
0.034836385399103165,
0.060318723320961,
-0.03815855458378792,
-0.0279878880828619,
0.00813374761492014,
-0.05753478407859802,
-0.0017469230806455016,
0.08106836676597595,
0.012444216758012772,
-0.02164050191640854,
0.019561827182769775,
-0.01170183252543211,
-0.03138429671525955,
0.06035584583878517,
-0.010170664638280869,
0.06150653958320618,
-0.06150653958320618,
0.02319950982928276,
-0.07008107751607895,
0.024164609611034393,
0.03173692896962166,
-0.01684284396469593,
0.011553355492651463,
0.028154924511909485,
-0.0245172418653965,
-0.0459907092154026,
-0.0022445525974035263,
-0.00689953425899148,
0.025092588737607002,
-0.03617267683148384,
-0.010152105242013931,
0.04109097272157669,
-0.0027630615513771772,
0.03416823595762253,
0.03643250837922096,
-0.05204113945364952,
-0.06143230199813843,
-0.016230376437306404,
-0.005980833433568478,
-0.022958233952522278,
-0.00845854077488184,
0.037453290075063705,
-0.09599029272794724,
-0.019840219989418983,
-0.039160773158073425,
0.03986603766679764,
0.018234815448522568,
-0.08737863600254059,
-0.0330546610057354,
-0.018058497458696365,
0.07906392961740494,
0.045136965811252594,
0.022067373618483543,
-0.0067092981189489365,
0.033667128533124924,
-0.053525909781455994,
0.005331247113645077,
0.025203946977853775,
0.04127656668424606,
0.003542565042153001,
0.0033384093549102545,
0.013585632666945457,
-0.023310868069529533,
-0.026503119617700577,
-0.022772638127207756,
0.05590153858065605,
-0.024610040709376335,
0.021844659000635147,
-0.06666611135005951,
-0.004124872852116823,
0.0003236331685911864,
0.0029463376849889755,
-0.07063786685466766,
0.003651602892205119,
-0.06265723705291748,
-0.017882181331515312,
-0.01146983727812767,
-0.006658259313553572,
0.02058260515332222,
0.01749243028461933,
-0.031495653092861176,
-0.03099454566836357,
0.01136775966733694,
0.014133141376078129,
0.0601702481508255,
-0.03223804011940956,
-0.04784666746854782,
0.000504879339132458,
-0.030567673966288567,
0.06481014937162399,
0.006444823928177357,
-0.013288679532706738,
-0.03793583810329437,
0.0462876632809639,
-0.00904316920787096,
0.021120833232998848,
-0.009312283247709274,
0.010671774856746197,
0.04988822713494301,
0.054825082421302795,
0.02765381522476673,
-0.057905975729227066,
0.05040789395570755,
0.041387926787137985,
-0.021529145538806915,
0.044543057680130005,
0.04851481318473816,
-0.01913495548069477,
-0.07936087995767593,
-0.1035626083612442,
-0.04858905449509621,
0.047289881855249405,
0.0364510677754879,
0.05478796362876892,
0.009187005460262299,
0.024999791756272316,
0.03741616755723953,
0.018012098968029022,
-0.03363000974059105,
-0.007572319824248552,
-0.009678835049271584,
-0.028006447479128838,
-0.009882991202175617,
-0.03327737748622894,
0.009446840733289719,
0.009456120431423187,
-0.06395640969276428,
-0.010244903154671192,
-0.01881016232073307,
-0.09153598546981812,
0.04075689986348152,
0.0012771330075338483,
0.0014522892888635397,
0.06239740177989006,
-0.019153514876961708,
0.03414967656135559,
0.09123903512954712,
-0.007349604740738869,
0.05723783001303673,
-0.020137174054980278,
-0.0023466304410248995,
-0.00008728815737413242,
-0.02811780571937561,
0.018262654542922974,
-0.02982528880238533,
-0.010050027631223202,
-0.022401446476578712,
-0.020434128120541573,
-0.071009062230587,
0.02988096885383129,
-0.004175911657512188,
-0.03394552320241928,
-0.022494245320558548,
-0.020471246913075447,
0.0027839411050081253,
0.025408102199435234,
0.00996650941669941,
-0.010050027631223202,
0.025983450934290886,
-0.0390494130551815,
-0.0023489503655582666,
-0.011525516398251057,
-0.006639699451625347,
-0.013214441016316414,
0.016165418550372124,
-0.02503691054880619,
-0.07516641169786453,
0.015831345692276955,
-0.024869874119758606,
-0.006978412624448538,
0.06896749883890152,
0.03678514063358307,
-0.0022619522642344236,
0.04142504557967186,
-0.0021018756087869406,
-0.0010654374491423368,
-0.03125438094139099,
0.033908404409885406,
-0.04936855658888817,
0.0009714794578030705,
-0.03927212953567505,
-0.06068991869688034,
-0.06751985102891922,
0.02188177779316902,
0.04439458250999451,
-0.013659871183335781,
-0.0018803202547132969,
-0.003408008022233844,
-0.014615691266953945,
-0.004419506527483463,
-0.005308047868311405,
-0.004173591732978821,
0.05508491396903992,
0.04851481318473816,
0.0019580386579036713,
-0.029064346104860306,
0.07631710916757584,
0.013093803077936172,
0.017798664048314095,
-0.0006304466514848173,
-0.03468790650367737,
0.02273551933467388,
-0.01978454180061817,
-0.06584949046373367,
-0.004210710991173983,
-0.02024853229522705,
-0.033388733863830566,
-0.048403456807136536,
0.03808431327342987,
0.05805445462465286,
-0.014504333026707172,
0.009400441311299801,
-0.0032572110649198294,
-0.024869874119758606,
0.007623358629643917,
0.04346660152077675,
0.028618915006518364,
-0.049257200211286545,
0.007117609493434429,
-0.05734918639063835,
0.004175911657512188,
-0.0016239656833931804,
-0.035894282162189484,
-0.006463383324444294,
-0.07468385994434357,
-0.03717489540576935,
0.01291748695075512,
0.02995520643889904,
-0.000293183809844777,
0.044283222407102585,
0.024535801261663437,
-0.05927938595414162,
-0.007256806828081608,
-0.09250108152627945,
0.019283432513475418,
0.04443170130252838,
-0.04858905449509621,
0.06859631091356277,
0.09947949647903442,
0.05315471813082695,
0.0000026326006263843738,
-0.047030046582221985,
-0.06313978880643845,
-0.033797044306993484,
-0.10705181956291199,
-0.00888077262789011,
0.001569446874782443,
-0.05330319330096245,
-0.02483275532722473,
-0.05085332691669464,
0.004175911657512188,
0.03309177979826927,
-0.037267692387104034,
0.03826991096138954,
-0.029676813632249832,
-0.05493643879890442,
-0.006147869862616062,
0.06599796563386917,
-0.06573813408613205,
0.031180141493678093,
0.005424045491963625,
-0.011822470463812351,
0.037583205848932266,
-0.015487992204725742,
0.003370888764038682,
-0.06373368948698044,
-0.03164413198828697,
0.047104284167289734,
-0.06518134474754333,
-0.008082709275186062,
0.02772805467247963,
-0.011321360245347023,
0.05894531309604645,
0.03272058814764023,
-0.0008473620982840657,
0.0014024103293195367,
0.03158845379948616,
-0.0730506181716919,
0.03982891887426376,
-0.007892473600804806,
-0.016295336186885834,
0.0012365338625386357,
0.05779461935162544,
0.01572926715016365,
-0.028878750279545784,
-0.02975105121731758,
-0.03524469584226608,
-0.0014128501061350107,
-0.023347986862063408,
0.040942493826150894,
-0.05979905650019646,
0.06109822914004326,
-0.0419447124004364,
-0.0065608215518295765,
0.013854746706783772,
-0.00689953425899148,
-0.012407097965478897,
-0.05270928516983986,
0.007284645922482014,
0.07624287158250809,
0.035374611616134644,
0.04896024614572525,
-0.029157143086194992,
-0.03782448172569275,
0.05545610934495926,
0.002403469290584326,
-0.04973974823951721,
0.015562230721116066,
-0.0013130921870470047,
-0.03279482573270798,
-0.07308773696422577,
-0.017678026109933853,
0.05950210243463516,
-0.012184382416307926,
-0.0295097753405571,
0.011098645627498627,
0.02824772335588932,
-0.01278756931424141,
0.007034091278910637,
0.011943107470870018,
0.03570868447422981,
0.02923138253390789,
0.02568649686872959,
-0.016035500913858414,
0.048217859119176865,
0.021659061312675476,
0.0351518951356411,
-0.001585686462931335,
-0.017316114157438278,
0.01724187470972538,
0.012425657361745834,
0.03994027525186539,
0.020304210484027863,
0.032405074685811996,
-0.008736935444176197,
0.0023176309186965227,
-0.001043977914378047,
-0.006639699451625347,
-0.0022526723332703114,
-0.01585918478667736,
-0.011748231947422028,
0.022791197523474693,
0.045136965811252594,
-0.015330236405134201,
0.005781317595392466,
0.04331812262535095,
0.05630984902381897,
-0.04706716537475586,
0.0687076672911644,
0.050630610436201096,
-0.07490658015012741,
0.013808348216116428,
0.06388217210769653,
-0.027245504781603813,
0.00950251892209053,
0.010235623456537724,
-0.04766107350587845,
0.02700422890484333,
0.0034660068340599537,
-0.001272493158467114,
0.026466000825166702,
-0.0064958627335727215,
0.04621342197060585,
0.02746821939945221,
0.03557876870036125,
-0.064513199031353,
-0.0335557721555233,
-0.022457124665379524,
0.050630610436201096,
0.03878958150744438,
-0.04606494680047035,
0.013854746706783772,
0.024888433516025543,
0.00037003218312747777,
-0.009743793867528439,
-0.008769414387643337,
-0.014736328274011612,
-0.0280621275305748,
0.015413754619657993,
0.0229953546077013,
0.01881016232073307,
0.02962113358080387,
0.0036678423639386892,
0.008978210389614105,
-0.02563081867992878,
0.04751259461045265,
0.010439779609441757,
0.010170664638280869,
0.01507968083024025,
-0.021529145538806915,
0.043355245143175125,
0.011516236700117588,
0.01475488767027855,
-0.007270726375281811,
-0.03156989440321922,
-0.03639538958668709,
-0.01860600709915161,
0.0321081206202507,
0.038307029753923416,
-0.0011222762987017632,
-0.06889326125383377,
0.022846877574920654,
-0.05734918639063835,
-0.0420931912958622,
0.012620532885193825,
0.040348585695028305,
-0.006556181237101555,
0.0343538336455822,
0.013966104947030544,
-0.011432718485593796,
-0.0038325591012835503,
-0.04862617328763008,
-0.015896303579211235,
-0.01412386167794466,
-0.05426829308271408,
0.014903364703059196,
-0.007252166513353586,
0.0446915365755558,
-0.007813595235347748,
0.018698804080486298,
-0.06425336003303528,
0.04561951756477356,
0.010421219281852245,
-0.047364119440317154,
-0.006862415000796318,
0.021399227902293205,
0.05330319330096245,
-0.0028929789550602436,
-0.06599796563386917,
0.005632841028273106,
0.06707442551851273,
-0.03119870088994503,
-0.009678835049271584,
-0.0016518051270395517,
-0.033203139901161194,
0.017919301986694336,
0.018123457208275795,
-0.0054472447372972965,
0.032664909958839417,
-0.0029695371631532907,
-0.04279845580458641,
-0.005888035520911217,
0.05196690186858177,
-0.05334031209349632,
-0.023682059720158577,
-0.013065963983535767,
-0.03945772722363472,
-0.04543391987681389,
0.020304210484027863,
0.046695973724126816,
0.04832921922206879,
0.04858905449509621,
-0.013028844259679317,
0.008797254413366318,
0.006393784657120705,
0.05385998263955116,
-0.018559608608484268,
-0.01835545152425766,
0.00898285023868084,
-0.020025815814733505,
-0.030901746824383736,
-0.0004059914208482951,
-0.03622835502028465,
0.06198909133672714,
-0.019060717895627022,
0.02963969297707081,
-0.022772638127207756,
-0.008439981378614902,
0.0026725835632532835,
-0.03138429671525955,
0.033147457987070084,
0.0025125069078058004,
0.011525516398251057,
0.0432438850402832,
-0.03604275733232498,
0.004718780051916838,
0.0011205363553017378,
0.0343538336455822,
0.05367438495159149,
0.03841838613152504,
-0.01650877110660076,
0.014476493932306767,
-0.054231174290180206,
-0.014337296597659588,
-0.05697799474000931,
0.02102803625166416,
-0.028136365115642548,
0.0378987193107605,
-0.030233601108193398,
-0.05545610934495926,
0.04157352074980736,
-0.015627190470695496,
0.0475868359208107,
-0.06139518320560455,
-0.0007644238648936152,
0.02280975878238678,
-0.023236628621816635,
0.037007857114076614,
0.056272730231285095,
0.03845550864934921,
-0.02216017246246338,
-0.019283432513475418,
-0.04320676624774933,
0.03246075287461281,
0.012091584503650665,
-0.03841838613152504,
0.030252160504460335,
-0.0033384093549102545,
0.0348549447953701,
0.01873592473566532,
0.03387128561735153,
-0.029342738911509514,
0.03769456222653389,
-0.0007644238648936152,
-0.03986603766679764,
-0.05330319330096245,
-0.0060829115100204945,
0.01236069854348898,
0.08336975425481796,
-0.02438732422888279,
0.03815855458378792,
-0.018169855698943138,
0.010152105242013931,
-0.003751360811293125,
0.01684284396469593,
-0.0065608215518295765,
0.021417787298560143,
-0.001430249772965908,
-0.038307029753923416,
-0.05360014736652374,
0.005530762951821089,
-0.02902722731232643,
0.01959894597530365,
0.009112766943871975,
0.06815087795257568,
0.01650877110660076,
0.014643530361354351,
0.0642162412405014,
0.04361507669091225,
-0.09688115119934082,
-0.006648979615420103,
0.060467202216386795,
-0.08173651248216629,
0.05014805868268013,
-0.012889647856354713,
0.013938264921307564,
-0.05374862253665924,
0.00568387983366847,
-0.04691868647933006,
0.018531767651438713,
0.012537014670670033,
0.055753059685230255,
0.075797438621521,
-0.0684107169508934,
0.07293926179409027
]
|
33,747 | bqplot.marks | __init__ | null | def __init__(self, **kwargs):
self._drag_start_handlers = CallbackDispatcher()
self._drag_handlers = CallbackDispatcher()
self._drag_end_handlers = CallbackDispatcher()
super(_ScatterBase, self).__init__(**kwargs)
self._name_to_handler.update({
'drag_start': self._drag_start_handlers,
'drag_end': self._drag_end_handlers,
'drag': self._drag_handlers
})
| (self, **kwargs) | [
-0.058509163558483124,
-0.036778759211301804,
0.004411986563354731,
0.024915823712944984,
-0.046792685985565186,
0.04137381538748741,
-0.03661399334669113,
0.0677725076675415,
-0.04357065260410309,
0.04195963963866234,
0.01900266297161579,
0.07319137454032898,
-0.0046957447193562984,
-0.014471681788563728,
-0.011981929652392864,
0.017309265211224556,
0.008965851739048958,
0.01922234706580639,
-0.03137819468975067,
-0.04313128441572189,
-0.006498984061181545,
-0.004290702752768993,
-0.013126117177307606,
-0.011267957277595997,
0.010462448932230473,
0.10032234340906143,
-0.04620686173439026,
0.022462686523795128,
0.021437494084239006,
-0.013986545614898205,
-0.05459146574139595,
0.023561105132102966,
0.018425993621349335,
-0.008581405505537987,
0.022078238427639008,
-0.03870099410414696,
-0.007638594601303339,
0.02921796776354313,
-0.02947426587343216,
0.05407886952161789,
0.033556725829839706,
-0.0424722358584404,
0.0015194808365777135,
0.012787437997758389,
0.06030324846506119,
0.0559827983379364,
-0.036522459238767624,
-0.01984478533267975,
-0.01859990879893303,
-0.027899865061044693,
-0.05543358996510506,
-0.02599593624472618,
0.001965713920071721,
0.03619293496012688,
-0.010078001767396927,
0.07436302304267883,
0.08062401413917542,
0.09944360703229904,
-0.02171209827065468,
0.028449073433876038,
-0.035039592534303665,
0.06920044869184494,
0.03406932204961777,
-0.04979503154754639,
-0.039030518382787704,
-0.06894415616989136,
0.01713535003364086,
-0.015231422148644924,
-0.009977313689887524,
0.05514067783951759,
0.028796907514333725,
0.037675801664590836,
-0.016796670854091644,
0.006778165698051453,
0.05594618245959282,
0.01416961569339037,
0.014160462655127048,
-0.022169774398207664,
0.043680496513843536,
-0.02297528274357319,
-0.0011367500992491841,
-0.018087312579154968,
-0.03760257363319397,
0.05682491883635521,
-0.02033907361328602,
-0.028577223420143127,
-0.05111313611268997,
0.003151091979816556,
0.024146929383277893,
-0.01416961569339037,
-0.07776812463998795,
0.01962510123848915,
-0.022444378584623337,
0.03222031518816948,
-0.0456942655146122,
-0.021931782364845276,
-0.03311735764145851,
-0.06451386213302612,
0.020393995568156242,
0.06780911982059479,
-0.0051717269234359264,
-0.025684718042612076,
-0.011927008628845215,
-0.022389458492398262,
-0.008347990922629833,
-0.0394698865711689,
0.0005712355487048626,
-0.009272494353353977,
-0.09402474015951157,
0.02509889379143715,
0.07439963519573212,
0.03551557660102844,
0.030938826501369476,
0.08721453696489334,
-0.06667408347129822,
0.007606557570397854,
-0.018526680767536163,
-0.03112189657986164,
0.01638476364314556,
-0.029455959796905518,
-0.059534355998039246,
0.03575356677174568,
0.026783136650919914,
0.04144704341888428,
-0.018416838720440865,
0.024403227493166924,
0.01649460382759571,
0.037181511521339417,
0.014773746952414513,
-0.028028013184666634,
0.05074699595570564,
-0.03544234856963158,
-0.029822098091244698,
0.01310781016945839,
0.008265608921647072,
-0.009821704588830471,
0.03445376828312874,
0.018178848549723625,
-0.05158912017941475,
-0.00020152000070083886,
-0.017565563321113586,
-0.004887968301773071,
0.032055553048849106,
0.04401002079248428,
-0.04558442533016205,
0.047524966299533844,
-0.013885857537388802,
0.0009960150346159935,
0.016814976930618286,
-0.0028581800870597363,
-0.0026613797526806593,
0.005414294544607401,
0.02271898463368416,
0.008654632605612278,
-0.0012894991086795926,
-0.035662032663822174,
-0.051259592175483704,
-0.04499860107898712,
0.015387031249701977,
0.07363074272871017,
-0.03300751745700836,
-0.05312690511345863,
0.028833521530032158,
-0.04723205417394638,
-0.007011579815298319,
0.010755361057817936,
0.01723603904247284,
-0.07776812463998795,
-0.002296383958309889,
0.04649977385997772,
0.03362995386123657,
-0.012229074724018574,
0.02033907361328602,
0.037309661507606506,
0.011551715433597565,
0.012705055996775627,
0.010288532823324203,
0.009885778650641441,
-0.019936319440603256,
0.01861821673810482,
0.05733751505613327,
-0.026380382478237152,
-0.011222189292311668,
0.016814976930618286,
-0.015954548493027687,
-0.02411031536757946,
0.019332189112901688,
-0.013492257334291935,
0.05312690511345863,
0.0424722358584404,
0.02196839638054371,
0.020082775503396988,
-0.02934611774981022,
-0.045547809451818466,
0.04510844126343727,
0.042765144258737564,
0.008769052103161812,
-0.025025665760040283,
0.024531377479434013,
0.033025823533535004,
-0.028833521530032158,
0.04411986470222473,
0.043973408639431,
0.01493851002305746,
0.028705371543765068,
0.03611970692873001,
0.051296208053827286,
0.031012054532766342,
-0.012439604848623276,
-0.038554538041353226,
0.03463684022426605,
-0.011826320551335812,
-0.011478487402200699,
0.003686571726575494,
0.017812708392739296,
-0.02758864499628544,
-0.04064153507351875,
-0.01231145579367876,
0.015268036164343357,
-0.007373143453150988,
0.059387899935245514,
0.04558442533016205,
-0.057667043060064316,
-0.004718628711998463,
-0.020320767536759377,
0.003350180573761463,
0.05330997705459595,
-0.07180004566907883,
-0.00015961413737386465,
-0.04184979572892189,
-0.029053205624222755,
-0.011899548582732677,
-0.00315566873177886,
0.038041941821575165,
-0.015826398506760597,
-0.028796907514333725,
0.027076048776507378,
-0.06378158181905746,
-0.05667846277356148,
-0.05396902933716774,
0.006650016643106937,
0.034160856157541275,
-0.010975045152008533,
-0.05133282020688057,
-0.0067827426828444,
-0.01573486439883709,
-0.020210925489664078,
0.05711783096194267,
-0.03247661516070366,
0.028632143512368202,
0.027552030980587006,
-0.010553983971476555,
-0.06231702119112015,
0.017831016331911087,
-0.027533724904060364,
-0.05975404009222984,
-0.01661360077559948,
0.010947584174573421,
-0.005496676079928875,
-0.00948302447795868,
-0.02985871210694313,
0.04031200706958771,
-0.04210609570145607,
0.08164920657873154,
0.024018781259655952,
-0.030169932171702385,
0.03251322731375694,
-0.041300587356090546,
-0.07150713354349136,
0.021529028192162514,
0.11943484842777252,
0.016412222757935524,
0.006251839455217123,
0.015789784491062164,
-0.034545302391052246,
-0.03957972675561905,
-0.0454745814204216,
-0.06143828481435776,
0.019149119034409523,
-0.042032867670059204,
0.09636803716421127,
-0.011917855590581894,
-0.0004691168142016977,
0.033282119780778885,
-0.017666252329945564,
-0.03335534781217575,
0.04320451244711876,
-0.037163205444812775,
-0.019204040989279747,
-0.04818401858210564,
0.01074620708823204,
0.07212956994771957,
-0.000027710786525858566,
0.016073543578386307,
0.014663904905319214,
0.001994318561628461,
-0.034545302391052246,
0.06575873494148254,
-0.006077923346310854,
0.04386356472969055,
0.02623392827808857,
-0.04968519136309624,
0.042911600321531296,
0.03245830535888672,
0.01949695311486721,
-0.052650924772024155,
0.013290880247950554,
0.013940778560936451,
-0.013501410372555256,
-0.02586778812110424,
0.03522266447544098,
0.021510722115635872,
-0.04924582317471504,
0.017300112172961235,
-0.02335972897708416,
0.02035738155245781,
0.04184979572892189,
-0.023670947179198265,
-0.010187843814492226,
0.09343891590833664,
-0.03608309105038643,
-0.03844469413161278,
-0.04895291104912758,
-0.04111751541495323,
0.05283399298787117,
0.03362995386123657,
0.022297922521829605,
-0.024531377479434013,
-0.008595135062932968,
0.04708559811115265,
-0.04617024585604668,
-0.000041834347939584404,
0.000865577720105648,
-0.031780946999788284,
0.009949852712452412,
-0.029675642028450966,
-0.02846738137304783,
0.013574638403952122,
-0.00020666883210651577,
-0.06806541979312897,
0.012229074724018574,
0.061657968908548355,
-0.016311535611748695,
0.03414255008101463,
-0.00567974615842104,
-0.01248537190258503,
0.025703024119138718,
-0.01167986448854208,
0.04232577979564667,
-0.032147087156772614,
-0.019277269020676613,
-0.03494805842638016,
-0.05257769674062729,
0.025538261979818344,
0.05133282020688057,
0.03670553117990494,
-0.002725454280152917,
-0.038408081978559494,
-0.010709593072533607,
-0.01935049705207348,
0.0847247838973999,
-0.010325146839022636,
0.013721094466745853,
-0.010810282081365585,
0.015826398506760597,
0.01099335215985775,
0.016805823892354965,
-0.0677725076675415,
-0.004988656844943762,
0.0029108126182109118,
-0.02647191844880581,
-0.014105541631579399,
-0.016567831858992577,
0.04067814722657204,
-0.04181318357586861,
-0.035662032663822174,
0.04887968301773071,
0.009345722384750843,
0.026032550260424614,
-0.036046478897333145,
0.015643328428268433,
-0.03782225772738457,
0.015515180304646492,
-0.013666173443198204,
0.01085604913532734,
-0.010535676963627338,
-0.012549446895718575,
0.04335096850991249,
0.05074699595570564,
-0.015405338257551193,
0.025025665760040283,
-0.03661399334669113,
-0.025519954040646553,
-0.04100767523050308,
-0.021437494084239006,
-0.05935128405690193,
0.03037130832672119,
0.05558004602789879,
-0.025300269946455956,
0.0136753274127841,
-0.038188397884368896,
-0.031927403062582016,
0.011945315636694431,
-0.015798939391970634,
0.0913885310292244,
-0.005803318228572607,
0.0422525517642498,
0.005798741243779659,
0.045035213232040405,
0.021950090304017067,
0.042179323732852936,
0.008137460798025131,
-0.012851512059569359,
-0.021803634241223335,
0.02584948018193245,
-0.051406048238277435,
-0.03979941084980965,
0.01999124139547348,
-0.006855970714241266,
-0.005752974189817905,
-0.04309467226266861,
0.09321922808885574,
0.013455643318593502,
-0.004416563082486391,
0.025886094197630882,
0.01936880312860012,
-0.03626616299152374,
0.030041782185435295,
0.04660961404442787,
0.028320925310254097,
-0.04770803451538086,
0.09270663559436798,
-0.08662871271371841,
-0.014261150732636452,
0.009858318604528904,
0.017959164455533028,
0.03209216520190239,
-0.017803555354475975,
-0.011862934567034245,
0.010416681878268719,
-0.01516734715551138,
0.002316979458555579,
0.019716637209057808,
-0.031140202656388283,
-0.035039592534303665,
-0.011039119213819504,
-0.04682929813861847,
0.01204600464552641,
0.012897280044853687,
-0.05294383689761162,
0.037181511521339417,
0.085383839905262,
0.0609256885945797,
-0.02709435671567917,
0.009858318604528904,
-0.0532001331448555,
-0.07674293220043182,
-0.050527311861515045,
-0.023762483149766922,
-0.021693792194128036,
-0.030279774218797684,
-0.0679921880364418,
-0.06766266375780106,
-0.07666970789432526,
-0.0015812668716534972,
-0.01274167001247406,
0.02747880294919014,
-0.018682291731238365,
-0.01713535003364086,
0.022188080474734306,
0.0754980593919754,
0.0029794638976454735,
-0.010929277166724205,
-0.02522704191505909,
-0.03176264092326164,
-0.011066580191254616,
0.0034760411363095045,
-0.026654988527297974,
-0.0226274486631155,
-0.00973932258784771,
0.011725631542503834,
-0.044778916984796524,
0.014023159630596638,
-0.006723244674503803,
-0.031066974624991417,
0.04510844126343727,
-0.020650293678045273,
-0.027918171137571335,
0.025684718042612076,
0.038298238068819046,
-0.02912643365561962,
-0.0043227397836744785,
-0.0050527313724160194,
-0.005267838481813669,
0.038920678198337555,
0.04148365557193756,
-0.0017139926785603166,
-0.018297843635082245,
0.02696620672941208,
0.0000623939631623216,
-0.02786325104534626,
-0.013895011506974697,
0.0059406207874417305,
-0.012329762801527977,
0.02498905174434185,
-0.03135988488793373,
-0.020046161487698555,
0.018819592893123627,
-0.06601503491401672,
-0.016787515953183174,
0.04258207604289055,
-0.01697974093258381,
0.013830936513841152,
0.011606636457145214,
0.020467223599553108,
-0.06868785619735718,
-0.03701674938201904,
0.07304491847753525,
-0.05085683986544609,
-0.02037568762898445,
0.05894853174686432,
0.03284275531768799,
0.003569864435121417,
-0.036046478897333145,
-0.02301189675927162,
-0.007112268358469009,
0.029199661687016487,
0.006700361147522926,
0.03469175845384598,
-0.00035727251088246703,
0.016567831858992577,
-0.010178690776228905,
-0.032659683376550674,
0.03247661516070366,
0.022297922521829605,
0.0761571079492569,
-0.010645519010722637,
0.0070527708157896996,
-0.06290284544229507,
0.00905738677829504,
0.013858397491276264,
0.009176382794976234,
0.02660006657242775,
-0.04598717764019966,
-0.01599116250872612,
-0.036778759211301804,
-0.024915823712944984,
-0.018673136830329895,
0.019826477393507957,
-0.026325462386012077,
0.0547013096511364,
-0.03921359032392502,
-0.000864433532115072,
-0.015936240553855896,
-0.028705371543765068,
0.002720877528190613,
0.01585385948419571,
-0.03168941289186478,
0.013858397491276264,
0.03936004638671875,
-0.04924582317471504,
0.06008356437087059,
-0.007130575366318226,
0.02400047332048416,
-0.013327494263648987,
0.02509889379143715,
0.02213316038250923,
0.03833485394716263,
-0.03914036229252815,
-0.021767020225524902,
0.0015057505806908011,
0.025172121822834015,
-0.008791935630142689,
0.012906433083117008,
-0.015515180304646492,
0.027881557121872902,
0.06813864409923553,
-0.006329644471406937,
-0.05418871343135834,
-0.08399250358343124,
0.04748835042119026,
0.0364675372838974,
-0.056385550647974014,
-0.004704898223280907,
-0.030005168169736862,
0.017281806096434593,
-0.006860547233372927,
-0.010727900080382824,
0.005565327126532793,
-0.04737851023674011,
0.0071717663668096066,
-0.005318182986229658,
-0.05268753692507744,
0.005629401654005051,
-0.013821783475577831,
0.01711704209446907,
-0.013181038200855255,
-0.023451263085007668,
-0.01638476364314556,
-0.009492178447544575,
-0.0377490296959877,
0.05257769674062729,
-0.004286125767976046,
-0.015295496210455894,
0.008888047188520432,
-0.05173557624220848,
-0.04309467226266861,
0.03635769709944725,
-0.05283399298787117,
0.02887013554573059,
0.035039592534303665,
0.023304807022213936,
0.06118198484182358,
-0.018892820924520493,
0.010691286064684391,
-0.016467144712805748,
-0.006274723447859287,
0.015158194117248058,
0.0699327290058136,
0.014837821014225483,
-0.002153360517695546,
0.0004516679618973285,
-0.02411031536757946,
-0.004334181547164917,
-0.033556725829839706,
-0.04122735932469368,
0.043277740478515625,
-0.07886654883623123,
0.012595213949680328,
0.024915823712944984,
0.02824769727885723,
-0.036778759211301804,
0.03439885005354881,
-0.10515539348125458,
0.056422166526317596,
0.006448640022426844,
-0.039396658539772034,
0.013245112262666225,
-0.009730169549584389,
-0.002338718855753541,
0.022334536537528038,
0.013501410372555256,
0.04298482835292816,
-0.03738288953900337,
-0.009258763864636421,
-0.001462271437048912,
-0.005945197306573391,
0.004544712137430906,
0.03681537136435509,
-0.003098459215834737,
-0.015020891092717648,
0.029309503734111786,
-0.049026139080524445,
0.04360726848244667,
-0.005771280732005835,
0.056275710463523865,
-0.056202482432127,
-0.06682053953409195,
0.04239900782704353,
-0.01080112811177969,
-0.031176816672086716,
0.04606040567159653,
0.04818401858210564,
0.047268666326999664,
0.027442188933491707,
-0.027295732870697975,
-0.01298881508409977,
-0.03644923120737076,
-0.01874636486172676,
0.04012893885374069,
-0.006517291069030762,
-0.0364675372838974,
-0.0050390008836984634,
0.0017929415917024016,
0.0019485510420054197,
-0.03683367744088173,
0.04393679276108742,
-0.017464876174926758,
0.04144704341888428,
-0.003714032005518675,
-0.048659998923540115,
0.008476139977574348,
-0.004947465844452381,
-0.021950090304017067,
-0.010901817120611668,
0.03262307122349739,
-0.0028902171179652214,
-0.01150594837963581,
0.02486090175807476,
0.007958967238664627,
0.06700360774993896,
0.031140202656388283,
-0.009167228825390339,
0.013895011506974697,
-0.032165393233299255,
-0.09812550991773605,
-0.0023524491116404533,
-0.14982447028160095,
0.057264287024736404,
-0.029199661687016487,
0.03157956898212433,
-0.024805981665849686,
-0.03557049483060837,
0.022554220631718636,
-0.01621999964118004,
0.037273045629262924,
-0.04433954879641533,
-0.01999124139547348,
0.08135629445314407,
-0.0035881714429706335,
0.022535914555191994,
-0.03558880463242531,
0.028833521530032158,
-0.0026957052759826183,
-0.0010692430660128593,
-0.020320767536759377,
0.022334536537528038,
0.022664062678813934,
0.0017414531903341413,
0.0017506065778434277,
-0.019954627379775047,
-0.019057584926486015,
0.0016441971529275179,
0.04313128441572189,
0.05162573233246803,
0.009341145865619183,
0.018279537558555603,
-0.04598717764019966,
0.03009670414030552,
-0.009464717470109463,
-0.008906354196369648,
0.02334142103791237,
-0.03011501021683216,
0.03132327273488045,
0.03146972879767418,
-0.040421850979328156,
0.03613801300525665,
0.02597763016819954,
-0.025812866166234016,
0.031048668548464775,
-0.018425993621349335,
-0.059644196182489395,
0.007931506261229515,
0.02059537172317505,
0.014773746952414513,
0.009730169549584389,
0.003718608757480979,
0.01299796812236309,
0.00095997320022434,
0.0042106094770133495,
0.019020970910787582,
0.04931905120611191,
-0.042801760137081146,
0.019954627379775047,
-0.011286264285445213,
-0.0714339017868042,
-0.015689097344875336,
-0.021071353927254677,
-0.005670592654496431,
-0.07798781245946884,
-0.0296024139970541,
-0.035167742520570755,
0.0025149236898869276,
-0.03663230314850807,
0.09805227816104889,
0.07278861850500107,
0.04137381538748741,
0.04393679276108742
]
|
33,786 | bqplot.marks | on_drag | null | def on_drag(self, callback, remove=False):
self._drag_handlers.register_callback(callback, remove=remove)
| (self, callback, remove=False) | [
-0.012598718516528606,
0.052874453365802765,
-0.02119867503643036,
0.03663494065403938,
-0.0186667088419199,
0.055493731051683426,
0.015802966430783272,
0.11063822358846664,
-0.014833834022283554,
0.006604941561818123,
0.03687940910458565,
0.00014637934509664774,
-0.01789838634431362,
-0.07096492499113083,
-0.04763590171933174,
0.009822285734117031,
0.004666677210479975,
0.03218217194080353,
-0.023643333464860916,
-0.03611108660697937,
-0.012528871186077595,
-0.0025406978093087673,
-0.031291618943214417,
-0.03270602971315384,
-0.030680455267429352,
0.020098578184843063,
-0.013305922970175743,
0.0032631815411150455,
0.035936467349529266,
0.028759652748703957,
-0.018544474616646767,
-0.008744017221033573,
-0.0036255146842449903,
-0.03099476732313633,
-0.05521434172987938,
0.06363094598054886,
0.027397628873586655,
0.045226167887449265,
-0.000048565743782091886,
0.01915564015507698,
-0.03286318480968475,
-0.01573311910033226,
0.05664621293544769,
0.018125390633940697,
0.07292065024375916,
0.08682027459144592,
-0.043933991342782974,
-0.03450459614396095,
-0.013637697324156761,
0.06715823709964752,
-0.007080776616930962,
-0.03366642817854881,
-0.009804823435842991,
0.025773677974939346,
-0.0466231144964695,
0.01828254759311676,
0.06324678659439087,
0.01861432194709778,
0.002529784105718136,
-0.004319623112678528,
-0.006971640046685934,
0.03946376219391823,
0.034626830369234085,
-0.06506282091140747,
0.031710702925920486,
-0.0043676430359482765,
0.025406979024410248,
-0.05004563555121422,
0.048648688942193985,
0.002179455943405628,
-0.018474627286195755,
0.024568811058998108,
0.031274158507585526,
0.023049630224704742,
0.08032447099685669,
0.022717855870723724,
0.007220471277832985,
-0.07753057032823563,
0.05524926632642746,
-0.045680176466703415,
0.041000403463840485,
-0.03432998061180115,
0.06153552606701851,
0.13124319911003113,
0.005203628446906805,
-0.032042477279901505,
-0.0028222701512277126,
-0.03782234713435173,
0.0722920224070549,
0.013463078998029232,
-0.045610327273607254,
-0.08095309138298035,
-0.011987553909420967,
0.0064172265119850636,
-0.04554048180580139,
-0.03394581750035286,
-0.0353253036737442,
-0.03473160043358803,
0.05102349817752838,
0.01990649849176407,
0.050779033452272415,
0.0451563224196434,
0.028235796838998795,
-0.004513885825872421,
0.026105452328920364,
-0.02972005307674408,
0.020150965079665184,
-0.03666986525058746,
-0.05909087136387825,
0.0553540363907814,
0.03949868306517601,
-0.008927365764975548,
0.06244354322552681,
0.06003380939364433,
0.0001411953562637791,
0.00027911661891266704,
0.007691940758377314,
-0.012895569205284119,
-0.05441109463572502,
-0.01831747032701969,
-0.006081086117774248,
-0.03485383465886116,
0.005592154338955879,
-0.05874163284897804,
-0.02247338928282261,
-0.015130684711039066,
0.055039722472429276,
0.06859011203050613,
0.05598266050219536,
-0.005439363420009613,
0.03607616201043129,
-0.02160029672086239,
-0.012520140036940575,
-0.06502789258956909,
-0.01618712581694126,
-0.014781448058784008,
0.02680392563343048,
-0.02331155724823475,
-0.0019939239136874676,
-0.028392953798174858,
-0.03399820253252983,
-0.00743874441832304,
-0.011751819401979446,
0.064469113945961,
-0.012511408887803555,
0.039743151515722275,
-0.047740671783685684,
0.01715625822544098,
0.03185039758682251,
0.02968513034284115,
-0.040127310901880264,
0.0004428213578648865,
0.015890276059508324,
-0.01871909387409687,
-0.02935335412621498,
0.028672343119978905,
-0.030034366995096207,
0.02254323661327362,
-0.0382414311170578,
0.049975790083408356,
0.029073964804410934,
-0.04257196933031082,
-0.009691321291029453,
-0.016632404178380966,
-0.013454348780214787,
0.0012015929678454995,
0.039708226919174194,
0.02292739786207676,
-0.04288627952337265,
0.07780995965003967,
0.04941701143980026,
0.007779249921441078,
0.044422924518585205,
0.035430073738098145,
0.04110517352819443,
0.03663494065403938,
0.029912132769823074,
0.004963528364896774,
-0.03474906459450722,
0.04414353519678116,
0.08004508167505264,
-0.01314876601099968,
0.03574438765645027,
0.02937081642448902,
-0.00010845440556295216,
-0.030785225331783295,
0.008547571487724781,
-0.0018815133953467011,
0.038904979825019836,
0.00975243840366602,
0.005504845175892115,
-0.003025264013558626,
-0.008215796202421188,
-0.01992396079003811,
0.06307216733694077,
0.024359267204999924,
0.017636459320783615,
0.058462243527173996,
-0.03483637422323227,
-0.014126629568636417,
-0.027973869815468788,
0.01828254759311676,
0.02467358112335205,
-0.02851518616080284,
0.0030711013823747635,
0.006286262534558773,
0.0006968365632928908,
-0.0051468778401613235,
-0.016614941880106926,
-0.0679265633225441,
0.05022025480866432,
0.020657358691096306,
0.00041089893784374,
-0.0011142836883664131,
0.024516424164175987,
-0.06530728191137314,
-0.07459698617458344,
-0.006958543788641691,
0.04449276998639107,
-0.009700052440166473,
-0.03347434848546982,
0.07871797680854797,
-0.046553269028663635,
-0.027083314955234528,
-0.0049286046996712685,
0.003677900182083249,
0.004214851651340723,
-0.06205938383936882,
0.028567571192979813,
-0.03342196345329285,
-0.007783615496009588,
0.0018116659484803677,
-0.013227344490587711,
-0.009385739453136921,
0.046518344432115555,
-0.011507352814078331,
0.033317193388938904,
-0.052909377962350845,
0.05109334737062454,
-0.013768661767244339,
-0.00931589212268591,
0.02467358112335205,
0.012589987367391586,
0.02853264845907688,
0.03410297632217407,
0.02676900289952755,
-0.06502789258956909,
0.04973132163286209,
-0.03977807238698006,
0.03153608366847038,
-0.001490804716013372,
-0.04463246464729309,
-0.010075482539832592,
0.047775596380233765,
0.0106080686673522,
0.02383541315793991,
-0.00701092928647995,
-0.008333663456141949,
0.0048718536272645,
0.032461561262607574,
0.0075566116720438,
-0.004238862078636885,
0.027275394648313522,
0.07354927062988281,
0.030697915703058243,
-0.043095823377370834,
0.04676280915737152,
0.0049024117179214954,
-0.028742190450429916,
0.030296294018626213,
0.10400272160768509,
0.0007077502668835223,
-0.038904979825019836,
-0.05737961083650589,
0.004723427817225456,
-0.016274435445666313,
-0.03792711719870567,
-0.028724728152155876,
-0.0013347394997254014,
-0.03446967527270317,
0.027729403227567673,
-0.022595621645450592,
0.015706926584243774,
0.02853264845907688,
-0.08661073446273804,
0.04131471738219261,
0.028305644169449806,
0.034137897193431854,
-0.050394874066114426,
-0.02884696051478386,
0.007744326256215572,
-0.008879345841705799,
-0.026105452328920364,
0.03473160043358803,
0.01917310059070587,
0.012162172235548496,
-0.058043159544467926,
0.035080838948488235,
-0.01427505537867546,
0.0518965907394886,
-0.017784884199500084,
-0.0026760271284729242,
-0.039289142936468124,
0.038974829018116,
-0.045261092483997345,
-0.04547063261270523,
0.03408551216125488,
0.014179014600813389,
-0.055458806455135345,
0.00839477963745594,
-0.02462119609117508,
-0.036704789847135544,
-0.06150060519576073,
0.044318150728940964,
0.06122121587395668,
0.03219963610172272,
0.01955726183950901,
0.01704275608062744,
0.01908579282462597,
0.016868138685822487,
-0.0407908596098423,
-0.0020528577733784914,
-0.09932295233011246,
-0.04508647322654724,
0.014152822084724903,
-0.018003158271312714,
-0.05919564142823219,
0.005609616171568632,
-0.028812037780880928,
0.03820650652050972,
-0.03172816336154938,
-0.0013707545585930347,
0.015401343815028667,
-0.0010466191451996565,
0.020465277135372162,
-0.0315011627972126,
0.03185039758682251,
-0.009769899770617485,
0.011393851600587368,
0.03143131360411644,
-0.03701910376548767,
0.07711149007081985,
-0.006290628109127283,
0.003776123048737645,
0.0017898386577144265,
0.020290659740567207,
-0.03143131360411644,
0.046867579221725464,
0.04505154862999916,
0.007657017093151808,
0.024044955149292946,
-0.03893990442156792,
-0.0652025118470192,
0.006543824914842844,
0.018107928335666656,
-0.07075537741184235,
0.003173689590767026,
0.0002677937154658139,
0.028323106467723846,
-0.04410861060023308,
0.019627109169960022,
-0.03328226879239082,
0.04110517352819443,
-0.02589591033756733,
-0.008464626967906952,
-0.013541657477617264,
-0.04725174233317375,
-0.053817395120859146,
-0.003972569014877081,
0.0051381466910243034,
-0.0021707250270992517,
-0.01870163157582283,
0.0391494482755661,
0.011952630244195461,
0.002579987049102783,
-0.06038304418325424,
0.03275841474533081,
0.0327758751809597,
-0.03817158564925194,
0.0021630856208503246,
-0.024359267204999924,
0.0036691692657768726,
-0.02467358112335205,
-0.026978544890880585,
0.02414972521364689,
-0.020709743723273277,
-0.05133781209588051,
0.051687050610780716,
-0.011062076315283775,
-0.0324091762304306,
-0.02765955589711666,
-0.018404779955744743,
-0.042222730815410614,
-0.006037431303411722,
-0.04323551803827286,
-0.03907959908246994,
-0.04428322985768318,
0.023643333464860916,
0.014458403922617435,
0.055842965841293335,
-0.018823863938450813,
0.0077268644236028194,
-0.053363386541604996,
0.0020157513208687305,
0.062233999371528625,
0.029021579772233963,
-0.042292580008506775,
0.031274158507585526,
0.026140375062823296,
-0.032933030277490616,
0.02551174908876419,
-0.002669478999450803,
0.023154400289058685,
-0.033369578421115875,
-0.007691940758377314,
0.023049630224704742,
-0.08241988718509674,
0.027921482920646667,
-0.060138579457998276,
-0.04026700556278229,
-0.0125637948513031,
0.028672343119978905,
-0.038835134357213974,
0.0313265435397625,
-0.027065852656960487,
0.002154354704543948,
0.03995269164443016,
0.07438744604587555,
-0.03649524599313736,
0.016649864614009857,
0.02938827872276306,
0.061779994517564774,
0.011935167945921421,
-0.015829158946871758,
0.002479581395164132,
0.04201319068670273,
0.009080157615244389,
-0.005186166614294052,
-0.039324067533016205,
0.022857550531625748,
0.02504028007388115,
0.03604124113917351,
-0.02463865838944912,
-0.05490002781152725,
0.03385850787162781,
0.005980680696666241,
-0.07760041952133179,
-0.006504535675048828,
0.0302264466881752,
-0.044387999922037125,
-0.0008981934515759349,
0.0035360227338969707,
0.046029411256313324,
0.0382414311170578,
0.035534847527742386,
-0.07522561401128769,
-0.06768209487199783,
-0.0690091922879219,
-0.03604124113917351,
0.002940137404948473,
-0.008783305995166302,
0.011577200144529343,
-0.06377064436674118,
-0.0697425901889801,
0.017252298071980476,
0.04120994359254837,
0.018946098163723946,
0.016230780631303787,
-0.017522957175970078,
0.052944302558898926,
0.09038248658180237,
-0.019731881096959114,
-0.027467476204037666,
-0.021425679326057434,
0.004470231477171183,
0.001190679264254868,
0.06377064436674118,
0.05364277586340904,
-0.010922381654381752,
0.005526672583073378,
0.04026700556278229,
-0.028358029201626778,
-0.051267966628074646,
-0.03172816336154938,
-0.023870335891842842,
0.05992903932929039,
-0.011908975429832935,
0.007565342355519533,
0.015672001987695694,
-0.007687575649470091,
-0.01692052371799946,
-0.06694869697093964,
-0.04966147616505623,
0.006871234625577927,
0.08598210662603378,
-0.059719495475292206,
-0.036320630460977554,
-0.06527236104011536,
0.06928858160972595,
-0.03862559050321579,
-0.02034304477274418,
-0.0010482561774551868,
0.0009091070969589055,
-0.015034644864499569,
-0.003599321935325861,
-0.03981299698352814,
0.023241709917783737,
0.029178736731410027,
-0.09150004386901855,
-0.03694925457239151,
-0.023538561537861824,
0.0477057509124279,
0.0004286336188670248,
0.05490002781152725,
0.03977807238698006,
-0.034993529319763184,
0.03216471150517464,
0.022001920267939568,
0.006098547950387001,
-0.056331899017095566,
0.01588154397904873,
-0.020587511360645294,
-0.026018142700195312,
-0.03611108660697937,
0.012816991657018661,
-0.00786655955016613,
-0.06212922930717468,
0.0011884965933859348,
0.022735316306352615,
-0.046099260449409485,
0.04578494653105736,
0.036739714443683624,
0.006037431303411722,
-0.03810173645615578,
-0.025791138410568237,
0.03869543969631195,
0.019277872517704964,
-0.03771757706999779,
-0.0755748450756073,
-0.015375151298940182,
0.022159075364470482,
-0.009010310284793377,
0.030086752027273178,
-0.012878107838332653,
-0.019662033766508102,
0.016265705227851868,
-0.0009674951434135437,
-0.06785671412944794,
0.05091872811317444,
-0.010319948196411133,
-0.02205430530011654,
-0.0053345924243330956,
0.024952970445156097,
-0.02938827872276306,
0.017985695973038673,
0.028358029201626778,
0.0022372982930392027,
-0.023556023836135864,
0.03481891006231308,
-0.0075391498394310474,
-0.035901546478271484,
-0.009743707254529,
-0.004145004320889711,
0.02423703484237194,
0.032950494438409805,
0.035430073738098145,
0.013707545585930347,
-0.006866869051009417,
0.02467358112335205,
-0.014606829732656479,
0.002250394783914089,
0.002022299449890852,
0.008355490863323212,
-0.03391089662909508,
-0.03991776704788208,
0.032496485859155655,
0.07899736613035202,
0.0007312145899049938,
-0.027310319244861603,
-0.10512027889490128,
-0.00285937637090683,
-0.0025210531894117594,
0.030383603647351265,
0.046029411256313324,
-0.021320907399058342,
-0.01314876601099968,
0.04103532433509827,
0.029196197167038918,
-0.04131471738219261,
-0.05269983410835266,
0.03195516765117645,
-0.0159339290112257,
-0.03324734419584274,
-0.027502398937940598,
0.020255735144019127,
0.004081705119460821,
-0.018806403502821922,
0.014109167270362377,
-0.0812324807047844,
0.019696956500411034,
-0.008482089266180992,
-0.0006471794913522899,
-0.004701600875705481,
-0.00956035777926445,
-0.00858686026185751,
-0.011839128099381924,
-0.0662851482629776,
-0.04155918210744858,
-0.022421004250645638,
-0.003568763844668865,
-0.03137892857193947,
0.021425679326057434,
-0.012467754073441029,
-0.03555230796337128,
0.03525545820593834,
0.02297978289425373,
0.03485383465886116,
-0.04239735007286072,
0.033352117985486984,
0.0551794171333313,
0.021146290004253387,
0.005954487714916468,
-0.014353632926940918,
-0.046972353011369705,
-0.007526053581386805,
-0.047775596380233765,
-0.01868416927754879,
0.032898109406232834,
-0.006024335045367479,
0.04204811155796051,
-0.019714418798685074,
-0.03342196345329285,
0.02119867503643036,
-0.008307470940053463,
0.03523799404501915,
0.020133502781391144,
-0.05364277586340904,
-0.00669661583378911,
0.003568763844668865,
-0.05531911179423332,
0.01826508529484272,
-0.019260410219430923,
0.005627078469842672,
-0.009394470602273941,
0.01552357617765665,
0.0331425741314888,
0.023608408868312836,
0.019242947921156883,
0.04033685103058815,
-0.03977807238698006,
-0.006102913524955511,
0.024987895041704178,
-0.058392394334077835,
0.031658317893743515,
0.01211851742118597,
0.027432551607489586,
-0.01469413936138153,
0.00817650742828846,
-0.00584098557010293,
0.030034366995096207,
-0.021478064358234406,
0.00022973235172685236,
0.009961980395019054,
0.054271399974823,
0.01680702157318592,
-0.02502281777560711,
0.024446576833724976,
-0.018544474616646767,
-0.048229604959487915,
-0.026943620294332504,
-0.024900585412979126,
-0.07697179168462753,
-0.03562215715646744,
-0.04320059344172478,
0.04159410670399666,
-0.05318876728415489,
0.023713180795311928,
0.02247338928282261,
0.024760890752077103,
0.049102697521448135,
-0.048578839749097824,
0.03101222962141037,
0.008303104899823666,
-0.005784234963357449,
0.007486764341592789,
0.017706306651234627,
-0.0007388541707769036,
0.0033570388332009315,
0.05053456872701645,
0.032444100826978683,
0.013209883123636246,
0.0055441344156861305,
0.006473977584391832,
0.02470850571990013,
-0.057135142385959625,
-0.02208922803401947,
0.018387317657470703,
-0.07313019037246704,
0.04278150945901871,
-0.007299049291759729,
0.04847406968474388,
-0.05060441419482231,
-0.0041275424882769585,
-0.0028550110291689634,
0.009935787878930569,
0.004236679058521986,
-0.044318150728940964,
-0.05734468623995781,
0.0375080332159996,
0.023521099239587784,
0.0019666398875415325,
-0.03855574503540993,
0.00007148441363824531,
0.025826063007116318,
-0.05409678444266319,
-0.005662002135068178,
-0.001092456397600472,
0.009237313643097878,
0.02722300961613655,
-0.027083314955234528,
-0.02968513034284115,
-0.035534847527742386,
0.025284744799137115,
0.044353075325489044,
-0.009691321291029453,
0.006124740932136774,
0.039219293743371964,
-0.0755748450756073,
-0.018893711268901825,
0.023887798190116882,
0.032444100826978683,
0.026087990030646324,
-0.038904979825019836,
0.04976624622941017,
0.0008550845086574554,
-0.03136146813631058,
0.007766153663396835,
0.0628277063369751,
-0.013917087577283382,
-0.006255704443901777,
-0.016449054703116417,
-0.052455369383096695,
0.07620347291231155,
-0.03426013141870499,
0.06621529906988144,
0.0040751569904387,
-0.006207684520632029,
0.029597820714116096,
-0.04969640076160431,
0.05399201065301895,
0.02287501096725464,
0.029108889400959015,
-0.027467476204037666,
0.04882330819964409,
-0.04365460202097893,
0.01443221140652895,
-0.045715101063251495,
0.002750240033492446,
-0.02374810352921486,
-0.057170066982507706,
-0.01383850909769535,
0.01529657281935215,
-0.039254218339920044,
-0.07718133926391602,
0.08381683379411697,
0.03270602971315384,
0.016003776341676712,
0.03789219632744789
]
|
33,787 | bqplot.marks | on_drag_end | null | def on_drag_end(self, callback, remove=False):
self._drag_end_handlers.register_callback(callback, remove=remove)
| (self, callback, remove=False) | [
-0.007079910486936569,
0.0755423828959465,
-0.04547245055437088,
0.03665100783109665,
-0.022053614258766174,
0.02838965319097042,
-0.0074693490751087666,
0.09983636438846588,
-0.0024941586889326572,
-0.017677897587418556,
0.039241429418325424,
-0.00955656636506319,
-0.021213477477431297,
-0.0733020156621933,
-0.01434360072016716,
0.019638217985630035,
-0.018185479566454887,
0.020303327590227127,
-0.029737373813986778,
-0.02168605476617813,
-0.024539021775126457,
-0.009320277720689774,
-0.00998538639396429,
-0.04410722851753235,
-0.02172105945646763,
-0.002421959536150098,
0.0030301841907203197,
-0.0003298196825198829,
0.011823187582194805,
0.048938021063804626,
-0.025729216635227203,
-0.036721017211675644,
-0.025449171662330627,
-0.02726946957409382,
-0.025326650589704514,
0.06896129995584488,
0.021738562732934952,
0.05632423236966133,
0.024031437933444977,
0.040466632694005966,
-0.0446673221886158,
-0.007250563241541386,
0.0349707305431366,
0.0446673221886158,
0.08282357454299927,
0.083663709461689,
-0.0492180660367012,
-0.040046561509370804,
0.0004014720325358212,
0.054013852030038834,
0.001450550276786089,
-0.029737373813986778,
-0.00063338503241539,
0.027041932567954063,
-0.029352311044931412,
0.04281201586127281,
0.03630094975233078,
-0.004071604926139116,
0.008051319047808647,
-0.018693063408136368,
-0.0036734144669026136,
0.007250563241541386,
0.03885636851191521,
-0.057899489998817444,
0.03255533427000046,
0.030840054154396057,
0.019620714709162712,
-0.03997655212879181,
0.06175012141466141,
0.03075253963470459,
-0.010991801507771015,
0.02691941149532795,
0.0189030971378088,
0.024188963696360588,
0.05292867496609688,
0.0052639879286289215,
-0.011149327270686626,
-0.04592752829194069,
0.0346381776034832,
-0.032695356756448746,
0.024766558781266212,
-0.005259612109512091,
0.06896129995584488,
0.11432873457670212,
0.026201793923974037,
-0.030122436583042145,
-0.01661897450685501,
-0.033850546926259995,
0.00847138836979866,
0.008563278242945671,
-0.036616001278162,
-0.09444548189640045,
-0.016198905184864998,
0.008663919754326344,
-0.016426442191004753,
-0.05852959305047989,
-0.047817837446928024,
-0.03273036330938339,
0.020898424088954926,
-0.00982786063104868,
0.05303369089961052,
0.018185479566454887,
0.05670929327607155,
0.002360699465498328,
0.055029019713401794,
-0.00843200646340847,
0.021808573976159096,
-0.04522741213440895,
-0.06913632899522781,
0.040466632694005966,
0.04330209642648697,
-0.007031777407974005,
0.06441055238246918,
0.016820257529616356,
-0.007749394979327917,
0.003299290779978037,
0.009031480178236961,
0.01941068097949028,
-0.028617190197110176,
-0.014116063714027405,
0.010125409811735153,
-0.02753201127052307,
-0.022823739796876907,
-0.06448056548833847,
-0.021493522450327873,
-0.03115510568022728,
0.03791121393442154,
0.06850622594356537,
0.03504074364900589,
-0.008650792762637138,
0.013984791934490204,
0.005158970598131418,
-0.027111943811178207,
-0.059159696102142334,
-0.026306811720132828,
0.002717320341616869,
0.010431709699332714,
-0.023873912170529366,
0.002927354769781232,
-0.013319683261215687,
-0.024328988045454025,
0.005539658013731241,
0.013748503290116787,
0.04326708987355232,
-0.0009336686343885958,
0.062240201979875565,
-0.03735112026333809,
0.028757212683558464,
0.01570882461965084,
0.022963764145970345,
-0.05128340423107147,
-0.005268363282084465,
0.012602065689861774,
-0.00004368880036054179,
-0.0178791806101799,
0.013267174363136292,
-0.02802209183573723,
0.045052383095026016,
-0.05166846886277199,
0.03388555347919464,
0.01694277673959732,
-0.05453893914818764,
-0.022263647988438606,
-0.020653385668992996,
-0.0036559116560965776,
0.024819066748023033,
0.038541316986083984,
0.0480978824198246,
-0.03731611743569374,
0.06570576876401901,
0.035163260996341705,
0.022473683580756187,
0.027742046862840652,
0.028564682230353355,
0.020740898326039314,
0.05065330117940903,
0.04179684817790985,
0.006567951291799545,
-0.03115510568022728,
0.052508603781461716,
0.0636054277420044,
-0.030052425339818,
0.04018658772110939,
0.022858746349811554,
0.00828323233872652,
-0.024994095787405968,
-0.023313820362091064,
0.008099452592432499,
-0.0032796000596135855,
-0.001656208885833621,
-0.02439899928867817,
-0.00927652046084404,
-0.01431734673678875,
-0.01981324702501297,
0.049638133496046066,
0.02107345312833786,
0.040466632694005966,
0.09325528144836426,
-0.021265985444188118,
-0.035163260996341705,
-0.038541316986083984,
0.001373975188471377,
0.027707040309906006,
-0.04774782434105873,
0.00781503040343523,
0.013888525776565075,
0.002511661732569337,
-0.00506708025932312,
-0.037946220487356186,
-0.06423553079366684,
0.02777705155313015,
0.026131782680749893,
-0.016120141372084618,
0.003380241570994258,
0.03801622986793518,
-0.08758435398340225,
-0.0756123885512352,
-0.0019581334199756384,
0.037981223315000534,
-0.007346828933805227,
-0.06399048864841461,
0.042426954954862595,
-0.018167978152632713,
-0.02576422318816185,
-0.02217613346874714,
-0.0041044228710234165,
-0.00862016249448061,
-0.051948513835668564,
0.05023323372006416,
-0.020898424088954926,
-0.04018658772110939,
0.01336344052106142,
-0.032642848789691925,
-0.003684353781864047,
0.053523771464824677,
0.03749114274978638,
0.03742113336920738,
-0.046662647277116776,
0.020443350076675415,
0.012181996367871761,
-0.026044268161058426,
-0.010991801507771015,
-0.020863419398665428,
0.003640596754848957,
0.021441014483571053,
0.036616001278162,
-0.007771273609250784,
0.049638133496046066,
-0.013713497668504715,
0.04512239620089531,
-0.0013531905133277178,
-0.03273036330938339,
0.017817920073866844,
0.024171462282538414,
0.018535537645220757,
0.02420646697282791,
-0.010466715320944786,
-0.018483029678463936,
0.04855295643210411,
0.014361103996634483,
0.038891375064849854,
0.005898466799408197,
-0.0029032882302999496,
0.08667420595884323,
0.022193636745214462,
-0.0395214781165123,
0.06045490875840187,
-0.014238583855330944,
-0.020285824313759804,
0.0401165746152401,
0.10053647309541702,
-0.03105008788406849,
-0.05418888106942177,
-0.07253188639879227,
-0.005355877801775932,
0.025186628103256226,
-0.03185522183775902,
-0.04802786931395531,
-0.030034922063350677,
-0.040606655180454254,
0.04669765383005142,
-0.010317941196262836,
0.012523302808403969,
0.010589235462248325,
-0.06371044367551804,
0.05485399067401886,
0.04102672263979912,
0.024486513808369637,
-0.047362763434648514,
-0.016321424394845963,
-0.0035399552434682846,
-0.013354688882827759,
-0.023173797875642776,
0.06343039870262146,
0.024591529741883278,
-0.006134755443781614,
-0.03248532488942146,
0.0031439526937901974,
0.0045201159082353115,
0.03700106218457222,
-0.03010493330657482,
-0.013801012188196182,
-0.029212286695837975,
0.02091592736542225,
-0.060524918138980865,
-0.039346449077129364,
0.05831955745816231,
0.011438124813139439,
-0.024924084544181824,
0.013582225888967514,
-0.008143209852278233,
-0.03616092726588249,
-0.0687512680888176,
0.03679103031754494,
0.06003483757376671,
0.05968478322029114,
0.025326650589704514,
-0.009644080884754658,
0.009819108992815018,
0.014203578233718872,
-0.07946301996707916,
-0.01422108057886362,
-0.05026823654770851,
-0.04704771190881729,
0.02112596295773983,
-0.018640555441379547,
-0.07687260210514069,
0.05026823654770851,
0.006887378636747599,
0.012584562413394451,
-0.023103786632418633,
-0.03906640410423279,
0.03227528929710388,
0.019620714709162712,
0.050898343324661255,
-0.04830791801214218,
0.05292867496609688,
-0.019603213295340538,
0.034655679017305374,
0.02933480776846409,
-0.05810952186584473,
0.06311534345149994,
-0.006226645316928625,
0.002165979938581586,
0.028477167710661888,
0.012470793910324574,
-0.03616092726588249,
0.01825549267232418,
0.06315034627914429,
0.022106122225522995,
0.011788181960582733,
-0.04592752829194069,
-0.0692763552069664,
-0.008493266999721527,
0.012033222243189812,
-0.07267191261053085,
0.020635882392525673,
0.005417137872427702,
0.031592678278684616,
-0.05474897101521492,
0.003769680391997099,
-0.01694277673959732,
0.04214690625667572,
-0.003262097015976906,
0.003218339988961816,
0.011613152921199799,
-0.06238022446632385,
-0.025834234431385994,
0.030419984832406044,
0.012059476226568222,
-0.003351799212396145,
-0.018272994086146355,
0.05649925768375397,
0.01756412908434868,
0.011236841790378094,
-0.06647589802742004,
0.025641702115535736,
0.03185522183775902,
-0.020600875839591026,
-0.017301585525274277,
-0.03357050195336342,
-0.008291983976960182,
-0.06770109385251999,
-0.031575173139572144,
0.025641702115535736,
-0.0033693022560328245,
-0.048517949879169464,
0.037281110882759094,
-0.037981223315000534,
-0.018868092447519302,
-0.008221972733736038,
-0.012864608317613602,
-0.036686010658741,
-0.018763074651360512,
-0.049323081970214844,
-0.004161307122558355,
-0.057269386947155,
0.010554229840636253,
0.023278815671801567,
0.060279879719018936,
-0.04386219009757042,
0.025134118273854256,
-0.05299868434667587,
0.013827266171574593,
0.0755423828959465,
-0.000025399671358172782,
-0.035215772688388824,
0.002861719112843275,
0.029912402853369713,
-0.035320788621902466,
0.037526149302721024,
-0.031435150653123856,
0.00445010419934988,
-0.01815047487616539,
-0.014387357980012894,
0.023733889684081078,
-0.08639416098594666,
0.005342750810086727,
-0.02198360301554203,
-0.020810911431908607,
-0.027304474264383316,
0.04834292456507683,
-0.012392031028866768,
0.033202942460775375,
-0.04442228004336357,
-0.02726946957409382,
0.017581630498170853,
0.06889128684997559,
-0.054013852030038834,
-0.00203799013979733,
0.019690727815032005,
0.03535579517483711,
-0.020985938608646393,
0.00930277444422245,
0.013862271793186665,
0.03826127201318741,
0.01576133258640766,
-0.02107345312833786,
-0.029562344774603844,
0.007626874838024378,
-0.005080207716673613,
0.031890224665403366,
-0.027812058106064796,
-0.03850631043314934,
0.05523905158042908,
-0.02777705155313015,
-0.044947367161512375,
-0.027812058106064796,
0.018833085894584656,
-0.029212286695837975,
-0.017301585525274277,
-0.006900506094098091,
0.027199458330869675,
0.04428225755691528,
0.027041932567954063,
-0.07190178334712982,
-0.037281110882759094,
-0.06595081090927124,
-0.02051336131989956,
-0.011245593428611755,
-0.024574026465415955,
0.02828463539481163,
-0.054468926042318344,
-0.04053664207458496,
0.036370959132909775,
0.010177917778491974,
0.03140014782547951,
0.009197757579386234,
-0.015078721567988396,
0.08205344527959824,
0.06665091961622238,
-0.01560380682349205,
-0.031120100989937782,
-0.02445150725543499,
0.03129512816667557,
-0.0006579984910786152,
0.0669659748673439,
0.0589846670627594,
0.0053690047934651375,
0.017607886344194412,
0.04547245055437088,
-0.017205320298671722,
-0.0561492033302784,
-0.03707107529044151,
-0.030822550877928734,
0.0583895705640316,
-0.005631547886878252,
0.004351650830358267,
0.011691915802657604,
0.005045201629400253,
-0.01091303862631321,
-0.09549564868211746,
-0.05660427734255791,
0.016102638095617294,
0.08163338154554367,
-0.09451548755168915,
-0.014527380466461182,
-0.06626585870981216,
0.0630103275179863,
-0.05478397756814957,
-0.006541697308421135,
-0.0005748598487116396,
0.014571137726306915,
-0.024416500702500343,
-0.017100302502512932,
-0.052403587847948074,
0.02005828730762005,
0.04109673574566841,
-0.07890293002128601,
-0.022753728553652763,
-0.004721398930996656,
0.03997655212879181,
0.014886189252138138,
0.04022159054875374,
0.027462000027298927,
-0.019393177703022957,
0.049638133496046066,
0.020338332280516624,
0.057269386947155,
-0.03217027336359024,
-0.01648770272731781,
0.02369888313114643,
-0.004769531544297934,
-0.015087472274899483,
0.012873359955847263,
-0.0019668848253786564,
-0.07456222176551819,
0.019393177703022957,
0.009320277720689774,
-0.034200605005025864,
0.03812124580144882,
0.0340430773794651,
0.02415395900607109,
-0.04547245055437088,
-0.023768896237015724,
0.03962649405002594,
0.005307744722813368,
-0.038086242973804474,
-0.09423544257879257,
-0.027111943811178207,
0.022613706067204475,
-0.0070186504162848,
0.030682528391480446,
-0.03283538296818733,
-0.040466632694005966,
0.02943982556462288,
0.035320788621902466,
-0.0698714479804039,
0.08121331036090851,
0.006283529568463564,
-0.010344195179641247,
0.0231913011521101,
0.05565912276506424,
-0.0140373008325696,
-0.0033321084920316935,
0.04032661020755768,
-0.00998538639396429,
-0.00837949849665165,
0.028967248275876045,
-0.02364637516438961,
-0.04214690625667572,
0.01149063277989626,
0.004927057307213545,
0.019288161769509315,
0.038191258907318115,
0.028914738446474075,
-0.00016655072977300733,
-0.011035558767616749,
0.009311526082456112,
0.001988763455301523,
-0.02933480776846409,
0.012260759249329567,
0.004830791614949703,
-0.08149335533380508,
-0.0030192448757588863,
0.029212286695837975,
0.06560075283050537,
-0.012873359955847263,
0.0014439866645261645,
-0.11775930225849152,
0.004541994538158178,
-0.0049183061346411705,
0.04659263417124748,
0.016881516203284264,
-0.01991826482117176,
0.0014275776920840144,
0.026306811720132828,
0.030717534944415092,
-0.04351213201880455,
-0.011306853033602238,
0.037841200828552246,
0.012243256904184818,
-0.03654598817229271,
-0.04760780185461044,
0.029282299801707268,
0.01624266244471073,
-0.02222864329814911,
0.043687161058187485,
-0.0801631361246109,
0.02208862081170082,
-0.008291983976960182,
0.018378011882305145,
-0.008882706053555012,
0.004406346939504147,
0.005272739101201296,
-0.00661608437076211,
-0.06297531723976135,
-0.015201241709291935,
-0.019603213295340538,
-0.0023825778625905514,
-0.03252033144235611,
0.018588045611977577,
0.0018596798181533813,
-0.03626594319939613,
0.023331323638558388,
0.008760185912251472,
0.03101508319377899,
-0.027006926015019417,
-0.0007116009946912527,
0.08289358764886856,
0.01750286854803562,
0.03756115585565567,
-0.002378202276304364,
-0.031487658619880676,
-0.02455652505159378,
-0.02798708714544773,
-0.03248532488942146,
0.048727985471487045,
-0.007154297549277544,
0.04326708987355232,
-0.05299868434667587,
-0.012199499644339085,
-0.010046646930277348,
-0.022963764145970345,
0.02606177143752575,
0.0254666730761528,
-0.03598589822649956,
-0.02061837911605835,
0.025134118273854256,
-0.07827282696962357,
0.016478950157761574,
0.005933472421020269,
0.004957687575370073,
-0.016697736456990242,
0.010072900913655758,
0.041866861283779144,
0.021913591772317886,
0.011543141677975655,
0.004848294425755739,
-0.06003483757376671,
0.022613706067204475,
0.020495859906077385,
-0.04417724162340164,
0.0036384088452905416,
0.017441608011722565,
0.019078126177191734,
0.012287013232707977,
0.004563873168081045,
-0.008961468935012817,
0.047572795301675797,
-0.008663919754326344,
-0.018080463632941246,
-0.003432750003412366,
0.01584884710609913,
0.01036169845610857,
-0.007320574950426817,
0.00491393031552434,
0.017117805778980255,
-0.026236800476908684,
-0.05404885858297348,
-0.025134118273854256,
-0.08331365138292313,
-0.037526149302721024,
-0.024031437933444977,
0.00231913011521101,
-0.049988191574811935,
-0.0020904988050460815,
0.011158078908920288,
0.028704704716801643,
0.03948647156357765,
-0.00572343822568655,
0.009950380772352219,
-0.022316157817840576,
-0.003953460603952408,
0.02999991737306118,
0.047257743775844574,
-0.0018006075406447053,
0.014046051539480686,
0.057654447853565216,
0.0036274695303291082,
0.010011640377342701,
-0.014448617585003376,
-0.015393773093819618,
0.008532647974789143,
-0.03871634602546692,
-0.02611427940428257,
0.0076006208546459675,
-0.07137669622898102,
0.010956795886158943,
-0.012777093797922134,
0.025781724601984024,
-0.03488321602344513,
0.00717180036008358,
-0.008681423030793667,
0.026534348726272583,
0.019533202052116394,
-0.054924000054597855,
-0.03766617178916931,
0.019428184255957603,
0.0349707305431366,
-0.020688390359282494,
-0.03316793590784073,
-0.018588045611977577,
0.02632431499660015,
-0.06371044367551804,
-0.013337185606360435,
0.0056796809658408165,
0.006187263876199722,
0.018378011882305145,
-0.03444564342498779,
-0.0280746016651392,
-0.034918222576379776,
0.04606755077838898,
0.01505246665328741,
-0.013547220267355442,
-0.009442797861993313,
0.025851735845208168,
-0.060629937797784805,
-0.008633289486169815,
0.0346381776034832,
-0.006756107322871685,
0.017117805778980255,
-0.00942529458552599,
0.05334874242544174,
-0.017599133774638176,
-0.0401165746152401,
0.01162190455943346,
0.05597417429089546,
-0.026044268161058426,
-0.007793152239173651,
-0.012059476226568222,
-0.05187850072979927,
0.09773601591587067,
-0.023768896237015724,
0.08877454698085785,
0.00795067846775055,
-0.010352946817874908,
0.01051047258079052,
-0.049428101629018784,
0.04260198026895523,
0.03626594319939613,
0.03906640410423279,
-0.020705893635749817,
0.06864625215530396,
-0.032800376415252686,
0.010151663795113564,
-0.012111985124647617,
0.0009238232742063701,
-0.04274200648069382,
-0.05201852694153786,
0.004708271473646164,
0.005430264864116907,
-0.012847105041146278,
-0.09423544257879257,
0.07659254968166351,
0.04487735405564308,
-0.0011278410675004125,
0.03763116896152496
]
|
33,788 | bqplot.marks | on_drag_start | null | def on_drag_start(self, callback, remove=False):
self._drag_start_handlers.register_callback(callback, remove=remove)
| (self, callback, remove=False) | [
-0.02148246206343174,
0.08060801774263382,
-0.011211326345801353,
0.014058507047593594,
-0.005126698408275843,
0.0678711012005806,
0.03806883841753006,
0.11601594090461731,
-0.034999918192625046,
0.00005235213757259771,
0.029731303453445435,
0.016932295635342598,
-0.009011635556817055,
-0.06975147873163223,
-0.04207795485854149,
-0.00371419545263052,
-0.002911485731601715,
0.033403366804122925,
-0.050912193953990936,
-0.02628985047340393,
-0.01569940522313118,
0.0233451034873724,
-0.006825250107795,
-0.02561575174331665,
-0.025899583473801613,
0.02307901345193386,
-0.023061273619532585,
-0.012000732123851776,
0.01794344373047352,
0.019690779969096184,
0.016089672222733498,
0.0059294081293046474,
-0.010457400232553482,
-0.033527541905641556,
-0.036436811089515686,
0.04945756122469902,
0.04076523333787918,
0.04395833611488342,
0.00996069610118866,
0.027709007263183594,
-0.031735859811306,
-0.023948244750499725,
0.042432744055986404,
0.02992643602192402,
0.054460082203149796,
0.06680673360824585,
-0.019265033304691315,
-0.030440879985690117,
0.0048428671434521675,
0.0601012259721756,
0.0039026769809424877,
-0.03987826406955719,
-0.00007421461486956105,
0.018502237275242805,
-0.07251883298158646,
0.03700447455048561,
0.05474391579627991,
-0.006980469916015863,
-0.0032840140629559755,
0.012524045072495937,
0.003343884600326419,
0.049776870757341385,
0.05055740475654602,
-0.06545853614807129,
0.030103830620646477,
-0.016932295635342598,
0.029358774423599243,
-0.05775962024927139,
0.03547888249158859,
0.011832207441329956,
-0.007113515865057707,
0.02442721091210842,
0.014510862529277802,
0.021890470758080482,
0.07063845545053482,
0.035390183329582214,
-0.009313206188380718,
-0.08394303172826767,
0.04296492412686348,
-0.05740483105182648,
0.011237936094403267,
-0.016382373869419098,
0.03760761395096779,
0.12978175282478333,
0.026059238240122795,
-0.01684359833598137,
-0.01208942849189043,
-0.023061273619532585,
0.04395833611488342,
-0.0009690169827081263,
-0.0556308850646019,
-0.04661925137042999,
-0.017916835844516754,
0.01878606714308262,
-0.014714865945279598,
-0.026343069970607758,
-0.024036942049860954,
-0.048889897763729095,
0.023433800786733627,
0.020648708567023277,
0.048641547560691833,
0.02882659062743187,
0.025810886174440384,
-0.011113760061562061,
0.03767857328057289,
-0.026573682203888893,
0.027034908533096313,
-0.0389912910759449,
-0.06545853614807129,
0.06329432874917984,
0.03271152824163437,
-0.03072471171617508,
0.06737439334392548,
0.0568726472556591,
-0.005024696700274944,
-0.011512896977365017,
0.010031653568148613,
0.007774310186505318,
-0.04651281237602234,
-0.016479941084980965,
0.00725986622273922,
-0.03356302157044411,
-0.011317763477563858,
-0.05747578665614128,
-0.02050679363310337,
-0.023309625685214996,
0.05595019832253456,
0.07191569358110428,
0.07443469762802124,
-0.02160663902759552,
0.047328829765319824,
-0.0125151751562953,
-0.03544340282678604,
-0.05974643677473068,
-0.02730100043118,
-0.01937146857380867,
0.03223256394267082,
-0.015380095690488815,
0.0015799188986420631,
-0.003184229601174593,
-0.0323212631046772,
-0.010954104363918304,
-0.006643420550972223,
0.05495678633451462,
-0.035674016922712326,
0.05162177234888077,
-0.03132785111665726,
0.038884855806827545,
0.03345658630132675,
0.04214891046285629,
-0.021500201895833015,
-0.019761737436056137,
0.012976400554180145,
-0.02102123759686947,
-0.025420619174838066,
0.0005066827870905399,
-0.03512409329414368,
0.025420619174838066,
-0.03345658630132675,
0.0455903634428978,
0.0177749190479517,
-0.04952852055430412,
-0.017783788964152336,
-0.028933027759194374,
-0.0175531767308712,
0.0078009190037846565,
0.01704760268330574,
0.028595978394150734,
-0.040623318403959274,
0.0678001418709755,
0.06510374695062637,
0.03803336247801781,
0.06510374695062637,
0.02313223108649254,
0.04190056025981903,
0.02329188585281372,
0.03531922772526741,
-0.000028739972549374215,
-0.04410025104880333,
0.0710996761918068,
0.07507331669330597,
-0.004940434359014034,
0.02806379459798336,
0.014643908478319645,
0.0038760679308325052,
-0.002638741862028837,
0.008031532168388367,
0.006177760194987059,
0.047541700303554535,
0.009233378805220127,
0.01649768091738224,
-0.012080559507012367,
-0.01611628197133541,
-0.021074455231428146,
0.042432744055986404,
0.046832125633955,
0.03455642983317375,
0.038175277411937714,
-0.04324875771999359,
-0.0189102441072464,
-0.023735372349619865,
0.025331921875476837,
0.018590934574604034,
-0.036401331424713135,
0.02472878061234951,
0.018085360527038574,
-0.007787614595144987,
0.003652107436209917,
-0.0077477009035646915,
-0.053111884742975235,
0.02258230745792389,
0.0007472739671356976,
0.0003292883629910648,
0.006882903166115284,
0.007929529994726181,
-0.11225517839193344,
-0.06804849207401276,
-0.0012728049186989665,
0.0568726472556591,
-0.025331921875476837,
-0.03446773439645767,
0.0656004548072815,
-0.03592236712574959,
-0.03767857328057289,
-0.009162421338260174,
0.0040534622967243195,
0.00021536789427045733,
-0.07720204442739487,
-0.008869720622897148,
-0.03675612062215805,
-0.01080331951379776,
-0.0511605478823185,
-0.03583367168903351,
-0.01709195040166378,
0.049776870757341385,
0.010812189429998398,
0.07294458150863647,
-0.03877841681241989,
0.021553421393036842,
-0.022298477590084076,
-0.02515452727675438,
0.03159394487738609,
0.028294408693909645,
-0.00143467728048563,
0.006301936227828264,
0.040658798068761826,
-0.06258475035429001,
0.024746520444750786,
-0.03902677074074745,
0.04917373135685921,
0.009756692685186863,
-0.02469330094754696,
-0.002632089424878359,
0.0411200225353241,
0.012595003470778465,
0.017109690234065056,
0.0018182926578447223,
-0.004379424266517162,
0.0014901129761710763,
0.01763300411403179,
-0.004308466799557209,
-0.0020755145233124495,
0.026822034269571304,
0.07195117324590683,
0.03696899488568306,
-0.029766781255602837,
0.03959443047642708,
0.008514931425452232,
-0.02362893521785736,
0.02659142203629017,
0.12190543860197067,
-0.006208804436028004,
-0.01794344373047352,
-0.05105411261320114,
0.009863128885626793,
-0.029305556789040565,
-0.07386703044176102,
-0.03345658630132675,
-0.011548375710844994,
-0.010856538079679012,
0.036436811089515686,
-0.009818780235946178,
-0.001106497598811984,
0.01633802428841591,
-0.08550410717725754,
0.027354218065738678,
0.049563996493816376,
0.038671981543302536,
-0.060207661241292953,
-0.031381070613861084,
-0.013535193167626858,
0.03313727676868439,
-0.0189102441072464,
0.006248718127608299,
0.01063479483127594,
0.013171534985303879,
-0.03984278440475464,
0.028205711394548416,
-0.03547888249158859,
0.05456652119755745,
-0.004944869317114353,
-0.02135828696191311,
-0.06740987300872803,
0.03223256394267082,
-0.058682069182395935,
-0.03535470739006996,
0.027318738400936127,
0.022511349990963936,
-0.04193603992462158,
-0.011166977696120739,
-0.033367887139320374,
-0.03654324635863304,
-0.06130750849843025,
-0.006536983884871006,
0.05406981706619263,
0.029944175854325294,
0.023912766948342323,
0.010892016813158989,
0.026023760437965393,
0.031505245715379715,
-0.05463747680187225,
0.020453575998544693,
-0.09309658408164978,
-0.01818292774260044,
0.029305556789040565,
0.005002522375434637,
-0.043532587587833405,
0.02265326678752899,
-0.03443225473165512,
0.033616241067647934,
-0.032179344445466995,
0.002357128309085965,
0.008341971784830093,
-0.004913825076073408,
0.0006075758719816804,
-0.04296492412686348,
0.038175277411937714,
-0.023487020283937454,
-0.0023460411466658115,
0.01268369983881712,
-0.011938643641769886,
0.05612758919596672,
-0.007423955947160721,
0.0036454549990594387,
0.0016719423001632094,
0.009969566017389297,
-0.00325518730096519,
0.02561575174331665,
0.06269118189811707,
-0.015007566660642624,
0.0032928837463259697,
-0.026892991736531258,
-0.07024818658828735,
0.0027873096987605095,
0.04048140347003937,
-0.080324187874794,
0.004248596262186766,
-0.005024696700274944,
0.03874293714761734,
-0.03654324635863304,
0.022990316152572632,
-0.02886207029223442,
0.029447471722960472,
-0.02646724507212639,
0.0020178614649921656,
-0.01885702647268772,
-0.041971515864133835,
-0.039310600608587265,
-0.0011841077357530594,
0.016639595851302147,
-0.006155585870146751,
-0.026484984904527664,
0.020772885531187057,
0.012905443087220192,
-0.015557489357888699,
-0.07191569358110428,
0.02962486632168293,
0.0194601658731699,
-0.04700951650738716,
-0.0010133655741810799,
-0.03654324635863304,
0.0025921757332980633,
-0.04349710792303085,
-0.00175398716237396,
0.007051427848637104,
-0.00989860761910677,
-0.04452599585056305,
0.031292375177145004,
0.015717145055532455,
-0.035638537257909775,
-0.013100577518343925,
-0.024781998246908188,
-0.029678083956241608,
0.0022152126766741276,
-0.013180404901504517,
-0.027673527598381042,
-0.012098298408091068,
-0.001636463450267911,
0.032427698373794556,
0.050450969487428665,
0.00183824950363487,
0.010829928331077099,
-0.04069427773356438,
0.012506306171417236,
0.06478443741798401,
-0.00177283538505435,
-0.02139376476407051,
-0.018874764442443848,
0.026325330138206482,
-0.016648465767502785,
0.019513385370373726,
-0.026999428868293762,
0.01479469332844019,
-0.02430303394794464,
-0.03721734881401062,
0.024923915043473244,
-0.10523036122322083,
0.018803806975483894,
-0.06318788975477219,
-0.03200194984674454,
-0.019211813807487488,
0.032516393810510635,
-0.016639595851302147,
0.027957359328866005,
-0.018555454909801483,
0.0019557734485715628,
0.04473887011408806,
0.05839823931455612,
-0.015646187588572502,
0.0030822278931736946,
0.023008054122328758,
0.0757119357585907,
0.0161606315523386,
0.006040279753506184,
-0.00278509221971035,
0.05030905455350876,
0.01633802428841591,
0.010821059346199036,
-0.031292375177145004,
0.010013914667069912,
0.00833310279995203,
0.030068352818489075,
-0.02013426460325718,
-0.05147985741496086,
0.04271657392382622,
0.01046627014875412,
-0.07940173894166946,
-0.011557245627045631,
0.02604149840772152,
-0.02261778712272644,
-0.02185499109327793,
-0.002268431009724736,
0.07386703044176102,
0.033864591270685196,
0.03544340282678604,
-0.06542305648326874,
-0.07266075164079666,
-0.033403366804122925,
-0.02561575174331665,
-0.010945235379040241,
-0.00010421921615488827,
0.016781510785222054,
-0.08486548811197281,
-0.05279257521033287,
0.04328423738479614,
0.03280022740364075,
0.017695091664791107,
0.04736430570483208,
-0.030902106314897537,
0.06925477832555771,
0.08763283491134644,
-0.014333467930555344,
-0.010528357699513435,
-0.02730100043118,
0.04637089744210243,
0.007503783330321312,
0.05552444979548454,
0.041510291397571564,
0.014448774978518486,
0.008412930183112621,
0.0367206409573555,
-0.04232630506157875,
-0.03301309794187546,
-0.008568149991333485,
-0.03413068503141403,
0.05793701484799385,
-0.015247049741446972,
0.007645699195563793,
-0.0035988891031593084,
-0.012257954105734825,
-0.008053706027567387,
-0.07315745204687119,
-0.053573112934827805,
0.013801285065710545,
0.09841841459274292,
-0.06982243806123734,
-0.021287329494953156,
-0.05552444979548454,
0.0822400450706482,
-0.014102855697274208,
-0.0180676206946373,
0.004195377696305513,
0.010093742050230503,
0.018307102844119072,
-0.003680933965370059,
-0.020826103165745735,
-0.012453087605535984,
0.025881843641400337,
-0.1025339663028717,
-0.0350353941321373,
-0.007552566938102245,
0.0456613190472126,
-0.009774431586265564,
0.05435364693403244,
0.03767857328057289,
-0.027123605832457542,
0.037110909819602966,
0.032090649008750916,
0.02071966603398323,
-0.0757119357585907,
-0.001926946802996099,
0.011548375710844994,
-0.012541784904897213,
-0.03304857760667801,
0.009060419164597988,
-0.004068984184414148,
-0.05843371897935867,
-0.013473105616867542,
0.00922450888901949,
-0.03072471171617508,
0.07287362217903137,
0.02338058315217495,
0.01268369983881712,
-0.027070386335253716,
-0.020542273297905922,
0.039346080273389816,
0.022688744589686394,
-0.038636501878499985,
-0.06854519993066788,
-0.025136787444353104,
0.05286353453993797,
-0.01057270634919405,
0.035975586622953415,
-0.020914800465106964,
0.0008758848998695612,
0.02903946489095688,
0.015930017456412315,
-0.047754574567079544,
0.030228007584810257,
-0.006288631819188595,
-0.0005737600149586797,
-0.006869598291814327,
0.010005044750869274,
-0.014484253711998463,
-0.008373016491532326,
0.01717177964746952,
0.009570428170263767,
-0.03223256394267082,
0.04427764564752579,
0.006505940109491348,
-0.019052159041166306,
-0.010413051582872868,
-0.015220439992845058,
0.041510291397571564,
0.016825860366225243,
0.024196596816182137,
-0.0011774554150179029,
0.001956881955265999,
0.017837008461356163,
-0.008373016491532326,
-0.00011433623876655474,
0.0029513994231820107,
-0.0023682154715061188,
-0.013872242532670498,
-0.027779964730143547,
0.022546829655766487,
0.06712604314088821,
0.003009052714332938,
-0.04661925137042999,
-0.11097794026136398,
0.009526079520583153,
-0.024799738079309464,
0.0345919094979763,
0.04182960093021393,
-0.013091707602143288,
-0.013260232284665108,
0.009233378805220127,
0.02494165301322937,
-0.039558954536914825,
-0.06169777363538742,
0.021748553961515427,
-0.002625437220558524,
-0.0339355506002903,
-0.013402147218585014,
0.010821059346199036,
0.008044836111366749,
0.02359345555305481,
0.011530636809766293,
-0.05974643677473068,
0.02620115503668785,
-0.031966473907232285,
0.0016342459712177515,
0.0011037258664146066,
0.014227031730115414,
0.00911807268857956,
-0.024675562977790833,
-0.046016108244657516,
-0.022174300625920296,
-0.0233451034873724,
-0.006155585870146751,
-0.015539750456809998,
-0.00462999427691102,
-0.008989461697638035,
-0.017437869682908058,
0.020648708567023277,
0.015016436576843262,
0.04520009458065033,
-0.05843371897935867,
0.04810936376452446,
0.05080575868487358,
0.01426251046359539,
0.015575229190289974,
-0.0028848766814917326,
-0.05119602754712105,
0.0054460084065794945,
-0.047151435166597366,
-0.008506061509251595,
0.0234160628169775,
0.011849946342408657,
0.022227520123124123,
-0.013872242532670498,
-0.029394254088401794,
-0.007783179637044668,
-0.020701928064227104,
0.04438408091664314,
0.0356917567551136,
-0.05211847648024559,
-0.016604116186499596,
-0.00043600218486972153,
-0.05850467458367348,
-0.010643664747476578,
-0.02224525809288025,
0.00607575848698616,
-0.028773372992873192,
0.003319492796435952,
-0.0012861094437539577,
0.01725160703063011,
0.009375294670462608,
0.0378914475440979,
-0.021074455231428146,
0.0019480123883113265,
0.019548863172531128,
-0.06311693042516708,
0.05084123834967613,
0.013615020550787449,
0.013109446503221989,
-0.033651720732450485,
-0.013730327598750591,
-0.0028072665445506573,
0.02316770888864994,
-0.007432825863361359,
-0.0023615630343556404,
0.006461591459810734,
0.045093659311532974,
0.015859059989452362,
-0.02886207029223442,
0.027567090466618538,
-0.002547827083617449,
-0.050663843750953674,
-0.008222230710089207,
-0.03991374373435974,
-0.0869232639670372,
-0.04523557424545288,
-0.03771405294537544,
0.03750117868185043,
-0.040410447865724564,
0.009242248721420765,
-0.004419338423758745,
0.023451540619134903,
0.04527105391025543,
-0.03874293714761734,
0.010696882382035255,
0.027460655197501183,
-0.010182439349591732,
-0.0009069289080798626,
0.000044764368794858456,
-0.014901130460202694,
-0.03920416533946991,
0.05729839578270912,
0.03636585548520088,
0.020187484100461006,
0.023398322984576225,
-0.0029691390227526426,
0.038601022213697433,
-0.0757119357585907,
-0.015176091343164444,
-0.002780657261610031,
-0.07471852749586105,
0.02806379459798336,
-0.01823614537715912,
0.053821463137865067,
-0.036649685353040695,
0.0015954410191625357,
0.005521400831639767,
0.013685978949069977,
0.01513174269348383,
-0.04590967297554016,
-0.05463747680187225,
0.033775895833969116,
0.04271657392382622,
0.020755145698785782,
-0.03849458694458008,
-0.009712344035506248,
0.049138251692056656,
-0.06510374695062637,
-0.03845910727977753,
-0.031452029943466187,
0.0010532792657613754,
0.03189551457762718,
-0.010927495546638966,
-0.02038261666893959,
-0.05612758919596672,
0.02038261666893959,
0.05775962024927139,
0.0038893723394721746,
0.004638863727450371,
0.02206786535680294,
-0.06737439334392548,
-0.033775895833969116,
0.009339815936982632,
0.01912311650812626,
0.020152004435658455,
-0.0490318164229393,
0.05744031071662903,
0.013898852281272411,
-0.03384685143828392,
-0.0021741902455687523,
0.06755179166793823,
-0.01992139220237732,
-0.025119047611951828,
-0.030139310285449028,
-0.05985287204384804,
0.08394303172826767,
-0.02362893521785736,
0.06393294781446457,
0.026325330138206482,
0.005978191737085581,
-0.004816258326172829,
-0.052650660276412964,
0.06489087641239166,
0.004195377696305513,
0.019761737436056137,
-0.02983773872256279,
0.0389203317463398,
-0.0647134780883789,
0.0004085614928044379,
-0.060030266642570496,
0.020329399034380913,
-0.03324371203780174,
-0.07209308445453644,
0.0009529406088404357,
-0.01483017299324274,
-0.015406704507768154,
-0.06730344146490097,
0.0891229510307312,
0.029820000752806664,
0.03923964500427246,
0.03280022740364075
]
|
33,810 | ipywidgets.widgets.widget_layout | Layout | Layout specification
Defines a layout that can be expressed using CSS. Supports a subset of
https://developer.mozilla.org/en-US/docs/Web/CSS/Reference
When a property is also accessible via a shorthand property, we only
expose the shorthand.
For example:
- ``flex-grow``, ``flex-shrink`` and ``flex-basis`` are bound to ``flex``.
- ``flex-wrap`` and ``flex-direction`` are bound to ``flex-flow``.
- ``margin-[top/bottom/left/right]`` values are bound to ``margin``, etc.
| class Layout(Widget):
"""Layout specification
Defines a layout that can be expressed using CSS. Supports a subset of
https://developer.mozilla.org/en-US/docs/Web/CSS/Reference
When a property is also accessible via a shorthand property, we only
expose the shorthand.
For example:
- ``flex-grow``, ``flex-shrink`` and ``flex-basis`` are bound to ``flex``.
- ``flex-wrap`` and ``flex-direction`` are bound to ``flex-flow``.
- ``margin-[top/bottom/left/right]`` values are bound to ``margin``, etc.
"""
_view_name = Unicode('LayoutView').tag(sync=True)
_view_module = Unicode('@jupyter-widgets/base').tag(sync=True)
_view_module_version = Unicode(__jupyter_widgets_base_version__).tag(sync=True)
_model_name = Unicode('LayoutModel').tag(sync=True)
# Keys
align_content = CaselessStrEnum(['flex-start', 'flex-end', 'center', 'space-between',
'space-around', 'space-evenly', 'stretch'] + CSS_PROPERTIES, allow_none=True, help="The align-content CSS attribute.").tag(sync=True)
align_items = CaselessStrEnum(['flex-start', 'flex-end', 'center',
'baseline', 'stretch'] + CSS_PROPERTIES, allow_none=True, help="The align-items CSS attribute.").tag(sync=True)
align_self = CaselessStrEnum(['auto', 'flex-start', 'flex-end',
'center', 'baseline', 'stretch'] + CSS_PROPERTIES, allow_none=True, help="The align-self CSS attribute.").tag(sync=True)
border_top = Unicode(None, allow_none=True, help="The border top CSS attribute.").tag(sync=True)
border_right = Unicode(None, allow_none=True, help="The border right CSS attribute.").tag(sync=True)
border_bottom = Unicode(None, allow_none=True, help="The border bottom CSS attribute.").tag(sync=True)
border_left = Unicode(None, allow_none=True, help="The border left CSS attribute.").tag(sync=True)
bottom = Unicode(None, allow_none=True, help="The bottom CSS attribute.").tag(sync=True)
display = Unicode(None, allow_none=True, help="The display CSS attribute.").tag(sync=True)
flex = Unicode(None, allow_none=True, help="The flex CSS attribute.").tag(sync=True)
flex_flow = Unicode(None, allow_none=True, help="The flex-flow CSS attribute.").tag(sync=True)
height = Unicode(None, allow_none=True, help="The height CSS attribute.").tag(sync=True)
justify_content = CaselessStrEnum(['flex-start', 'flex-end', 'center',
'space-between', 'space-around'] + CSS_PROPERTIES, allow_none=True, help="The justify-content CSS attribute.").tag(sync=True)
justify_items = CaselessStrEnum(['flex-start', 'flex-end', 'center'] + CSS_PROPERTIES,
allow_none=True, help="The justify-items CSS attribute.").tag(sync=True)
left = Unicode(None, allow_none=True, help="The left CSS attribute.").tag(sync=True)
margin = Unicode(None, allow_none=True, help="The margin CSS attribute.").tag(sync=True)
max_height = Unicode(None, allow_none=True, help="The max-height CSS attribute.").tag(sync=True)
max_width = Unicode(None, allow_none=True, help="The max-width CSS attribute.").tag(sync=True)
min_height = Unicode(None, allow_none=True, help="The min-height CSS attribute.").tag(sync=True)
min_width = Unicode(None, allow_none=True, help="The min-width CSS attribute.").tag(sync=True)
overflow = Unicode(None, allow_none=True, help="The overflow CSS attribute.").tag(sync=True)
order = Unicode(None, allow_none=True, help="The order CSS attribute.").tag(sync=True)
padding = Unicode(None, allow_none=True, help="The padding CSS attribute.").tag(sync=True)
right = Unicode(None, allow_none=True, help="The right CSS attribute.").tag(sync=True)
top = Unicode(None, allow_none=True, help="The top CSS attribute.").tag(sync=True)
visibility = CaselessStrEnum(['visible', 'hidden']+CSS_PROPERTIES, allow_none=True, help="The visibility CSS attribute.").tag(sync=True)
width = Unicode(None, allow_none=True, help="The width CSS attribute.").tag(sync=True)
object_fit = CaselessStrEnum(['contain', 'cover', 'fill', 'scale-down', 'none'], allow_none=True, help="The object-fit CSS attribute.").tag(sync=True)
object_position = Unicode(None, allow_none=True, help="The object-position CSS attribute.").tag(sync=True)
grid_auto_columns = Unicode(None, allow_none=True, help="The grid-auto-columns CSS attribute.").tag(sync=True)
grid_auto_flow = CaselessStrEnum(['column','row','row dense','column dense']+ CSS_PROPERTIES, allow_none=True, help="The grid-auto-flow CSS attribute.").tag(sync=True)
grid_auto_rows = Unicode(None, allow_none=True, help="The grid-auto-rows CSS attribute.").tag(sync=True)
grid_gap = Unicode(None, allow_none=True, help="The grid-gap CSS attribute.").tag(sync=True)
grid_template_rows = Unicode(None, allow_none=True, help="The grid-template-rows CSS attribute.").tag(sync=True)
grid_template_columns = Unicode(None, allow_none=True, help="The grid-template-columns CSS attribute.").tag(sync=True)
grid_template_areas = Unicode(None, allow_none=True, help="The grid-template-areas CSS attribute.").tag(sync=True)
grid_row = Unicode(None, allow_none=True, help="The grid-row CSS attribute.").tag(sync=True)
grid_column = Unicode(None, allow_none=True, help="The grid-column CSS attribute.").tag(sync=True)
grid_area = Unicode(None, allow_none=True, help="The grid-area CSS attribute.").tag(sync=True)
def __init__(self, **kwargs):
if 'border' in kwargs:
border = kwargs.pop('border')
for side in ['top', 'right', 'bottom', 'left']:
kwargs.setdefault(f'border_{side}', border)
super().__init__(**kwargs)
def _get_border(self):
"""
`border` property getter. Return the common value of all side
borders if they are identical. Otherwise return None.
"""
found = None
for side in ['top', 'right', 'bottom', 'left']:
if not hasattr(self, "border_" + side):
return
old, found = found, getattr(self, "border_" + side)
if found is None or (old is not None and found != old):
return
return found
def _set_border(self, border):
"""
`border` property setter. Set all 4 sides to `border` string.
"""
for side in ['top', 'right', 'bottom', 'left']:
setattr(self, "border_" + side, border)
border = property(_get_border, _set_border)
| (**kwargs) | [
0.0368070974946022,
-0.050642967224121094,
-0.04618769511580467,
0.0019479047041386366,
0.004575341008603573,
-0.028754904866218567,
-0.03445683792233467,
0.023890892043709755,
-0.04508409649133682,
-0.024177011102437973,
0.0019249130273237824,
0.05877690762281418,
0.04381699860095978,
0.016625527292490005,
-0.031166475266218185,
0.008292325772345066,
0.02415657229721546,
-0.05902215093374252,
0.058654285967350006,
-0.011587797664105892,
0.0033184632193297148,
-0.038339875638484955,
0.04393962025642395,
0.03466120734810829,
0.023993076756596565,
-0.0007612794870510697,
0.016901426017284393,
0.014326360076665878,
0.026486394926905632,
-0.03930041566491127,
-0.04990723356604576,
-0.0001413029240211472,
-0.0357852466404438,
0.003701657522469759,
0.057223692536354065,
-0.08477281033992767,
0.04179373383522034,
0.037011466920375824,
-0.00638657296076417,
-0.013386256992816925,
-0.014377452433109283,
0.010790753178298473,
0.045492835342884064,
-0.10627257078886032,
0.0157671719789505,
0.007536156103014946,
0.022092433646321297,
0.03786982223391533,
-0.058122921735048294,
-0.006800422910600901,
0.06584811955690384,
-0.026629453524947166,
-0.007015011738985777,
0.08326047658920288,
-0.06703346967697144,
0.05497561767697334,
-0.0030297902412712574,
0.0918031558394432,
0.004991745576262474,
0.005727478768676519,
-0.053504154086112976,
0.03797200694680214,
-0.024994490668177605,
-0.02231724001467228,
-0.03619398549199104,
-0.035703495144844055,
0.0027308985590934753,
0.0053136288188397884,
0.01615547388792038,
-0.027835238724946976,
-0.040853630751371384,
0.017330603674054146,
0.01529711950570345,
-0.011495831422507763,
-0.041977666318416595,
-0.058531664311885834,
-0.019456055015325546,
0.006018706131726503,
0.05170569568872452,
-0.027446934953331947,
0.01635984517633915,
0.05840904265642166,
0.02726300247013569,
-0.03437509015202522,
0.08354659378528595,
-0.03455902263522148,
0.012231564149260521,
0.10202167183160782,
0.0030936559196561575,
-0.052482299506664276,
-0.019629770889878273,
0.026343336328864098,
0.010780534707009792,
0.04210028797388077,
-0.021949373185634613,
0.01616569235920906,
-0.009370380081236362,
-0.06184246391057968,
-0.03335323929786682,
-0.0028458568267524242,
0.0017588621703907847,
0.01909840665757656,
0.005722369067370892,
-0.004110398236662149,
-0.009237539023160934,
-0.022807728499174118,
-0.046514686197042465,
0.010545508936047554,
-0.04214116185903549,
-0.023298216983675957,
0.04013833403587341,
-0.04917150363326073,
-0.05154219642281532,
0.03464077040553093,
0.05362677574157715,
0.03184089809656143,
-0.05861341208219528,
-0.017310166731476784,
0.06617511063814163,
-0.05158307030797005,
-0.04598332569003105,
0.00020947959274053574,
-0.03445683792233467,
-0.020048730075359344,
0.053790271282196045,
0.037931133061647415,
-0.010719223879277706,
0.07757897675037384,
-0.029613260179758072,
0.02585284784436226,
0.0053340657614171505,
-0.014929252676665783,
-0.034497711807489395,
0.0157671719789505,
-0.009528766386210918,
0.011219930835068226,
0.022071996703743935,
0.009493001736700535,
-0.01439789030700922,
0.08673477172851562,
0.03547868877649307,
-0.01076009776443243,
-0.024074824526906013,
-0.011148401536047459,
-0.06682910025119781,
-0.020181570202112198,
-0.024994490668177605,
-0.02728343941271305,
-0.028754904866218567,
0.016022633761167526,
-0.029960690066218376,
-0.019721737131476402,
0.03122778609395027,
0.024463128298521042,
0.030022000893950462,
0.03325105458498001,
-0.008047081530094147,
-0.035417377948760986,
0.04778178408741951,
0.01584891974925995,
-0.006667581852525473,
-0.02971544675529003,
0.055302612483501434,
-0.01040245033800602,
0.011495831422507763,
0.06862755864858627,
0.026731640100479126,
-0.09940572828054428,
-0.002771772677078843,
0.029122771695256233,
0.005236989818513393,
-0.029224958270788193,
-0.04091494157910347,
0.01206806767731905,
-0.022991662845015526,
0.07618925720453262,
0.012139597907662392,
0.018332019448280334,
-0.013314726762473583,
-0.04704605042934418,
-0.024483565241098404,
-0.02697688341140747,
-0.0017243747133761644,
0.006897498853504658,
0.011516268365085125,
0.021969810128211975,
0.04410311579704285,
-0.05428076162934303,
0.036214422434568405,
0.002015602309256792,
0.013386256992816925,
-0.00423812959343195,
-0.025893721729516983,
0.011342553421854973,
-0.024422254413366318,
-0.012732272036373615,
0.02738562412559986,
-0.034109409898519516,
0.0347633920609951,
-0.014418327249586582,
0.010453542694449425,
-0.003494732780382037,
0.031452592462301254,
0.04263165220618248,
0.05301366373896599,
-0.037318021059036255,
-0.01475553773343563,
-0.03719539940357208,
-0.017555411905050278,
0.013927837833762169,
-0.06225120276212692,
0.008343419060111046,
-0.03674578666687012,
0.03607136383652687,
0.03889167308807373,
-0.047413915395736694,
0.0010275995591655374,
0.04234553128480911,
-0.023114284500479698,
0.002516309730708599,
0.0793774351477623,
0.023666083812713623,
0.009922179393470287,
-0.031248223036527634,
0.02597546949982643,
-0.04254990443587303,
0.030083313584327698,
0.003435976104810834,
0.02374783344566822,
-0.03870774060487747,
-0.02182675153017044,
-0.06462189555168152,
0.04022008180618286,
0.035396941006183624,
0.015021219849586487,
-0.05121520534157753,
-0.02928626909852028,
0.009247757494449615,
-0.04643293842673302,
-0.027344750240445137,
-0.019629770889878273,
-0.009891523979604244,
0.01637006364762783,
-0.005088821053504944,
-0.033169303089380264,
-0.004940652754157782,
0.0236252099275589,
0.02123407833278179,
-0.0015123405028134584,
-0.026792950928211212,
-0.052359677851200104,
-0.025117114186286926,
0.024279195815324783,
-0.020641403272747993,
-0.0049202158115804195,
-0.01584891974925995,
-0.04393962025642395,
0.00199516536667943,
0.019977200776338577,
-0.0391777940094471,
0.03102341666817665,
-0.08371008932590485,
0.0200180746614933,
0.08681651949882507,
0.08918721228837967,
0.008312763646245003,
0.01318188663572073,
0.02848922461271286,
-0.06033012270927429,
-0.014275267720222473,
-0.10537334531545639,
0.039750028401613235,
-0.008915655314922333,
0.03825812786817551,
-0.003821725258603692,
-0.04066969454288483,
0.026506831869482994,
0.008338309824466705,
-0.049661990255117416,
-0.019241467118263245,
0.011383427307009697,
-0.028550535440444946,
-0.001804845524020493,
0.04171198606491089,
0.005696822889149189,
-0.049253251403570175,
-0.027937423437833786,
-0.05219618231058121,
-0.016237223520874977,
0.0030093530658632517,
-0.009114916436374187,
0.024177011102437973,
0.02119320258498192,
-0.007745635695755482,
0.06396791338920593,
0.030042439699172974,
-0.027119943872094154,
0.04304039105772972,
-0.01838311180472374,
-0.0384216234087944,
0.02190849930047989,
0.03829900175333023,
0.10373838245868683,
0.021152328699827194,
0.010453542694449425,
0.00903827790170908,
0.010964468121528625,
-0.0017230974044650793,
0.055915724486112595,
-0.004491038154810667,
0.04024051874876022,
0.019047314301133156,
0.041977666318416595,
0.028121357783675194,
-0.013141012750566006,
-0.00021937878045719117,
-0.0031549669802188873,
-0.016206568107008934,
0.037522394210100174,
0.05603834614157677,
-0.019844358786940575,
-0.06752395629882812,
-0.03192264586687088,
-0.0339050367474556,
0.005431141704320908,
-0.04365350306034088,
0.027099506929516792,
-0.029960690066218376,
0.0015021219151094556,
0.03028768301010132,
-0.025301046669483185,
-0.004680080804973841,
-0.034293342381715775,
0.011148401536047459,
-0.007459517102688551,
-0.0640905350446701,
-0.004703072365373373,
-0.0010908266995102167,
-0.004498702008277178,
-0.08395533263683319,
0.08616252988576889,
0.03351673483848572,
-0.013008171692490578,
0.0007836325094103813,
-0.012865112163126469,
-0.030880356207489967,
0.06617511063814163,
-0.01475553773343563,
-0.0013769450597465038,
-0.007990879938006401,
0.02243986167013645,
-0.01607372611761093,
-0.022664669901132584,
0.03852380812168121,
0.04291776940226555,
-0.04806790128350258,
-0.03968871757388115,
-0.0640905350446701,
-0.022255929186940193,
0.028141794726252556,
0.013396475464105606,
-0.01132211647927761,
-0.0023847462143749,
0.03204526752233505,
0.00022895864094607532,
-0.02061074785888195,
-0.007648559752851725,
0.010617039166390896,
0.007004793267697096,
-0.03102341666817665,
0.0028995040338486433,
-0.03443640097975731,
0.03725671023130417,
-0.030675986781716347,
-0.021683692932128906,
0.04896713048219681,
-0.019660426303744316,
0.01353953406214714,
-0.036500539630651474,
-0.07026252150535583,
0.05260492488741875,
0.02293035201728344,
0.04737304151058197,
0.018812289461493492,
-0.03537650406360626,
-0.04418486729264259,
-0.012231564149260521,
-0.016400719061493874,
-0.025076240301132202,
-0.02918408252298832,
0.011741075664758682,
-0.012170253321528435,
0.02152019552886486,
0.024279195815324783,
-0.04770003631711006,
-0.017821092158555984,
0.045492835342884064,
0.06114760413765907,
0.04761828854680061,
-0.02716081775724888,
0.04508409649133682,
-0.07761985063552856,
0.03723627328872681,
0.0273651871830225,
0.011281242594122887,
-0.015174496918916702,
0.08101239800453186,
0.057632435113191605,
0.01615547388792038,
0.05423988774418831,
-0.04234553128480911,
-0.02100927010178566,
-0.03780851140618324,
-0.00853757094591856,
-0.0050658294931054115,
-0.028816217556595802,
0.03819681331515312,
0.03380285203456879,
-0.00812883023172617,
-0.0268542617559433,
-0.04152804985642433,
0.004943207371979952,
0.06372267007827759,
0.037440646439790726,
0.008414948359131813,
-0.04158936068415642,
-0.022889476269483566,
0.011904572136700153,
-0.029122771695256233,
0.008047081530094147,
0.004043978173285723,
0.0535450279712677,
-0.028019173070788383,
-0.04614682123064995,
-0.0035509346053004265,
-0.04876276105642319,
-0.023277780041098595,
-0.06192421168088913,
0.05043859779834747,
-0.03930041566491127,
0.04447098448872566,
0.0049099973402917385,
0.0157671719789505,
0.0015621556667611003,
-0.012967297807335854,
0.00837918370962143,
-0.03566262125968933,
0.024687936529517174,
0.012139597907662392,
-0.03831943869590759,
0.006734002381563187,
0.0824429914355278,
-0.02160194329917431,
-0.03895298391580582,
-0.003982666879892349,
-0.07676149904727936,
-0.01768825203180313,
-0.05182831734418869,
-0.056814953684806824,
-0.033598482608795166,
0.030655549839138985,
-0.009743355214595795,
-0.003952011466026306,
0.0040056584402918816,
-0.026629453524947166,
0.001221112790517509,
0.03200439363718033,
-0.0066164894960820675,
-0.07553527504205704,
0.02364564687013626,
-0.026752077043056488,
-0.060166627168655396,
-0.0066726915538311005,
-0.004174264147877693,
0.04042445123195648,
-0.022071996703743935,
-0.027549121528863907,
-0.01182282343506813,
-0.07116174697875977,
-0.03425246849656105,
0.0161452554166317,
-0.035396941006183624,
-0.008098174817860126,
0.008726613596081734,
-0.025934595614671707,
0.034109409898519516,
0.05346328020095825,
-0.04463448002934456,
0.03159565478563309,
-0.04091494157910347,
-0.0737776905298233,
0.0741046816110611,
-0.0015621556667611003,
0.03838074952363968,
0.028060046955943108,
0.05170569568872452,
0.03970915451645851,
-0.0577959306538105,
0.004199810326099396,
-0.05746893584728241,
0.01878163404762745,
-0.02867315709590912,
0.04626944288611412,
0.05534348636865616,
0.0688319280743599,
-0.05088821426033974,
-0.00773030798882246,
0.023318655788898468,
0.014019805006682873,
-0.03122778609395027,
-0.02705863118171692,
-0.013866527006030083,
0.04013833403587341,
-0.010729442350566387,
0.029224958270788193,
-0.014030023477971554,
-0.03970915451645851,
-0.009094479493796825,
0.026241149753332138,
0.009365270845592022,
0.022664669901132584,
0.010688568465411663,
0.009523657150566578,
-0.035192571580410004,
-0.004588114097714424,
0.10447411239147186,
0.01090315729379654,
-0.054812122136354446,
0.024177011102437973,
-0.004761828575283289,
0.0041870372369885445,
-0.028754904866218567,
-0.01036157552152872,
0.054403383284807205,
-0.028039610013365746,
0.06090235710144043,
-0.024217884987592697,
-0.0021292835008352995,
0.004534466657787561,
0.03445683792233467,
0.005901193246245384,
0.03868730366230011,
0.0017588621703907847,
0.009722918272018433,
0.025607602670788765,
0.04471622779965401,
0.03623485937714577,
-0.008772596716880798,
0.006003378424793482,
-0.0007069936254993081,
-0.0017026603454723954,
0.03365979343652725,
0.0305942390114069,
-0.04214116185903549,
-0.02011004090309143,
-0.026016343384981155,
0.016441592946648598,
-0.016104381531476974,
0.09057693183422089,
0.015675203874707222,
0.011669546365737915,
-0.0007121028611436486,
-0.05231880396604538,
-0.07124349474906921,
0.013355601578950882,
0.03819681331515312,
0.01530733797699213,
-0.004529357422143221,
0.008736832067370415,
0.029817631468176842,
0.008614209480583668,
-0.0014024913543835282,
0.06592986732721329,
-0.01798458956182003,
0.005880756303668022,
-0.03930041566491127,
-0.013948274776339531,
0.04134411737322807,
-0.04647381231188774,
-0.08665302395820618,
0.0006929431692697108,
0.02554629184305668,
0.030553365126252174,
-0.06245557218790054,
-0.0070609948597848415,
0.0026772513519972563,
-0.018822507932782173,
0.03443640097975731,
0.012241782620549202,
-0.08395533263683319,
-0.03224963694810867,
0.011659327894449234,
0.04598332569003105,
0.0014791302382946014,
0.021152328699827194,
0.08093065023422241,
-0.04855839163064957,
-0.02423832193017006,
0.029613260179758072,
-0.009937507100403309,
-0.01697295531630516,
0.028039610013365746,
-0.006381463725119829,
0.053504154086112976,
0.057509809732437134,
0.012824238277971745,
0.057428061962127686,
-0.024279195815324783,
0.0007504223030991852,
-0.02607765421271324,
0.05313628539443016,
-0.01448985654860735,
0.0027845457661896944,
-0.030348993837833405,
-0.015685422345995903,
-0.05011160671710968,
-0.05767330899834633,
0.048844508826732635,
0.02959282323718071,
-0.06433577835559845,
0.010821409523487091,
0.04060838371515274,
0.0029761430341750383,
-0.02352302521467209,
-0.028141794726252556,
0.020631184801459312,
0.0025022593326866627,
-0.06090235710144043,
-0.023686520755290985,
0.01197610143572092,
0.06678822636604309,
-0.04193679243326187,
0.05624271556735039,
-0.05121520534157753,
0.033782415091991425,
0.025219298899173737,
0.0022314684465527534,
0.0005958672263659537,
-0.003479404840618372,
-0.0003688245778903365,
0.04831314459443092,
-0.02172456681728363,
0.0322905108332634,
0.0640905350446701,
-0.014612479135394096,
0.008844126015901566,
0.03558087348937988,
-0.045206718146800995,
0.010325810872018337,
0.018148085102438927,
-0.041548486799001694,
0.05951264128088951,
0.004700517747551203,
-0.05264579877257347,
-0.02190849930047989,
0.022071996703743935,
-0.03899385780096054,
-0.03676622360944748,
-0.011700201779603958,
-0.006447883788496256,
-0.020385941490530968,
-0.0029863615054637194,
-0.014448982663452625,
0.020028293132781982,
0.02092752233147621,
-0.026547705754637718,
0.032964933663606644,
0.008813470602035522,
0.047945279628038406,
0.03372110426425934,
0.02534192055463791,
0.007633232045918703,
0.013161449693143368,
-0.0343342162668705,
0.0066726915538311005,
0.0038089521694928408,
0.014050460420548916,
-0.004151272587478161,
0.01717732660472393,
-0.04537021368741989,
-0.00783249270170927,
0.029756320640444756,
-0.09262063354253769,
-0.019578678533434868,
0.005727478768676519,
-0.028754904866218567,
-0.0161452554166317,
-0.011179056949913502,
0.038544245064258575,
-0.027549121528863907,
-0.0019364089239388704,
-0.029776757583022118,
0.027712617069482803,
0.024585751816630363,
-0.02546454407274723,
-0.06082060933113098,
-0.008062409237027168,
-0.007638341281563044,
0.05669232830405235,
-0.01938452571630478,
0.056937575340270996,
-0.04700517654418945,
-0.033986784517765045,
0.022460298612713814,
0.028611846268177032,
0.08097152411937714,
0.014724882319569588,
-0.03993396461009979,
0.013672375120222569,
-0.0396069698035717,
0.017330603674054146,
0.08252473920583725,
0.013273852877318859,
-0.04193679243326187,
0.03968871757388115,
-0.009932397864758968,
0.026343336328864098,
0.025198861956596375,
-0.026527268812060356,
-0.014796411618590355,
-0.016022633761167526,
0.053994640707969666,
0.03251532092690468,
-0.026731640100479126,
0.009160900488495827,
0.07140699028968811,
-0.029776757583022118,
-0.03770632669329643,
-0.006534741260111332,
-0.01596132293343544,
0.009728027507662773,
0.0880427360534668,
-0.02071293257176876,
0.03766545280814171,
-0.01074987929314375,
-0.003080882830545306,
0.06233295053243637,
0.0009011454530991614,
-0.06515326350927353,
0.04254990443587303,
-0.010121440514922142,
-0.05374939739704132,
-0.0503159761428833,
0.006933263503015041,
-0.016094163060188293,
0.05199181288480759,
0.005604856181889772,
0.035703495144844055,
0.025076240301132202,
0.035192571580410004,
0.033087555319070816,
-0.015205152332782745,
-0.043980494141578674,
-0.00732667651027441,
0.04422574117779732,
-0.032167889177799225,
0.027201691642403603,
0.012211127206683159,
-0.02060052938759327,
-0.06932241469621658,
-0.025893721729516983,
-0.010484198108315468,
-0.002835638355463743,
0.06404966115951538,
0.042590778321027756,
0.03253575786948204,
0.0037272039335221052,
0.05158307030797005
]
|
33,815 | ipywidgets.widgets.widget_layout | __init__ | null | def __init__(self, **kwargs):
if 'border' in kwargs:
border = kwargs.pop('border')
for side in ['top', 'right', 'bottom', 'left']:
kwargs.setdefault(f'border_{side}', border)
super().__init__(**kwargs)
| (self, **kwargs) | [
-0.010446921922266483,
-0.02103336714208126,
0.040252912789583206,
-0.018521921709179878,
-0.085110142827034,
-0.02722478285431862,
-0.01679530180990696,
0.037706583738327026,
0.02889908105134964,
0.018190549686551094,
-0.0030608258675783873,
0.11566608399152756,
-0.019167223945260048,
-0.0008567696786485612,
0.0017604109598323703,
0.007695666514337063,
0.03571835532784462,
-0.026841089129447937,
0.01655113324522972,
0.0033049944322556257,
0.05225204676389694,
0.0007668415200896561,
-0.0016830182867124677,
0.04778725281357765,
0.05863530933856964,
0.068122997879982,
-0.059821270406246185,
0.03634621948003769,
0.07401791960000992,
-0.016245922073721886,
-0.02038806490600109,
0.014336176216602325,
-0.023736661300063133,
0.089365653693676,
0.04426425322890282,
-0.04063660651445389,
0.002069981535896659,
0.023632017895579338,
-0.09006327390670776,
0.08169178664684296,
0.04639200493693352,
-0.009322002530097961,
0.03317203000187874,
-0.0032134312205016613,
0.010795733891427517,
-0.01935907080769539,
0.05434492230415344,
-0.0002695118309929967,
-0.06006544083356857,
-0.03509049490094185,
0.024591250345110893,
-0.0361369326710701,
0.028306100517511368,
-0.019463714212179184,
-0.032177913933992386,
0.013560069724917412,
-0.0033464159350842237,
0.060239844024181366,
-0.017702212557196617,
0.05880971625447273,
-0.08524966984987259,
0.020545031875371933,
0.020911283791065216,
-0.03235232084989548,
-0.010446921922266483,
-0.05267062410712242,
-0.04203185439109802,
0.004329629708081484,
0.03137564659118652,
0.04182256758213043,
0.06268152594566345,
0.0510660856962204,
-0.04953131452202797,
0.014109448529779911,
-0.02741662971675396,
-0.002249837853014469,
-0.019184663891792297,
0.045380450785160065,
0.004011339042335749,
0.007237850688397884,
-0.0244517270475626,
-0.0021877058316022158,
-0.011903212405741215,
0.06714632362127304,
0.040078505873680115,
-0.02230653166770935,
-0.019202103838324547,
0.06271640956401825,
0.05720518156886101,
-0.028550269082188606,
-0.07673865556716919,
0.009932423941791058,
-0.014911715872585773,
-0.002825377741828561,
-0.03760194033384323,
-0.007015482988208532,
0.00494005111977458,
-0.017562687397003174,
-0.023422731086611748,
0.02207980491220951,
-0.02891652099788189,
-0.025567924603819847,
0.011153265833854675,
-0.03931112214922905,
0.02420755848288536,
-0.05465885251760483,
-0.022446056827902794,
-0.046845462173223495,
-0.04510140046477318,
-0.01317637600004673,
0.024765657261013985,
-0.032648809254169464,
-0.004800525959581137,
0.06250712275505066,
-0.012635717168450356,
0.02403315156698227,
-0.017257478088140488,
-0.0445781834423542,
0.03379989042878151,
-0.005441468209028244,
-0.014301295392215252,
0.014798352494835854,
0.06547202914953232,
0.010987580753862858,
0.08134297281503677,
0.04695010557770729,
-0.0594724602997303,
0.041369110345840454,
0.04712451249361038,
-0.033904533833265305,
0.04865928366780281,
-0.0062044947408139706,
-0.06139092519879341,
-0.08880755305290222,
-0.041299350559711456,
-0.00022018761956132948,
0.045136284083127975,
0.048101186752319336,
0.002644431544467807,
0.024940064176917076,
0.035822998732328415,
-0.0035121014807373285,
0.018207989633083344,
-0.020318303257226944,
-0.10101597756147385,
0.07799437642097473,
-0.004068020731210709,
-0.02680620737373829,
0.06139092519879341,
0.06700679659843445,
0.00784391164779663,
0.005410947371274233,
0.01848703995347023,
0.014301295392215252,
0.004211905878037214,
-0.08190107345581055,
-0.012478752061724663,
-0.0424504280090332,
0.03231743723154068,
0.09445831179618835,
0.03228255733847618,
-0.017484204843640327,
0.03542186692357063,
-0.06083282455801964,
0.010446921922266483,
0.06920431554317474,
-0.0005109551711939275,
-0.09878358244895935,
0.05183347314596176,
0.012426430359482765,
0.032404642552137375,
-0.05200788006186485,
0.014885555021464825,
0.03533466160297394,
-0.021504264324903488,
0.032613929361104965,
-0.02595161832869053,
0.005192939657717943,
-0.02745150960981846,
-0.043252695351839066,
0.03976457566022873,
-0.006858517415821552,
0.025829533115029335,
0.00435143057256937,
0.05654243752360344,
-0.03938088193535805,
0.011659043841063976,
0.005267062224447727,
0.013516467995941639,
-0.012147380039095879,
0.015112282708287239,
0.02914324961602688,
-0.024695895612239838,
-0.03571835532784462,
-0.0013679973781108856,
-0.04067148640751839,
0.05008941516280174,
-0.05567040666937828,
0.005624594632536173,
0.05636803060770035,
-0.021853076294064522,
0.02720734104514122,
-0.028550269082188606,
0.019829966127872467,
0.08148249983787537,
0.019707882776856422,
0.025550484657287598,
-0.030276887118816376,
-0.016054075211286545,
-0.03364292532205582,
0.021417060866951942,
-0.019847406074404716,
0.006718992721289396,
0.019062580540776253,
0.014981478452682495,
0.018626565113663673,
-0.05511230602860451,
0.02232397347688675,
-0.03331155329942703,
0.03746241703629494,
0.08211036026477814,
0.02255070023238659,
-0.03268369287252426,
0.007952915504574776,
0.01231306605041027,
0.029614144936203957,
0.055321596562862396,
-0.056821487843990326,
-0.018870733678340912,
0.0012295625638216734,
-0.08308703452348709,
-0.047508206218481064,
-0.055321596562862396,
0.044299133121967316,
-0.03226511552929878,
-0.01391760166734457,
-0.006348379887640476,
-0.05971662700176239,
-0.03338131681084633,
-0.03161981329321861,
0.056891247630119324,
0.0013865280197933316,
0.011161986738443375,
-0.011606722138822079,
0.02103336714208126,
-0.014981478452682495,
0.0027904966846108437,
0.04482235014438629,
-0.01574014499783516,
0.025236554443836212,
-0.08273822069168091,
0.024922622367739677,
0.014484421350061893,
0.032631371170282364,
0.016926106065511703,
-0.00499673280864954,
-0.039450645446777344,
-0.017798136919736862,
-0.0015064321924000978,
-0.020998487249016762,
-0.010996300727128983,
-0.03491608798503876,
0.029666466638445854,
0.0467756986618042,
0.07883153110742569,
0.01614127866923809,
-0.03081754595041275,
-0.021347299218177795,
-0.08029653877019882,
0.010813173837959766,
0.0254981629550457,
-0.01850447990000248,
0.01095269899815321,
0.04796165972948074,
0.010787012986838818,
-0.022411175072193146,
-0.0122171426191926,
0.01612383872270584,
-0.07199481129646301,
-0.03223023563623428,
0.08162202686071396,
-0.02314368076622486,
0.011161986738443375,
0.011249189265072346,
-0.01571398414671421,
-0.01552213728427887,
0.0318814218044281,
-0.0035426225513219833,
-0.00537170609459281,
-0.017684772610664368,
0.005485069938004017,
0.04192721098661423,
0.02316112257540226,
0.04227602481842041,
0.00358186406083405,
-0.025236554443836212,
0.07911057770252228,
0.04614783823490143,
-0.01914978213608265,
-0.03652062267065048,
0.0030063241720199585,
-0.04778725281357765,
0.06473951786756516,
0.04171792417764664,
0.012496192939579487,
-0.03315458819270134,
0.011746246367692947,
0.0045389169827103615,
0.04395032301545143,
-0.010551565326750278,
0.038787901401519775,
0.04011338949203491,
-0.034340549260377884,
-0.02589929662644863,
-0.03313714638352394,
0.016673216596245766,
-0.006243736017495394,
-0.04660129174590111,
-0.02146938256919384,
0.04192721098661423,
0.00019634304044302553,
-0.07799437642097473,
-0.041543517261743546,
-0.023091359063982964,
-0.010176592506468296,
-0.01953347586095333,
0.010141710750758648,
0.00997602567076683,
0.004599959123879671,
0.07708746939897537,
-0.021347299218177795,
0.002618270693346858,
0.03315458819270134,
-0.028776995837688446,
-0.025864414870738983,
-0.02441684529185295,
-0.005864403210580349,
0.06519297510385513,
0.001267713843844831,
-0.04548509418964386,
0.05211252346634865,
-0.0036690670531243086,
-0.015059961006045341,
0.02384130470454693,
-0.005646395497024059,
0.024504048749804497,
-0.0036908676847815514,
0.012426430359482765,
0.022201888263225555,
0.016219761222600937,
-0.01199913490563631,
-0.04276436194777489,
0.04084589332342148,
-0.004098542034626007,
0.0339742973446846,
-0.01914978213608265,
-0.04872904717922211,
-0.05587969347834587,
0.015243087895214558,
0.006461743731051683,
0.06229783594608307,
-0.012949648313224316,
-0.0004826142103411257,
0.024974944069981575,
0.005349905230104923,
0.03864837810397148,
0.0005090476479381323,
-0.006117291748523712,
0.008872906677424908,
-0.005184219218790531,
-0.0024896461982280016,
-0.05228693038225174,
-0.008855466730892658,
-0.01456290390342474,
0.029788551852107048,
0.034985851496458054,
-0.027747999876737595,
0.0030826267320662737,
0.037043843418359756,
-0.012391548603773117,
-0.011685204692184925,
-0.0872727781534195,
0.0573447048664093,
-0.011039902456104755,
-0.046217598021030426,
-0.03798563405871391,
-0.012077618390321732,
0.03254416584968567,
0.05075215548276901,
-0.004992372822016478,
-0.021329857409000397,
0.006727712694555521,
0.03742753714323044,
-0.05870507284998894,
-0.06397213786840439,
-0.019428832456469536,
0.039206478744745255,
0.03746241703629494,
0.00882058497518301,
-0.026945732533931732,
0.0034859406296163797,
-0.063727967441082,
-0.006357099860906601,
-0.003265752922743559,
0.02677132748067379,
0.006086770910769701,
0.0024198838509619236,
0.04806630313396454,
0.07464578002691269,
-0.022672785446047783,
-0.010368438437581062,
-0.035578832030296326,
0.003507741494104266,
0.018016142770648003,
0.03137564659118652,
-0.011153265833854675,
0.043706152588129044,
0.010324837639927864,
-0.026474837213754654,
-0.04583390802145004,
0.0276433564722538,
0.04084589332342148,
0.04932202771306038,
0.0382298044860363,
0.05179859325289726,
0.032840657979249954,
-0.03927623853087425,
-0.028166575357317924,
0.0679834708571434,
0.005781560204923153,
-0.04998477175831795,
0.0361369326710701,
-0.06609988957643509,
-0.00808371976017952,
0.03149773180484772,
-0.0019500774797052145,
0.0019642480183392763,
-0.019864847883582115,
-0.002831917954608798,
-0.0027774160262197256,
-0.00009844403393799439,
-0.0488685704767704,
0.00041857449105009437,
0.012696759775280952,
-0.014955317601561546,
-0.007338134106248617,
0.011161986738443375,
-0.009199918247759342,
0.012208422645926476,
-0.037288010120391846,
0.005410947371274233,
0.05193811655044556,
-0.029631584882736206,
-0.03266625106334686,
0.025445841252803802,
-0.09306306391954422,
-0.0890866070985794,
-0.013682154007256031,
0.016088956966996193,
-0.014902995899319649,
0.03320690989494324,
-0.04088077321648598,
-0.06453023105859756,
-0.026631802320480347,
-0.02930021472275257,
-0.018626565113663673,
0.03931112214922905,
0.009845220483839512,
-0.06093746796250343,
0.0017571408534422517,
-0.010848055593669415,
-0.013237418606877327,
-0.03100939281284809,
-0.0037780706770718098,
0.03592764213681221,
0.020771758630871773,
0.035613711923360825,
-0.033259231597185135,
-0.06275129318237305,
-0.029178129509091377,
-0.04398520290851593,
-0.01457162480801344,
-0.03146284818649292,
-0.031323324888944626,
-0.017894059419631958,
-0.021103130653500557,
-0.05797256529331207,
0.0014377597253769636,
0.01909746043384075,
-0.004172664601355791,
0.0009123616036958992,
0.03798563405871391,
-0.05399610847234726,
0.0339917354285717,
0.040287792682647705,
0.02999783866107464,
-0.0032984542194753885,
0.024329641833901405,
-0.008218884468078613,
-0.03041641227900982,
0.0059734066016972065,
-0.012714199721813202,
-0.011214308440685272,
0.030451294034719467,
-0.0056027937680482864,
-0.05996079370379448,
-0.03938088193535805,
0.03791587054729462,
0.011946813203394413,
0.011502077803015709,
0.014379777945578098,
0.0011848709546029568,
-0.017798136919736862,
0.03503817319869995,
0.002910400740802288,
-0.007189888972789049,
-0.07799437642097473,
0.036834556609392166,
0.019045138731598854,
0.01911490224301815,
0.041159823536872864,
0.02593417838215828,
0.0056115142069756985,
-0.015277968719601631,
-0.037497296929359436,
0.0467059351503849,
0.04482235014438629,
-0.023876186460256577,
0.05162418633699417,
-0.015626780688762665,
0.005184219218790531,
-0.02213212661445141,
-0.05270550400018692,
0.0702158734202385,
-0.04077612981200218,
0.07666889578104019,
-0.04018314927816391,
0.030712902545928955,
0.01810334622859955,
-0.03036409057676792,
0.03137564659118652,
0.04276436194777489,
0.016298243775963783,
-0.027800321578979492,
-0.05758887156844139,
0.03509049490094185,
-0.0003790606278926134,
0.008545896038413048,
0.03446263447403908,
-0.009592331945896149,
0.03160237520933151,
0.0004981472156941891,
0.017928941175341606,
0.020492710173130035,
-0.051135849207639694,
0.000236946958466433,
-0.007765428628772497,
-0.045554857701063156,
0.042171381413936615,
0.03906695172190666,
-0.001962068025022745,
0.01996949128806591,
0.025829533115029335,
-0.00013019138714298606,
-0.05204275995492935,
-0.0012012216029688716,
0.007826470769941807,
0.04572926461696625,
-0.03959016874432564,
0.023701779544353485,
-0.03435799106955528,
-0.003322435077279806,
0.0008126231259666383,
0.01974276266992092,
0.002509266836568713,
-0.006082410458475351,
0.014920436777174473,
0.02848050557076931,
-0.04321781545877457,
-0.05064751207828522,
-0.008358409628272057,
-0.018975377082824707,
-0.055147189646959305,
-0.054519325494766235,
-0.013682154007256031,
0.041090063750743866,
-0.03202094882726669,
-0.017527807503938675,
0.03997386246919632,
-0.049217384308576584,
0.014423379674553871,
-0.00005685228097718209,
0.017588848248124123,
-0.0066099888645112514,
-0.02551560290157795,
0.05298455432057381,
-0.016507530584931374,
-0.06296057999134064,
-0.019864847883582115,
-0.004368871450424194,
-0.017588848248124123,
0.061076994985342026,
-0.03223023563623428,
0.04789189621806145,
-0.038787901401519775,
-0.011005020700395107,
0.02187051624059677,
0.04607807472348213,
-0.05713541805744171,
-0.011763687245547771,
-0.013359501957893372,
0.027992168441414833,
0.010333557613193989,
-0.02340528927743435,
-0.028131693601608276,
-0.009670814499258995,
-0.04185744747519493,
0.03235232084989548,
0.03127100318670273,
-0.03505561500787735,
-0.04970572143793106,
-0.01295836828649044,
-0.040357556194067,
0.046461768448352814,
-0.03767170384526253,
0.018818411976099014,
0.010943979024887085,
-0.06864621490240097,
-0.030032720416784286,
-0.014763470739126205,
0.06529761850833893,
0.01677786000072956,
0.009723136201500893,
-0.08985398709774017,
-0.022044923156499863,
0.020021812990307808,
-0.016507530584931374,
-0.004307829309254885,
0.005663835909217596,
0.027678238227963448,
-0.005476349499076605,
-0.004791805986315012,
0.006653590127825737,
-0.005358625669032335,
-0.013908881694078445,
-0.005245261359959841,
-0.02935253642499447,
-0.03714848682284355,
-0.010882936418056488,
-0.031183799728751183,
0.0035535229835659266,
0.03802051767706871,
-0.014030965976417065,
0.05183347314596176,
0.038997188210487366,
0.0022138666827231646,
-0.01764116995036602,
0.01683018170297146,
0.05696101114153862,
-0.03760194033384323,
-0.024783097207546234,
-0.025829533115029335,
0.004115982446819544,
0.046217598021030426,
-0.008449972607195377,
-0.005580993369221687,
0.0069631608203053474,
-0.08392418175935745,
-0.030503615736961365,
0.02146938256919384,
0.021626347675919533,
0.012286905199289322,
-0.06285593658685684,
-0.027259662747383118,
0.005293223075568676,
0.0024482246953994036,
-0.014257693663239479,
-0.06742537021636963,
0.08622634410858154,
-0.0286549124866724,
0.012295625172555447,
-0.009461527690291405,
-0.061321161687374115,
0.008894708007574081,
0.05378682166337967,
0.02785264328122139,
-0.0382646843791008,
0.0680881142616272,
-0.03463703766465187,
-0.017466764897108078,
-0.022167006507515907,
-0.048589520156383514,
0.013664713129401207,
0.05779816210269928,
-0.014484421350061893,
-0.04632224515080452,
-0.0679834708571434,
-0.0552518330514431,
0.026910850778222084,
0.013542628847062588,
0.018539361655712128,
-0.0017713112756609917,
-0.05085679888725281,
0.07133206725120544,
-0.022411175072193146,
0.029230451211333275,
0.03697407990694046,
-0.04290388524532318,
0.053019434213638306,
-0.018382396548986435,
-0.007647704798728228,
0.04695010557770729,
0.028742114081978798,
-0.04928714781999588,
0.009522569365799427,
0.02249837853014469,
0.03868325799703598,
0.002550688339397311,
-0.07318077236413956,
-0.04841511696577072,
-0.005650755483657122,
0.06557667255401611,
-0.02867235243320465,
0.008537175133824348,
0.020283421501517296,
-0.025428399443626404,
-0.04422936961054802,
-0.048310473561286926,
-0.0033703965600579977,
-0.016934826970100403,
0.03018968552350998,
0.024486606940627098,
-0.019254425540566444,
0.030451294034719467,
-0.024102915078401566,
0.001858514384366572,
0.03353828191757202,
-0.005934165325015783,
-0.0035578832030296326,
0.006252456456422806,
-0.011005020700395107,
-0.0445781834423542,
0.045345570892095566,
0.049217384308576584,
-0.014144329354166985,
0.06494880467653275,
-0.001100938068702817,
0.025009825825691223,
0.012879885733127594,
0.046008311212062836,
-0.0041857450269162655,
0.012932207435369492,
-0.014074566774070263,
0.01308045256882906,
0.013717034831643105,
-0.04443865641951561,
-0.030067600309848785,
-0.028340980410575867,
0.00712448637932539,
-0.045764144510030746,
-0.05246133729815483,
-0.01956835761666298,
0.03379989042878151,
0.012696759775280952,
0.0849008560180664,
0.03889254480600357,
0.05336824804544449,
0.02188795804977417
]
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.