pdf / app.py
changxin's picture
Update app.py
65a043f
raw
history blame
2.95 kB
import streamlit as st
from streamlit.components.v1 import html
st.header('塌ε…₯η½‘ι‘΅εŠε›Ύθ‘¨')
html('''
<iframe src="https://web.powerva.microsoft.com/environments/Default-51a58d6c-4fcf-4b75-8608-d00bf7f244d5/bots/new_bot_830e155fc862429e89683426b31c9bd5/webchat" height="500" frameborder="1" style="width:100%"></iframe>
''',height=520)
html('''
<iframe src="https://d.pbihub.cn/" height="600" frameborder="1" style="width:100%"></iframe>
''',height=620)
html('''
<head><meta charset="utf-8"><title>ζ΅‹θ―•</title></head>
<body>
<div id="main" style="width: 600px;height:400px;"></div>
<script src="http://echarts.baidu.com/build/dist/echarts.js"></script>
<script>
require.config({paths: {echarts: 'http://echarts.baidu.com/build/dist'}});
require(
['echarts','echarts/chart/bar'],
function (ec) {
var myChart = ec.init(document.getElementById('main'));
var option = {
title : {
text: 'ζŸεœ°εŒΊθ’Έε‘ι‡ε’Œι™ζ°΄ι‡',
subtext: 'ηΊ―ε±žθ™šζž„'
},
tooltip : {
trigger: 'axis'
},
legend: {
data:['蒸发量','降水量']
},
toolbox: {
show : true,
feature : {
dataView : {show: true, readOnly: false},
magicType : {show: true, type: ['line', 'bar']},
restore : {show: true},
saveAsImage : {show: true}
}
},
calculable : true,
xAxis : [
{
type : 'category',
data : ['1月','2月','3月','4月','5月','6月','7月','8月','9月','10月','11月','12月']
}
],
yAxis : [
{
type : 'value'
}
],
series : [
{
name:'蒸发量',
type:'bar',
data:[2.0, 4.9, 7.0, 23.2, 25.6, 76.7, 135.6, 162.2, 32.6, 20.0, 6.4, 3.3],
markPoint : {
data : [
{type : 'max', name: 'ζœ€ε€§ε€Ό'},
{type : 'min', name: 'ζœ€ε°ε€Ό'}
]
},
markLine : {
data : [
{type : 'average', name: '平均值'}
]
}
},
{
name:'降水量',
type:'bar',
data:[2.6, 5.9, 9.0, 26.4, 28.7, 70.7, 175.6, 182.2, 48.7, 18.8, 6.0, 2.3],
markPoint : {
data : [
{name : 'εΉ΄ζœ€ι«˜', value : 182.2, xAxis: 7, yAxis: 183},
{name : 'εΉ΄ζœ€δ½Ž', value : 2.3, xAxis: 11, yAxis: 3}
]
},
markLine : {
data : [
{type : 'average', name : '平均值'}
]
}
}
]
};
myChart.setOption(option);
}
);
</script>
</body>
''',height=600)