Multipage personality test: Patient page and Pro page

Hello everyone,

I made a personality test in Python (used for mental health), I was able to deploy the App with the functions that run all the questions from de .CSV and made variables for each answer (True or False radio buttons). Some code I made, converts the results through scales taking scores from 2 other .CSVs, and gives back all the interpretations.

I would need different pages, one for the patient, where he takes the test, and the other one for the professional where he sees all the results.

-Patient page:
Test of radio buttons True or False and some other data like name and age…
The answers are “stored” like this: a1 = 1; a2 = 0; a3 = 0…
Each scale adds different answers: a1 + a3 + a10 = ScaleA result. a2 + a4 + a15 = ScaleB…
With this brute result you get the final results from the other .CSVs

-Pro page:
You see everything ordered: brute results of all scales, final results of all scales, graphs and text interpretations for each range of results.

  1. Is there a way to store the results from the tests and the graphs I make on the internet?

  2. Is there a way to download some kind of document with the final results and charts?

  3. Can I put user name and password to log into the professional’s page?

  4. Is it possible to stop the patient’s page from refreshing when you go to the pro’s page? So the radio buttons of every question remain as they were when the patient answered.

I have read and seen videos about Session State, Cache, control flow, Heroku… but sincerely, I don’t understand if what I want to achieve is possible. I am anxious about having to use another framework. In that case, I would really appreciate if someone could tell me what they think is the best option for this project.

I am loving Streamlit, and I will keep on using it for other projects, but would love to keep on with the present one.

Thanks very much in advance!!

Hi @Neteresy, welcome to the forum!

All of the functionality that you have described is possible using Streamlit. I would encourage you to start building and search for answers online when you get stuck. To help out, I’ve provided a few links I think may be helpful to you while you build.

For user authentication, consider Streamlit Authenticator

For saving data across multiple sessions, consider working with online databases.

For downloading files, my favorite tool is st.download_button in conjunction with something like openpyxl.

For saving settings when navigating to different pages, you may find st.session_state really helpful.

And for when you need some help – come back, search through the forums, or ask! Make sure your question conforms to the community guidelines.

Happy Streamliting! :balloon:

2 Likes

Thank you very much Tyler! I will continue right away. See you later.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.