how to create input file for collaborative filtering http://spark.apache.org/docs/latest/mllib-collaborative-filtering.html
https://github.com/apache/spark/blob/master/data/mllib/als/test.data

I want to find missing value in a matrix based on past matrices

But I find that the test.data are not matrices, instead a long list of 3 columns

How do I understand test.data and create my own data?

Which value represent missing value?

and how to understand the result, which value represent result?
This data set is in a sparse format. Most ratings are unknown, which is a common scenario in recommender systems. This data format is much smaller due to leaving out all the unknowns. You can interpret this data as follows:

user, item, rating


What this means is that user U has rated item I with rating R. Every UxI combination not in your dataset is unknown and has to be predicted using collaborative filtering.