Maybe someone else can offer an easier solution, but I know this is possible with the ChartJS StackedBarChart widget. I would recommend setting up your domain model like I have done. You will need to create a pretty complicated microflow that creates all of the objects for your chart. In the microflow you will need to retrieve all of your investment data from the database and make use of loops and variables to create the objects. For this particular case, your microflow will create 1 MultiSeriesChart object, 4 MultiSeriesDataSet objects, and 24 DataPoint objects. The most important part will be to create placeholder DataPoints for all of the years for which there are no investments.
Here is the end result:
Here is my domain model structure:
Here is my page in the modeler:
Here are the settings for the widget:
And here is the data that you will need to create in the microflow "DS_MultiSeriesChart":
One difficult aspect will be dynamically setting the color values for a variable number of data sets. In the past, I have created an entity called Color that can store that data.