
        PLOT = document.getElementById('saturation_plot2');

var trace1 = {
    x: [0.05000000074505806, 0.10000000149011612, 0.20000000298023224, 0.30000001192092896, 0.4000000059604645, 0.5, 0.6000000238418579, 0.699999988079071, 0.800000011920929, 0.8999999761581421, 1.0],
    y: [1407, 2484, 3989, 4966, 5644, 6140, 6521, 6828, 7082, 7302, 7495],
    text: ['0.05', '0.10', '0.20', '0.30', '0.40', '0.50', '0.60', '0.70', '0.80', '0.90', '1.00'],
    hovertemplate: 'Sampling ratio=%{text}<br>Unique reads number per bin=%{y}<extra></extra>',
    marker:{
        color:"#1F77B4",
        // size:10,
        // maxdisplayed:11,
        // standoff:4
    },
    mode:"markers+lines",
}
                
var data = [trace1]
        
        
        const yMax = Math.max(...trace1.y);
            var layout = {
            //title: {text:'','font':{'color':'#CECECE', 'size':20}, 'x':0.05, 'xanchor':'center', 'y':0.98, 'yanchor':'top'},
            yaxis: {'title':{'text':'Unique reads number per bin 50','font':{'color':'#080808', 'size':18}},'showgrid': true,'showticklabels': true,
            range: [0, yMax*1.05],
                    'showline': true,
                    fixedrange: true,
                    // 'mirror': 'ticks',
                    // 'autotick': false,
                    // 'ticks': 'outside',
                    // 'dtick': 0.025,
                },
                
            xaxis: {'title':{'text':'Sampling ratio','font':{'color':'#080808', 'size':18}},'showgrid': true, 'showticklabels': true, 'zeroline': false,
                'showline': true,
                fixedrange: true,
                // range: [0, maxX*1.05], // 设置坐标轴范围为0到1
                dtick : 0.2,
                //tickformat: '.1', // 将刻度显示为浮点数形式，保留两位小数
                //tickvals: [0, maxX/5, maxX*2/5,maxX*3/5,maxX*4/5, maxX], // 设置自定义刻度值
                //ticktext: ['0', '0.2', '0.4', '0.6', '0.8', '1'], // 设置自定义刻度文本
              
            
                // 'mirror': 'ticks',
            },
            margin: {'l' : 100, 't' : 30, 'r' : 20, 'b' : 50},
            showlegend: false,
            // dragmode:"pan",
            // plot_bgcolor:"black",
            paper_bgcolor:"#FFF3",
            // images: 
            }
          
        
        
        var config = {
            toImageButtonOptions: {
                format: 'png', // one of png, svg, jpeg, webp
                filename: 'custom_image',
                height: 600,
                width: 600,
                scale: 5 // Multiply title/legend/axis/canvas sizes by this factor
            },
            displayModeBar: false,
            scrollZoom:false,
            displaylogo:false,
            // modeBarButtonsToRemove:["hoverClosestCartesian","hoverCompareCartesian","toggleSpikelines","autoScale2d","lasso2d","select2d"]
        };
        
        Plotly.newPlot(PLOT, data, layout,config);
        