Robinlovelace / cyclemon

Analyse cycling potential in Monmouthshire
3 stars 1 forks source link

Plumb PCT model into Makefile #4

Open fiftysevendegreesofrad opened 3 years ago

fiftysevendegreesofrad commented 3 years ago

Locations to edit are the two lines marked 'todo' in the makefile.

Alternatively I can do that if you provide me with a command line call to R that can make ../output-data/towns/%/rnet_pct_dutch.shp from ../input-data/towns/%/trip-origin-zones.csv, ../input-data/towns/%/destinations.shp and ../input-data/towns/%/cycle-buffer.shp

Robinlovelace commented 3 years ago

Hi @fiftysevendegreesofrad thanks for opening this issue and sorry for the very slow reply! I think it is possible and can take a look. First question though, is the Makefile even working in its current state? Paraphrasing a previous conversation we had:

Update on the Makefile, this is the message I get after following the instructions:

cd code
make monmouth-town-all

Generated this error message:

make: * No rule to make target 'monmouth-town-all'. Stop.

Your response was along the lines of makefiles not being great and to look at line 77 of the makefile:

%-town-all: %-town-directories %-town-contents ;

which says monmouth-town-all depends on monmouth-town-directories and monmouth-town-contents

I think we should get the Makefile work before adding to it. Sound like a plan? Apologies if it is working already but last time I tried it it was failing...

fiftysevendegreesofrad commented 3 years ago

That is the trouble with makefiles, they're not very good at telling you which line failed as they test all possible ways to build something, so when one possible way doesn't work it's not really news to Make (even if you as dev know it's the only possible way)

I don't have time this week but if you write me a command line call to R that can make that can make rnet_pct_dutch.shp from ../input-data/towns/%/trip-origin-zones.csv, ../input-data/towns/%/destinations.shp and ../input-data/towns/%/cycle-buffer.shp (where % is the name of the town in question) I can wire that into the makefile when I fix it?

Robinlovelace commented 3 years ago

if you write me a command line call to R that can make that can make rnet_pct_dutch.shp from ../input-data/towns/%/trip-origin-zones.csv, ../input-data/towns/%/destinations.shp and ../input-data/towns/%/cycle-buffer.shp (where % is the name of the town in question) I can wire that into the makefile when I fix it?

Sounds like a plan. One for next week!