added method fromList to sparse matrix