wrapfig does not wrap text. I have been looking for an answer for about 3h now, tried everything from changing amount of spaces, copy-pasting code that should be working, etc., but nothing is functioning. All I get is a figure somewhere in my text, sometimes not even in the order it should be appearing in.
Here's the important bits of code:
\documentclass[11pt,a4paper]{article}
% all packages:
\usepackage{blindtext}
\usepackage{wrapfig}
\usepackage{graphicx}
\graphicspath{ {images} }
\usepackage{amsmath}
\usepackage{gensymb}
\usepackage[utf8]{inputenc}
\usepackage[margin=2cm]{geometry}
\usepackage{ragged2e}
\usepackage[dvipsnames]{xcolor}
\begin{document}
% bunch of stuf that works as it should
\newpage
\section*{Data Analysis}
\subsection*{Raw data}
\begin{wrapfigure}{l}{0.4\textwidth} % my original wrapfig (it's not where it should be, I put it here because I read that maybe \blindtext and \lipsum messed with wrapfg so I put it above some of my own text.)
\center
\includegraphics[width=0.4\textwidth]{1Ttr}
\end{wrapfigure}
\indent
Due to the high amount of data collected, I will not be presenting each data point as a set of numbers, but only their graphs versus time. To see the .odt with all raw data, follow the link in the footnote.\footnote{[Insert link]}
\subsubsection*{Run 1}
\begin{wrapfigure}{r}{0.5\linewidth} %some random code I copied from a different thread
\centering
\rule{0.9\linewidth}{0.75\linewidth}
\caption{Dummy figure.}
\label{fig:myfig}
\end{wrapfigure}
\blindtext
\end{document}
And here's what I get: (The figures appear, but one not where it should, and both do not wrap text)
Is there any way to get this working? Any help would be appreciated, I don't really want to be up until 2AM again tomorrow..
Edit: here's the document with text replaced with placeholders. @john-kormylo's solution works by itself, but not in the full document.
\documentclass[11pt,a4paper]{article}
\usepackage{gobble}
\usepackage{blindtext}
\usepackage{wrapfig}
\usepackage{graphicx}
\graphicspath{ {images} }
\usepackage{amsmath}
\usepackage{gensymb}
\usepackage[utf8]{inputenc}
\usepackage[margin=2cm]{geometry}
\usepackage{ragged2e}
\usepackage[dvipsnames]{xcolor}
\author{personal info}
\title{\Huge\textbf {Topic of research}}
\date{}
\begin{document}
\maketitle
\newpage
\section*{Introduction}
\indent
\blindtext
\section*{Research Question}
\center
\large\textit{\textbf{Topic of research}}
\justify
\section*{Experiment}
\subsection*{Variables}
\begin{itemize}
\item item
\item item
\item item
\end{itemize}
\subsection*{Apparatus}
\textcolor{red}{PUT BLENDER RENDER HERE}% this works when I tried with a filler image
\newpage
\subsection*{Method}
\begin{enumerate}
\item item
\item item
\item item
\begin{itemize}
\item \small{change procedure if...}
\end{itemize}
\item item
\item item
\item item
\end{enumerate}
\subsection*{Personal Protection}
\begin{itemize}
\item item
\item item
\item item
\item item
\end{itemize}
\subsection*{Data collection}
\indent % repeated to match original
How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used How to collect data, what was used
\newpage
\section*{Data Analysis}
\subsection*{Raw data}\leavevmode\par% gobble \@afterheading
\indent
Due to the high amount of data collected, I will not be presenting each data point as a set of numbers, but only their graphs versus time. To see the .odt with all raw data, follow the link in the footnote.\footnote{[Insert link]}
\subsubsection*{Run 1}
\begin{wrapfigure}[8]{l}{0.4\textwidth}
\vspace{-30pt}
\center
\includegraphics[width=0.4\textwidth]{1Ttr}
\end{wrapfigure}
\blindtext
\end{document}