-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdd_field_visit.R
105 lines (91 loc) · 3.26 KB
/
dd_field_visit.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
field_visit<-
list(
data.frame(
Variable="FieldVisitID",
Label="Field Visit Identifier",
Definition="System-provided Field Visit identifier",
Type="Integer",
Mandatory="System-assigned"),
data.frame(
Variable="FieldVisitCode",
Label="Field Visit Code",
Definition="User-provided Field Visit code",
Type="String",
Mandatory="Yes"),
data.frame(
Variable="FieldVisitCrossReferenceID",
Label="Field Visit Cross Identifier",
Definition="The identifier of the Field Visit under another nomenclature system.
For example, in a different database or document where other identification
for the same Field Visit is used",
Type="String",
Mandatory="No"),
data.frame(
Variable="FieldVisitCrossReferenceIDOrigin",
Label="Field Visit Cross Identifier Origin",
Definition="The location/database/document where other identification
for the same Field Visit is used",
Type="String",
Mandatory="No"),
data.frame(
Variable="FieldVisitLeader",
Label="Field Visit Leader",
Definition="The name of the leader of the Field Visit",
Type="Single selection",
Mandatory="Yes"),
# data.frame(
# Variable="FieldVisitType",
# Label="Field Visit Type",
# Definition="The type of Field Visit (e.g., 'Market', 'Free-ranging', 'Ranger patrolling').
# More than one Field Visit type can be selected",
# Type="Multiple selection",
# Mandatory="Yes"),
# data.frame(
# Variable="FieldVisitWho",
# Label="Field Visit People Participating",
# Definition="Mention who is participating in the Field Visit" ,
# Type="String",
# Mandatory="Yes"),
data.frame(
Variable="FieldVisitWhere",
Label="Field Visit Places Visited",
Definition="Briefly describe the places to be visited during the Field Visit" ,
Type="String",
Mandatory="Yes"),
# data.frame(
# Variable="FieldVisitWhat",
# Label="Field Visit Activities Conducted",
# Definition="Briefly describe the activities conducted during the Field Visit" ,
# Type="String",
# Mandatory="Yes"),
#
# data.frame(
# Variable="FieldVisitPurpose",
# Label="Field Visit Purpose",
# Definition="Briefly describe the purpose of the Field Visit" ,
# Type="String",
# Mandatory="Yes"),
data.frame(
Variable="FieldVisitStartDate",
Label="Field Visit Start Date",
Definition="The date the Field Visit started" ,
Type="Date",
Mandatory="Yes"),
data.frame(
Variable="FieldVisitEndDate",
Label="Field Visit End Date",
Definition="The date the Field Visit ended or the anticipated ending date" ,
Type="Date",
Mandatory="Yes"))
field_visit<-
field_visit %>% bind_rows() |>
gt::gt() %>%
gt::tab_options(table.font.size = 8) %>%
gt::cols_width(Variable ~ gt::pct(22),
Label ~ gt::pct(20),
Definition ~ gt::pct(30),
Type~ gt::pct(13),
Mandatory~ gt::pct(15)) %>%
gt::tab_style(
style = cell_text(size = px(15), weight = "bold"),
locations = cells_column_labels())