clear all
clc
close all

% convert length-weighted adjacency matrices from .mat to .txt files

sLength = load('Day0_AdjacencyMatrices/Tumour 1/AdjacencyMatrixLength.mat') % Tumour 1, full network - change for other tumours and largest connected components
CLength= struct2cell(sLength)
dlmwrite('Day0_AdjacencyMatrices/Tumour 1/AdjacencyMatrixLengths.txt', CLength, 'delimiter','\t')

% convert diameter-weighted adjacency matrices from .mat to .txt files

sDiameter = load('Day0_AdjacencyMatrices/Tumour 1/AdjacencyMatrixDiameter.mat') % Tumour 1, full network - adjust for other tumours and largest connected components
CDiameter= struct2cell(sDiameter)
dlmwrite('Day0_AdjacencyMatrices/Tumour 1/AdjacencyMatrixDiameters.txt', CDiameter, 'delimiter','\t')