зеркало из https://github.com/microsoft/SandDance.git
update streamlit usage readme (#684)
* update streamlit usage readme * dependabot update
This commit is contained in:
Родитель
7551cb045c
Коммит
8a84944abb
|
@ -20,9 +20,15 @@ df = pd.DataFrame(
|
|||
np.random.randn(20, 3),
|
||||
columns=['a', 'b', 'c'])
|
||||
|
||||
sdEvent = sanddance(df)
|
||||
#make sure to use a key to prevent refreshing after an event
|
||||
sdEvent = sanddance(df, key='sd1')
|
||||
|
||||
#if sdEvent is not None and contains a cubeClick >= 0, display the data row
|
||||
if sdEvent is not None and 'cubeClick' in sdEvent and sdEvent['cubeClick'] is not None and sdEvent['cubeClick'] >= 0:
|
||||
st.write(df.iloc[sdEvent['cubeClick']])
|
||||
else:
|
||||
st.write("No cubeClick event")
|
||||
|
||||
st.write(sdEvent)
|
||||
```
|
||||
The return value is a dictionary of visual interaction events such as selections.
|
||||
|
||||
|
|
|
@ -2101,9 +2101,9 @@
|
|||
}
|
||||
},
|
||||
"node_modules/@babel/traverse": {
|
||||
"version": "7.23.0",
|
||||
"resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.0.tgz",
|
||||
"integrity": "sha512-t/QaEvyIoIkwzpiZ7aoSKK8kObQYeF7T2v+dazAYCb8SXtp58zEVkWW7zAnju8FNKNdr4ScAOEDmMItbyOmEYw==",
|
||||
"version": "7.23.2",
|
||||
"resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.2.tgz",
|
||||
"integrity": "sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"@babel/code-frame": "^7.22.13",
|
||||
|
@ -21142,9 +21142,9 @@
|
|||
}
|
||||
},
|
||||
"@babel/traverse": {
|
||||
"version": "7.23.0",
|
||||
"resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.0.tgz",
|
||||
"integrity": "sha512-t/QaEvyIoIkwzpiZ7aoSKK8kObQYeF7T2v+dazAYCb8SXtp58zEVkWW7zAnju8FNKNdr4ScAOEDmMItbyOmEYw==",
|
||||
"version": "7.23.2",
|
||||
"resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.2.tgz",
|
||||
"integrity": "sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"@babel/code-frame": "^7.22.13",
|
||||
|
|
Загрузка…
Ссылка в новой задаче