Added pathstring variable and tuple for storing results globally