Project

General

Profile

1 387 aaronmk
all: _always plots
2 198 aaronmk
	./join VegX VegBIEN
3 199 aaronmk
	./review
4 150 aaronmk
5 223 aaronmk
.SUFFIXES:
6
7 383 aaronmk
_always:
8
.PHONY: _always
9 188 aaronmk
10 633 aaronmk
all = $(wildcard for_review/*) \
11
$(filter-out DwC-% VegX-%,$(wildcard *-VegBIEN.*.csv))
12 196 aaronmk
13 383 aaronmk
clean: _always
14 196 aaronmk
	$(RM) $(all)
15 188 aaronmk
16 423 aaronmk
remake: _always clean all ;
17
18 240 aaronmk
#####
19 198 aaronmk
20 350 aaronmk
bin = ../bin
21
chRoot = $(bin)/ch_root <$< >$@
22 240 aaronmk
23 383 aaronmk
VegX-VegBIEN.organisms.csv: _always
24 612 aaronmk
	$(bin)/in_place $@ $(bin)/simplify_xpath
25 438 aaronmk
	$(bin)/in_place $@ $(bin)/sort 1 0
26 350 aaronmk
27 240 aaronmk
#####
28 212 aaronmk
29 439 aaronmk
vegxVegbienGenMaps := VegX-VegBIEN.plots.csv VegX-VegBIEN.stems.csv
30 197 aaronmk
31 438 aaronmk
plots: _always $(vegxVegbienGenMaps) ;
32
33
all += $(vegxVegbienGenMaps)
34
35
VegX-VegBIEN.plots.csv: VegX-VegBIEN.organisms.csv
36 188 aaronmk
	env \
37 439 aaronmk
left_in_root='/*s/individualOrganismObservation/*ID->/*s/plotObservation' \
38
left_out_root='/*s/plotObservation' \
39 525 aaronmk
right_in_root='/taxonoccurrence/*_id/locationevent' \
40
right_out_root='/locationevent' \
41 439 aaronmk
$(chRoot)
42
43
VegX-VegBIEN.stems.csv: VegX-VegBIEN.organisms.csv
44
	env \
45 441 aaronmk
left_in_root='/*s/individualOrganismObservation->/*s/individualOrganismObservation[relatedItem[relationshipType=stemParent]/relatedItemID]' \
46 504 aaronmk
left_out_root='/*s/individualOrganismObservation[relatedItem[relationshipType=stemParent]/relatedItemID]' \
47 681 aaronmk
right_in_root='/taxonoccurrence/aggregateoccurrence/*_id/plantobservation/stemobservation' \
48 673 aaronmk
right_out_root='/stemobservation' \
49 439 aaronmk
$(chRoot)