Corrected an issue related to the colorbar plot

This commit is contained in:
José Julián Sierra Álvarez 2024-09-19 20:59:32 -06:00 committed by GitHub
parent f251b8cebc
commit ad97065360
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 9 deletions

6
app.jl
View File

@ -134,7 +134,8 @@ rgb_ViridisPalette =reinterpret(ColorTypes.RGB24, ViridisPalette)
SaveBitmap(joinpath("public", "TrIQ_$(floor(Int, Nmass)).bmp"),TrIQ(slice, Int(triqColor), triqProb),ViridisPalette)
testT = "/TrIQ_$(floor(Int, Nmass)).bmp" # we define the starting value of the images
msgtriq = "TrIQ image with the Nmass of $(floor(Int, Nmass))"
Colorbar(fig[1, 1], colormap = rgb_ViridisPalette, limits = (0, maximum(TrIQ(slice, Int(triqColor), triqProb))))
ticks = round.(range(0, stop = maximum(TrIQ(slice, Int(triqColor), triqProb)), length = 10), digits = 2)
Colorbar(fig[1, 1], colormap = rgb_ViridisPalette, limits = (0, maximum(TrIQ(slice, Int(triqColor), triqProb))),ticks = ticks, label = "Intensity")
save("public/colorbar_TrIQ_$(floor(Int, Nmass)).png", fig)
msg = "The file has been created successfully inside the 'public' folder of the app."
colorbarT = "/colorbar_TrIQ_$(floor(Int, Nmass)).png"
@ -143,7 +144,8 @@ rgb_ViridisPalette =reinterpret(ColorTypes.RGB24, ViridisPalette)
SaveBitmap(joinpath("public", "$(floor(Int, Nmass)).bmp"),IntQuant(slice),ViridisPalette)
test = "/$(floor(Int, Nmass)).bmp" # we define the starting value of the images
msgimg = "image with the Nmass of $(floor(Int, Nmass))"
Colorbar(fig[1, 1], colormap = rgb_ViridisPalette, limits = (0, maximum(slice)))
ticks = round.(range(0, stop = maximum(slice), length = 10), digits = 2)
Colorbar(fig[1, 1], colormap = rgb_ViridisPalette, limits = (0, maximum(slice)),ticks = ticks, label = "Intensity")
save("public/colorbar_$(floor(Int, Nmass)).png", fig)
msg = "The file has been created successfully inside the 'public' folder of the app."
colorbar = "/colorbar_$(floor(Int, Nmass)).png"

View File

@ -17,15 +17,10 @@
<p id="i7brk">full route: {{full_route}} {{warning_fr}}</p>
<div class="row">
<div class="st-col col-12 col-sm">
<q-input id="icc9d" v-model="Nmass" :dense="true" label="Mass-to-charge ratio of interest" type="number" :rules="[
val => val >= 0 || 'Need positive mass values',
]"></q-input>
<q-input id="icc9d" v-model="Nmass" :dense="true" label="Mass-to-charge ratio of interest" type="number" :rules="[ val => !!val || '* Required', val => val >= 0 &amp;&amp; val <= 2000 || 'Need positive mass values',]"></q-input>
</div>
<div class="st-col col-12 col-sm">
<q-input id="iqt3l" step="0.01" v-model="Tol" :dense="true" label="Mass-to-charge ratio Tolerance" type="number" :rules="[
val => !!val || '* Required',
val => val >= 0 &amp;&amp; val <= 1 || 'Needs to be in range between 0 and 1',
]"></q-input>
<q-input id="iqt3l" step="0.01" v-model="Tol" :dense="true" label="Mass-to-charge ratio Tolerance" type="number" :rules="[val => !!val || '* Required', val => val >= 0 &amp;&amp; val <= 1 || 'Needs to be in range between 0 and 1',]"></q-input>
</div>
</div>
<div class="row">