I will present two studies from my research on microbial dynamics, addressing processes that occur at the within- and between-host level. The first study examines antibiotic resistance and treatment optimization for bacterial infections, quantifying the crucial role of host immune defenses. The second study presents a multi-strain epidemiological model applied to pneumococcus data before and after vaccination. This framework allows for retrospective inference of strain interactions in co-colonization and vaccine efficacy parameters, and can be useful for comparative analyses.