galaaz 0.4.6 → 0.5.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (181) hide show
  1. checksums.yaml +5 -5
  2. data/README.md +3575 -118
  3. data/Rakefile +21 -4
  4. data/bin/gknit +152 -6
  5. data/bin/gknit-draft +105 -0
  6. data/bin/gknit-draft.rb +28 -0
  7. data/bin/gknit_Rscript +127 -0
  8. data/bin/grun +27 -1
  9. data/bin/gstudio +47 -4
  10. data/bin/{gstudio.rb → gstudio_irb.rb} +0 -0
  11. data/bin/gstudio_pry.rb +7 -0
  12. data/blogs/galaaz_ggplot/galaaz_ggplot.Rmd +3 -12
  13. data/blogs/galaaz_ggplot/galaaz_ggplot.html +77 -222
  14. data/blogs/galaaz_ggplot/galaaz_ggplot.md +4 -31
  15. data/blogs/galaaz_ggplot/galaaz_ggplot.pdf +0 -0
  16. data/blogs/galaaz_ggplot/galaaz_ggplot_files/figure-html/midwest_rb.png +0 -0
  17. data/blogs/galaaz_ggplot/galaaz_ggplot_files/figure-html/scatter_plot_rb.png +0 -0
  18. data/blogs/galaaz_ggplot/midwest.Rmd +1 -9
  19. data/blogs/gknit/gknit.Rmd +232 -123
  20. data/blogs/{dev/dev.html → gknit/gknit.html} +1897 -33
  21. data/blogs/gknit/gknit.pdf +0 -0
  22. data/blogs/gknit/lst.rds +0 -0
  23. data/blogs/gknit/stats.bib +27 -0
  24. data/blogs/manual/lst.rds +0 -0
  25. data/blogs/manual/manual.Rmd +1893 -47
  26. data/blogs/manual/manual.html +3153 -347
  27. data/blogs/manual/manual.md +3575 -118
  28. data/blogs/manual/manual.pdf +0 -0
  29. data/blogs/manual/manual.tex +4026 -0
  30. data/blogs/manual/manual_files/figure-html/bubble-1.png +0 -0
  31. data/blogs/manual/manual_files/figure-html/diverging_bar.png +0 -0
  32. data/blogs/manual/manual_files/figure-latex/bubble-1.png +0 -0
  33. data/blogs/manual/manual_files/figure-latex/diverging_bar.pdf +0 -0
  34. data/blogs/{dev → manual}/model.rb +0 -0
  35. data/blogs/nse_dplyr/nse_dplyr.Rmd +849 -0
  36. data/blogs/nse_dplyr/nse_dplyr.html +878 -0
  37. data/blogs/nse_dplyr/nse_dplyr.md +1198 -0
  38. data/blogs/nse_dplyr/nse_dplyr.pdf +0 -0
  39. data/blogs/oh_my/oh_my.html +274 -386
  40. data/blogs/oh_my/oh_my.md +208 -205
  41. data/blogs/ruby_plot/ruby_plot.Rmd +64 -84
  42. data/blogs/ruby_plot/ruby_plot.html +235 -208
  43. data/blogs/ruby_plot/ruby_plot.md +239 -34
  44. data/blogs/ruby_plot/ruby_plot.pdf +0 -0
  45. data/blogs/ruby_plot/ruby_plot_files/figure-html/dose_len.png +0 -0
  46. data/blogs/ruby_plot/ruby_plot_files/figure-html/facet_by_delivery.png +0 -0
  47. data/blogs/ruby_plot/ruby_plot_files/figure-html/facet_by_dose.png +0 -0
  48. data/blogs/ruby_plot/ruby_plot_files/figure-html/facets_by_delivery_color.png +0 -0
  49. data/blogs/ruby_plot/ruby_plot_files/figure-html/facets_by_delivery_color2.png +0 -0
  50. data/blogs/ruby_plot/ruby_plot_files/figure-html/facets_with_decorations.png +0 -0
  51. data/blogs/ruby_plot/ruby_plot_files/figure-html/facets_with_jitter.png +0 -0
  52. data/blogs/ruby_plot/ruby_plot_files/figure-html/facets_with_points.png +0 -0
  53. data/blogs/ruby_plot/ruby_plot_files/figure-html/final_box_plot.png +0 -0
  54. data/blogs/ruby_plot/ruby_plot_files/figure-html/final_violin_plot.png +0 -0
  55. data/blogs/ruby_plot/ruby_plot_files/figure-html/violin_with_jitter.png +0 -0
  56. data/examples/Bibliography/master.bib +50 -0
  57. data/examples/Bibliography/stats.bib +72 -0
  58. data/examples/islr/ch2.spec.rb +1 -1
  59. data/examples/islr/ch3_boston.rb +4 -4
  60. data/examples/islr/x_y_rnorm.jpg +0 -0
  61. data/examples/latex_templates/Test-acm_article/Makefile +16 -0
  62. data/examples/latex_templates/Test-acm_article/Test-acm_article.Rmd +65 -0
  63. data/examples/latex_templates/Test-acm_article/acm_proc_article-sp.cls +1670 -0
  64. data/examples/latex_templates/Test-acm_article/sensys-abstract.cls +703 -0
  65. data/examples/latex_templates/Test-acm_article/sigproc.bib +59 -0
  66. data/examples/latex_templates/Test-acs_article/Test-acs_article.Rmd +260 -0
  67. data/examples/latex_templates/Test-acs_article/Test-acs_article.pdf +0 -0
  68. data/examples/latex_templates/Test-acs_article/acs-Test-acs_article.bib +11 -0
  69. data/examples/latex_templates/Test-acs_article/acs-my_output.bib +11 -0
  70. data/examples/latex_templates/Test-acs_article/acstest.bib +17 -0
  71. data/examples/latex_templates/Test-aea_article/AEA.cls +1414 -0
  72. data/examples/latex_templates/Test-aea_article/BibFile.bib +0 -0
  73. data/examples/latex_templates/Test-aea_article/Test-aea_article.Rmd +108 -0
  74. data/examples/latex_templates/Test-aea_article/Test-aea_article.pdf +0 -0
  75. data/examples/latex_templates/Test-aea_article/aea.bst +1269 -0
  76. data/examples/latex_templates/Test-aea_article/multicol.sty +853 -0
  77. data/examples/latex_templates/Test-aea_article/references.bib +0 -0
  78. data/examples/latex_templates/Test-aea_article/setspace.sty +546 -0
  79. data/examples/latex_templates/Test-amq_article/Test-amq_article.Rmd +256 -0
  80. data/examples/latex_templates/Test-amq_article/Test-amq_article.pdf +0 -0
  81. data/examples/latex_templates/Test-amq_article/Test-amq_article.pdfsync +3397 -0
  82. data/examples/latex_templates/Test-amq_article/pics/Figure2.pdf +0 -0
  83. data/examples/latex_templates/Test-ams_article/Test-ams_article.Rmd +215 -0
  84. data/examples/latex_templates/Test-ams_article/amstest.bib +436 -0
  85. data/examples/latex_templates/Test-asa_article/Test-asa_article.Rmd +153 -0
  86. data/examples/latex_templates/Test-asa_article/Test-asa_article.pdf +0 -0
  87. data/examples/latex_templates/Test-asa_article/agsm.bst +1353 -0
  88. data/examples/latex_templates/Test-asa_article/bibliography.bib +233 -0
  89. data/examples/latex_templates/Test-ieee_article/IEEEtran.bst +2409 -0
  90. data/examples/latex_templates/Test-ieee_article/IEEEtran.cls +6346 -0
  91. data/examples/latex_templates/Test-ieee_article/Test-ieee_article.Rmd +175 -0
  92. data/examples/latex_templates/Test-ieee_article/Test-ieee_article.pdf +0 -0
  93. data/examples/latex_templates/Test-ieee_article/mybibfile.bib +20 -0
  94. data/examples/latex_templates/Test-rjournal_article/RJournal.sty +335 -0
  95. data/examples/latex_templates/Test-rjournal_article/RJreferences.bib +18 -0
  96. data/examples/latex_templates/Test-rjournal_article/RJwrapper.pdf +0 -0
  97. data/examples/latex_templates/Test-rjournal_article/Test-rjournal_article.Rmd +52 -0
  98. data/examples/latex_templates/Test-springer_article/Test-springer_article.Rmd +65 -0
  99. data/examples/latex_templates/Test-springer_article/Test-springer_article.pdf +0 -0
  100. data/examples/latex_templates/Test-springer_article/bibliography.bib +26 -0
  101. data/examples/latex_templates/Test-springer_article/spbasic.bst +1658 -0
  102. data/examples/latex_templates/Test-springer_article/spmpsci.bst +1512 -0
  103. data/examples/latex_templates/Test-springer_article/spphys.bst +1443 -0
  104. data/examples/latex_templates/Test-springer_article/svglov3.clo +113 -0
  105. data/examples/latex_templates/Test-springer_article/svjour3.cls +1431 -0
  106. data/examples/misc/moneyball.rb +1 -1
  107. data/examples/misc/subsetting.rb +37 -37
  108. data/examples/rmarkdown/svm-rmarkdown-anon-ms-example/svm-rmarkdown-anon-ms-example.Rmd +73 -0
  109. data/examples/rmarkdown/svm-rmarkdown-anon-ms-example/svm-rmarkdown-anon-ms-example.pdf +0 -0
  110. data/examples/rmarkdown/svm-rmarkdown-article-example/svm-rmarkdown-article-example.Rmd +382 -0
  111. data/examples/rmarkdown/svm-rmarkdown-article-example/svm-rmarkdown-article-example.pdf +0 -0
  112. data/examples/rmarkdown/svm-rmarkdown-beamer-example/svm-rmarkdown-beamer-example.Rmd +164 -0
  113. data/examples/rmarkdown/svm-rmarkdown-beamer-example/svm-rmarkdown-beamer-example.pdf +0 -0
  114. data/examples/rmarkdown/svm-rmarkdown-cv/svm-rmarkdown-cv.Rmd +92 -0
  115. data/examples/rmarkdown/svm-rmarkdown-cv/svm-rmarkdown-cv.pdf +0 -0
  116. data/examples/rmarkdown/svm-rmarkdown-syllabus-example/attend-grade-relationships.csv +482 -0
  117. data/examples/rmarkdown/svm-rmarkdown-syllabus-example/svm-rmarkdown-syllabus-example.Rmd +280 -0
  118. data/examples/rmarkdown/svm-rmarkdown-syllabus-example/svm-rmarkdown-syllabus-example.pdf +0 -0
  119. data/examples/rmarkdown/svm-xaringan-example/svm-xaringan-example.Rmd +386 -0
  120. data/lib/R_interface/r.rb +2 -2
  121. data/lib/R_interface/r_libs.R +6 -1
  122. data/lib/R_interface/r_methods.rb +12 -2
  123. data/lib/R_interface/rdata_frame.rb +8 -17
  124. data/lib/R_interface/rindexed_object.rb +1 -2
  125. data/lib/R_interface/rlist.rb +1 -0
  126. data/lib/R_interface/robject.rb +20 -23
  127. data/lib/R_interface/rpkg.rb +15 -6
  128. data/lib/R_interface/rsupport.rb +13 -19
  129. data/lib/R_interface/ruby_extensions.rb +14 -18
  130. data/lib/R_interface/rvector.rb +0 -12
  131. data/lib/gknit.rb +2 -0
  132. data/lib/gknit/draft.rb +105 -0
  133. data/lib/gknit/knitr_engine.rb +6 -37
  134. data/lib/util/exec_ruby.rb +22 -84
  135. data/lib/util/inline_file.rb +7 -3
  136. data/specs/figures/bg.jpeg +0 -0
  137. data/specs/figures/bg.png +0 -0
  138. data/specs/figures/bg.svg +2 -2
  139. data/specs/figures/dose_len.png +0 -0
  140. data/specs/figures/no_args.jpeg +0 -0
  141. data/specs/figures/no_args.png +0 -0
  142. data/specs/figures/no_args.svg +2 -2
  143. data/specs/figures/width_height.jpeg +0 -0
  144. data/specs/figures/width_height.png +0 -0
  145. data/specs/figures/width_height_units1.jpeg +0 -0
  146. data/specs/figures/width_height_units1.png +0 -0
  147. data/specs/figures/width_height_units2.jpeg +0 -0
  148. data/specs/figures/width_height_units2.png +0 -0
  149. data/specs/r_dataframe.spec.rb +184 -11
  150. data/specs/r_list.spec.rb +4 -4
  151. data/specs/r_list_apply.spec.rb +11 -10
  152. data/specs/ruby_expression.spec.rb +3 -11
  153. data/specs/tmp.rb +106 -34
  154. data/version.rb +1 -1
  155. metadata +96 -33
  156. data/bin/gknit_old_r +0 -236
  157. data/blogs/dev/dev.Rmd +0 -77
  158. data/blogs/dev/dev.md +0 -87
  159. data/blogs/dev/dev_files/figure-html/bubble-1.png +0 -0
  160. data/blogs/dev/dev_files/figure-html/diverging_bar. +0 -0
  161. data/blogs/dev/dev_files/figure-html/diverging_bar.png +0 -0
  162. data/blogs/dplyr/dplyr.rb +0 -63
  163. data/blogs/galaaz_ggplot/galaaz_ggplot.aux +0 -43
  164. data/blogs/galaaz_ggplot/galaaz_ggplot.log +0 -640
  165. data/blogs/galaaz_ggplot/galaaz_ggplot.out +0 -10
  166. data/blogs/galaaz_ggplot/galaaz_ggplot.tex +0 -481
  167. data/blogs/galaaz_ggplot/midwest.png +0 -0
  168. data/blogs/galaaz_ggplot/scatter_plot.png +0 -0
  169. data/blogs/ruby_plot/ruby_plot.Rmd_external_figs +0 -662
  170. data/blogs/ruby_plot/ruby_plot.tex +0 -1077
  171. data/blogs/ruby_plot/ruby_plot_files/figure-html/dose_len.svg +0 -57
  172. data/blogs/ruby_plot/ruby_plot_files/figure-html/facet_by_delivery.svg +0 -106
  173. data/blogs/ruby_plot/ruby_plot_files/figure-html/facet_by_dose.svg +0 -110
  174. data/blogs/ruby_plot/ruby_plot_files/figure-html/facets_by_delivery_color.svg +0 -174
  175. data/blogs/ruby_plot/ruby_plot_files/figure-html/facets_by_delivery_color2.svg +0 -236
  176. data/blogs/ruby_plot/ruby_plot_files/figure-html/facets_with_jitter.svg +0 -296
  177. data/blogs/ruby_plot/ruby_plot_files/figure-html/facets_with_points.svg +0 -236
  178. data/blogs/ruby_plot/ruby_plot_files/figure-html/final_box_plot.svg +0 -218
  179. data/blogs/ruby_plot/ruby_plot_files/figure-html/final_violin_plot.svg +0 -128
  180. data/blogs/ruby_plot/ruby_plot_files/figure-html/violin_with_jitter.svg +0 -150
  181. data/examples/paper/paper.rb +0 -36
@@ -0,0 +1,1443 @@
1
+ %%
2
+ %% This is file `spphys.bst',
3
+ %% generated with the docstrip utility.
4
+ %%
5
+ %% The original source files were:
6
+ %%
7
+ %% merlin.mbs (with options: `seq-no,vonx,nm-init,ed-au,yr-par,xmth,jtit-x,jttl-rm,thtit-a,vol-bf,volp-com,jpg-1,pgsep-c,num-xser,ser-vol,ser-ed,jnm-x,pub-date,pre-pub,doi,edpar,edby,fin-bare,pp,ed,abr,ord,jabr,xand,url,url-blk,nfss,')
8
+ %% ----------------------------------------
9
+ %%********************************************************************************%%
10
+ %% %%
11
+ %% For Springer physics publications. Based on the APS reference style. %%
12
+ %% Report bugs and improvements to: Joylene Vette-Guillaume or Frank Holzwarth %%
13
+ %% Springer-Verlag 2004/10/15 %%
14
+ %% %%
15
+ %%********************************************************************************%%
16
+ %%
17
+ %% Copyright 1994-2004 Patrick W Daly
18
+ % ===============================================================
19
+ % IMPORTANT NOTICE:
20
+ % This bibliographic style (bst) file has been generated from one or
21
+ % more master bibliographic style (mbs) files, listed above.
22
+ %
23
+ % This generated file can be redistributed and/or modified under the terms
24
+ % of the LaTeX Project Public License Distributed from CTAN
25
+ % archives in directory macros/latex/base/lppl.txt; either
26
+ % version 1 of the License, or any later version.
27
+ % ===============================================================
28
+ % Name and version information of the main mbs file:
29
+ % \ProvidesFile{merlin.mbs}[2004/02/09 4.13 (PWD, AO, DPC)]
30
+ % For use with BibTeX version 0.99a or later
31
+ %-------------------------------------------------------------------
32
+ % This bibliography style file is intended for texts in ENGLISH
33
+ % This is a numerical citation style, and as such is standard LaTeX.
34
+ % It requires no extra package to interface to the main text.
35
+ % The form of the \bibitem entries is
36
+ % \bibitem{key}...
37
+ % Usage of \cite is as follows:
38
+ % \cite{key} ==>> [#]
39
+ % \cite[chap. 2]{key} ==>> [#, chap. 2]
40
+ % where # is a number determined by the ordering in the reference list.
41
+ % The order in the reference list is that by which the works were originally
42
+ % cited in the text, or that in the database.
43
+ %---------------------------------------------------------------------
44
+
45
+ ENTRY
46
+ { address
47
+ author
48
+ booktitle
49
+ chapter
50
+ doi
51
+ edition
52
+ editor
53
+ eid
54
+ howpublished
55
+ institution
56
+ journal
57
+ key
58
+ month
59
+ note
60
+ number
61
+ organization
62
+ pages
63
+ publisher
64
+ school
65
+ series
66
+ title
67
+ type
68
+ url
69
+ volume
70
+ year
71
+ }
72
+ {}
73
+ { label }
74
+ INTEGERS { output.state before.all mid.sentence after.sentence after.block }
75
+ FUNCTION {init.state.consts}
76
+ { #0 'before.all :=
77
+ #1 'mid.sentence :=
78
+ #2 'after.sentence :=
79
+ #3 'after.block :=
80
+ }
81
+ STRINGS { s t}
82
+ FUNCTION {output.nonnull}
83
+ { 's :=
84
+ output.state mid.sentence =
85
+ { ", " * write$ }
86
+ { output.state after.block =
87
+ { add.period$ write$
88
+ newline$
89
+ "\newblock " write$
90
+ }
91
+ { output.state before.all =
92
+ 'write$
93
+ { add.period$ " " * write$ }
94
+ if$
95
+ }
96
+ if$
97
+ mid.sentence 'output.state :=
98
+ }
99
+ if$
100
+ s
101
+ }
102
+ FUNCTION {output}
103
+ { duplicate$ empty$
104
+ 'pop$
105
+ 'output.nonnull
106
+ if$
107
+ }
108
+ FUNCTION {output.check}
109
+ { 't :=
110
+ duplicate$ empty$
111
+ { pop$ "empty " t * " in " * cite$ * warning$ }
112
+ 'output.nonnull
113
+ if$
114
+ }
115
+ FUNCTION {fin.entry}
116
+ { duplicate$ empty$
117
+ 'pop$
118
+ 'write$
119
+ if$
120
+ newline$
121
+ }
122
+
123
+ FUNCTION {new.block}
124
+ { output.state before.all =
125
+ 'skip$
126
+ { after.block 'output.state := }
127
+ if$
128
+ }
129
+ FUNCTION {new.sentence}
130
+ { output.state after.block =
131
+ 'skip$
132
+ { output.state before.all =
133
+ 'skip$
134
+ { after.sentence 'output.state := }
135
+ if$
136
+ }
137
+ if$
138
+ }
139
+ FUNCTION {add.blank}
140
+ { " " * before.all 'output.state :=
141
+ }
142
+
143
+ FUNCTION {add.comma}
144
+ { duplicate$ empty$
145
+ 'skip$
146
+ { "," * add.blank }
147
+ if$
148
+ }
149
+
150
+ FUNCTION {date.block}
151
+ {
152
+ new.block
153
+ }
154
+
155
+ FUNCTION {not}
156
+ { { #0 }
157
+ { #1 }
158
+ if$
159
+ }
160
+ FUNCTION {and}
161
+ { 'skip$
162
+ { pop$ #0 }
163
+ if$
164
+ }
165
+ FUNCTION {or}
166
+ { { pop$ #1 }
167
+ 'skip$
168
+ if$
169
+ }
170
+ FUNCTION {new.block.checka}
171
+ { empty$
172
+ 'skip$
173
+ 'new.block
174
+ if$
175
+ }
176
+ FUNCTION {new.block.checkb}
177
+ { empty$
178
+ swap$ empty$
179
+ and
180
+ 'skip$
181
+ 'new.block
182
+ if$
183
+ }
184
+ FUNCTION {new.sentence.checka}
185
+ { empty$
186
+ 'skip$
187
+ 'new.sentence
188
+ if$
189
+ }
190
+ FUNCTION {new.sentence.checkb}
191
+ { empty$
192
+ swap$ empty$
193
+ and
194
+ 'skip$
195
+ 'new.sentence
196
+ if$
197
+ }
198
+ FUNCTION {field.or.null}
199
+ { duplicate$ empty$
200
+ { pop$ "" }
201
+ 'skip$
202
+ if$
203
+ }
204
+ FUNCTION {emphasize}
205
+ { duplicate$ empty$
206
+ { pop$ "" }
207
+ { "\emph{" swap$ * "}" * }
208
+ if$
209
+ }
210
+ FUNCTION {bolden}
211
+ { duplicate$ empty$
212
+ { pop$ "" }
213
+ { "\textbf{" swap$ * "}" * }
214
+ if$
215
+ }
216
+ FUNCTION {tie.or.space.prefix}
217
+ { duplicate$ text.length$ #3 <
218
+ { "~" }
219
+ { " " }
220
+ if$
221
+ swap$
222
+ }
223
+
224
+ FUNCTION {capitalize}
225
+ { "u" change.case$ "t" change.case$ }
226
+
227
+ FUNCTION {space.word}
228
+ { " " swap$ * " " * }
229
+ % Here are the language-specific definitions for explicit words.
230
+ % Each function has a name bbl.xxx where xxx is the English word.
231
+ % The language selected here is ENGLISH
232
+ FUNCTION {bbl.and}
233
+ { "and"}
234
+
235
+ FUNCTION {bbl.etal}
236
+ { "et~al." }
237
+
238
+ FUNCTION {bbl.editors}
239
+ { "eds." }
240
+
241
+ FUNCTION {bbl.editor}
242
+ { "ed." }
243
+
244
+ FUNCTION {bbl.edby}
245
+ { "ed. by" }
246
+
247
+ FUNCTION {bbl.edition}
248
+ { "edn." }
249
+
250
+ FUNCTION {bbl.volume}
251
+ { "vol." }
252
+
253
+ FUNCTION {bbl.of}
254
+ { "of" }
255
+
256
+ FUNCTION {bbl.number}
257
+ { "no." }
258
+
259
+ FUNCTION {bbl.nr}
260
+ { "no." }
261
+
262
+ FUNCTION {bbl.in}
263
+ { "in" }
264
+
265
+ FUNCTION {bbl.pages}
266
+ { "pp." }
267
+
268
+ FUNCTION {bbl.page}
269
+ { "p." }
270
+
271
+ FUNCTION {bbl.chapter}
272
+ { "chap." }
273
+
274
+ FUNCTION {bbl.techrep}
275
+ { "Tech. Rep." }
276
+
277
+ FUNCTION {bbl.mthesis}
278
+ { "Master's thesis" }
279
+
280
+ FUNCTION {bbl.phdthesis}
281
+ { "Ph.D. thesis" }
282
+
283
+ FUNCTION {bbl.first}
284
+ { "1st" }
285
+
286
+ FUNCTION {bbl.second}
287
+ { "2nd" }
288
+
289
+ FUNCTION {bbl.third}
290
+ { "3rd" }
291
+
292
+ FUNCTION {bbl.fourth}
293
+ { "4th" }
294
+
295
+ FUNCTION {bbl.fifth}
296
+ { "5th" }
297
+
298
+ FUNCTION {bbl.st}
299
+ { "st" }
300
+
301
+ FUNCTION {bbl.nd}
302
+ { "nd" }
303
+
304
+ FUNCTION {bbl.rd}
305
+ { "rd" }
306
+
307
+ FUNCTION {bbl.th}
308
+ { "th" }
309
+
310
+ MACRO {jan} {"Jan."}
311
+
312
+ MACRO {feb} {"Feb."}
313
+
314
+ MACRO {mar} {"Mar."}
315
+
316
+ MACRO {apr} {"Apr."}
317
+
318
+ MACRO {may} {"May"}
319
+
320
+ MACRO {jun} {"Jun."}
321
+
322
+ MACRO {jul} {"Jul."}
323
+
324
+ MACRO {aug} {"Aug."}
325
+
326
+ MACRO {sep} {"Sep."}
327
+
328
+ MACRO {oct} {"Oct."}
329
+
330
+ MACRO {nov} {"Nov."}
331
+
332
+ MACRO {dec} {"Dec."}
333
+
334
+ FUNCTION {eng.ord}
335
+ { duplicate$ "1" swap$ *
336
+ #-2 #1 substring$ "1" =
337
+ { bbl.th * }
338
+ { duplicate$ #-1 #1 substring$
339
+ duplicate$ "1" =
340
+ { pop$ bbl.st * }
341
+ { duplicate$ "2" =
342
+ { pop$ bbl.nd * }
343
+ { "3" =
344
+ { bbl.rd * }
345
+ { bbl.th * }
346
+ if$
347
+ }
348
+ if$
349
+ }
350
+ if$
351
+ }
352
+ if$
353
+ }
354
+
355
+ MACRO {acmcs} {"ACM Comput. Surv."}
356
+
357
+ MACRO {acta} {"Acta Inf."}
358
+
359
+ MACRO {cacm} {"Commun. ACM"}
360
+
361
+ MACRO {ibmjrd} {"IBM J. Res. Dev."}
362
+
363
+ MACRO {ibmsj} {"IBM Syst.~J."}
364
+
365
+ MACRO {ieeese} {"IEEE Trans. Software Eng."}
366
+
367
+ MACRO {ieeetc} {"IEEE Trans. Comput."}
368
+
369
+ MACRO {ieeetcad}
370
+ {"IEEE Trans. Comput. Aid. Des."}
371
+
372
+ MACRO {ipl} {"Inf. Process. Lett."}
373
+
374
+ MACRO {jacm} {"J.~ACM"}
375
+
376
+ MACRO {jcss} {"J.~Comput. Syst. Sci."}
377
+
378
+ MACRO {scp} {"Sci. Comput. Program."}
379
+
380
+ MACRO {sicomp} {"SIAM J. Comput."}
381
+
382
+ MACRO {tocs} {"ACM Trans. Comput. Syst."}
383
+
384
+ MACRO {tods} {"ACM Trans. Database Syst."}
385
+
386
+ MACRO {tog} {"ACM Trans. Graphic."}
387
+
388
+ MACRO {toms} {"ACM Trans. Math. Software"}
389
+
390
+ MACRO {toois} {"ACM Trans. Office Inf. Syst."}
391
+
392
+ MACRO {toplas} {"ACM Trans. Progr. Lang. Syst."}
393
+
394
+ MACRO {tcs} {"Theor. Comput. Sci."}
395
+
396
+ FUNCTION {bibinfo.check}
397
+ { swap$
398
+ duplicate$ missing$
399
+ {
400
+ pop$ pop$
401
+ ""
402
+ }
403
+ { duplicate$ empty$
404
+ {
405
+ swap$ pop$
406
+ }
407
+ { swap$
408
+ pop$
409
+ }
410
+ if$
411
+ }
412
+ if$
413
+ }
414
+ FUNCTION {bibinfo.warn}
415
+ { swap$
416
+ duplicate$ missing$
417
+ {
418
+ swap$ "missing " swap$ * " in " * cite$ * warning$ pop$
419
+ ""
420
+ }
421
+ { duplicate$ empty$
422
+ {
423
+ swap$ "empty " swap$ * " in " * cite$ * warning$
424
+ }
425
+ { swap$
426
+ pop$
427
+ }
428
+ if$
429
+ }
430
+ if$
431
+ }
432
+ FUNCTION {format.url}
433
+ { url empty$
434
+ { "" }
435
+ { "\urlprefix\url{" url * "}" * }
436
+ if$
437
+ }
438
+
439
+ STRINGS { bibinfo}
440
+ INTEGERS { nameptr namesleft numnames }
441
+
442
+ FUNCTION {format.names}
443
+ { 'bibinfo :=
444
+ duplicate$ empty$ 'skip$ {
445
+ 's :=
446
+ "" 't :=
447
+ #1 'nameptr :=
448
+ s num.names$ 'numnames :=
449
+ numnames 'namesleft :=
450
+ { namesleft #0 > }
451
+ { s nameptr
452
+ "{f{.}.~}{vv~}{ll}{, jj}"
453
+ format.name$
454
+ bibinfo bibinfo.check
455
+ 't :=
456
+ nameptr #1 >
457
+ {
458
+ namesleft #1 >
459
+ { ", " * t * }
460
+ {
461
+ "," *
462
+ s nameptr "{ll}" format.name$ duplicate$ "others" =
463
+ { 't := }
464
+ { pop$ }
465
+ if$
466
+ t "others" =
467
+ {
468
+ " " * bbl.etal *
469
+ }
470
+ { " " * t * }
471
+ if$
472
+ }
473
+ if$
474
+ }
475
+ 't
476
+ if$
477
+ nameptr #1 + 'nameptr :=
478
+ namesleft #1 - 'namesleft :=
479
+ }
480
+ while$
481
+ } if$
482
+ }
483
+ FUNCTION {format.names.ed}
484
+ {
485
+ format.names
486
+ }
487
+ FUNCTION {format.authors}
488
+ { author "author" format.names
489
+ }
490
+ FUNCTION {get.bbl.editor}
491
+ { editor num.names$ #1 > 'bbl.editors 'bbl.editor if$ }
492
+
493
+ FUNCTION {format.editors}
494
+ { editor "editor" format.names duplicate$ empty$ 'skip$
495
+ {
496
+ " " *
497
+ get.bbl.editor
498
+ "(" swap$ * ")" *
499
+ *
500
+ }
501
+ if$
502
+ }
503
+ FUNCTION {format.doi}
504
+ { doi "doi" bibinfo.check
505
+ duplicate$ empty$ 'skip$
506
+ {
507
+ new.block
508
+ "\doi{" swap$ * "}" *
509
+ }
510
+ if$
511
+ }
512
+ FUNCTION {format.note}
513
+ {
514
+ note empty$
515
+ { "" }
516
+ { note #1 #1 substring$
517
+ duplicate$ "{" =
518
+ 'skip$
519
+ { output.state mid.sentence =
520
+ { "l" }
521
+ { "u" }
522
+ if$
523
+ change.case$
524
+ }
525
+ if$
526
+ note #2 global.max$ substring$ * "note" bibinfo.check
527
+ }
528
+ if$
529
+ }
530
+
531
+ FUNCTION {format.title}
532
+ { title
533
+ duplicate$ empty$ 'skip$
534
+ { "t" change.case$ }
535
+ if$
536
+ "title" bibinfo.check
537
+ }
538
+ FUNCTION {output.bibitem}
539
+ { newline$
540
+ "\bibitem{" write$
541
+ cite$ write$
542
+ "}" write$
543
+ newline$
544
+ ""
545
+ before.all 'output.state :=
546
+ }
547
+
548
+ FUNCTION {if.digit}
549
+ { duplicate$ "0" =
550
+ swap$ duplicate$ "1" =
551
+ swap$ duplicate$ "2" =
552
+ swap$ duplicate$ "3" =
553
+ swap$ duplicate$ "4" =
554
+ swap$ duplicate$ "5" =
555
+ swap$ duplicate$ "6" =
556
+ swap$ duplicate$ "7" =
557
+ swap$ duplicate$ "8" =
558
+ swap$ "9" = or or or or or or or or or
559
+ }
560
+ FUNCTION {n.separate}
561
+ { 't :=
562
+ ""
563
+ #0 'numnames :=
564
+ { t empty$ not }
565
+ { t #-1 #1 substring$ if.digit
566
+ { numnames #1 + 'numnames := }
567
+ { #0 'numnames := }
568
+ if$
569
+ t #-1 #1 substring$ swap$ *
570
+ t #-2 global.max$ substring$ 't :=
571
+ numnames #5 =
572
+ { duplicate$ #1 #2 substring$ swap$
573
+ #3 global.max$ substring$
574
+ "," swap$ * *
575
+ }
576
+ 'skip$
577
+ if$
578
+ }
579
+ while$
580
+ }
581
+ FUNCTION {n.dashify}
582
+ {
583
+ n.separate
584
+ 't :=
585
+ ""
586
+ { t empty$ not }
587
+ { t #1 #1 substring$ "-" =
588
+ { t #1 #2 substring$ "--" = not
589
+ { "--" *
590
+ t #2 global.max$ substring$ 't :=
591
+ }
592
+ { { t #1 #1 substring$ "-" = }
593
+ { "-" *
594
+ t #2 global.max$ substring$ 't :=
595
+ }
596
+ while$
597
+ }
598
+ if$
599
+ }
600
+ { t #1 #1 substring$ *
601
+ t #2 global.max$ substring$ 't :=
602
+ }
603
+ if$
604
+ }
605
+ while$
606
+ }
607
+
608
+ FUNCTION {word.in}
609
+ { bbl.in
610
+ " " * }
611
+
612
+ FUNCTION {format.date}
613
+ {
614
+ ""
615
+ duplicate$ empty$
616
+ year "year" bibinfo.check duplicate$ empty$
617
+ { swap$ 'skip$
618
+ { "there's a month but no year in " cite$ * warning$ }
619
+ if$
620
+ *
621
+ }
622
+ { swap$ 'skip$
623
+ {
624
+ swap$
625
+ " " * swap$
626
+ }
627
+ if$
628
+ *
629
+ }
630
+ if$
631
+ duplicate$ empty$
632
+ 'skip$
633
+ {
634
+ before.all 'output.state :=
635
+ " (" swap$ * ")" *
636
+ }
637
+ if$
638
+ }
639
+ FUNCTION {format.btitle}
640
+ { title "title" bibinfo.check
641
+ duplicate$ empty$ 'skip$
642
+ {
643
+ emphasize
644
+ }
645
+ if$
646
+ }
647
+ FUNCTION {either.or.check}
648
+ { empty$
649
+ 'pop$
650
+ { "can't use both " swap$ * " fields in " * cite$ * warning$ }
651
+ if$
652
+ }
653
+ FUNCTION {format.bvolume}
654
+ { volume empty$
655
+ { "" }
656
+ { bbl.volume volume tie.or.space.prefix
657
+ "volume" bibinfo.check * *
658
+ series "series" bibinfo.check
659
+ duplicate$ empty$ 'pop$
660
+ { emphasize ", " * swap$ * }
661
+ if$
662
+ "volume and number" number either.or.check
663
+ }
664
+ if$
665
+ }
666
+ FUNCTION {format.number.series}
667
+ { volume empty$
668
+ { number empty$
669
+ { series field.or.null }
670
+ { series empty$
671
+ { number "number" bibinfo.check }
672
+ { output.state mid.sentence =
673
+ { bbl.number }
674
+ { bbl.number capitalize }
675
+ if$
676
+ number tie.or.space.prefix "number" bibinfo.check * *
677
+ bbl.in space.word *
678
+ series "series" bibinfo.check *
679
+ }
680
+ if$
681
+ }
682
+ if$
683
+ }
684
+ { "" }
685
+ if$
686
+ }
687
+ FUNCTION {is.num}
688
+ { chr.to.int$
689
+ duplicate$ "0" chr.to.int$ < not
690
+ swap$ "9" chr.to.int$ > not and
691
+ }
692
+
693
+ FUNCTION {extract.num}
694
+ { duplicate$ 't :=
695
+ "" 's :=
696
+ { t empty$ not }
697
+ { t #1 #1 substring$
698
+ t #2 global.max$ substring$ 't :=
699
+ duplicate$ is.num
700
+ { s swap$ * 's := }
701
+ { pop$ "" 't := }
702
+ if$
703
+ }
704
+ while$
705
+ s empty$
706
+ 'skip$
707
+ { pop$ s }
708
+ if$
709
+ }
710
+
711
+ FUNCTION {convert.edition}
712
+ { extract.num "l" change.case$ 's :=
713
+ s "first" = s "1" = or
714
+ { bbl.first 't := }
715
+ { s "second" = s "2" = or
716
+ { bbl.second 't := }
717
+ { s "third" = s "3" = or
718
+ { bbl.third 't := }
719
+ { s "fourth" = s "4" = or
720
+ { bbl.fourth 't := }
721
+ { s "fifth" = s "5" = or
722
+ { bbl.fifth 't := }
723
+ { s #1 #1 substring$ is.num
724
+ { s eng.ord 't := }
725
+ { edition 't := }
726
+ if$
727
+ }
728
+ if$
729
+ }
730
+ if$
731
+ }
732
+ if$
733
+ }
734
+ if$
735
+ }
736
+ if$
737
+ t
738
+ }
739
+
740
+ FUNCTION {format.edition}
741
+ { edition duplicate$ empty$ 'skip$
742
+ {
743
+ convert.edition
744
+ output.state mid.sentence =
745
+ { "l" }
746
+ { "t" }
747
+ if$ change.case$
748
+ "edition" bibinfo.check
749
+ " " * bbl.edition *
750
+ }
751
+ if$
752
+ }
753
+ INTEGERS { multiresult }
754
+ FUNCTION {multi.page.check}
755
+ { 't :=
756
+ #0 'multiresult :=
757
+ { multiresult not
758
+ t empty$ not
759
+ and
760
+ }
761
+ { t #1 #1 substring$
762
+ duplicate$ "-" =
763
+ swap$ duplicate$ "," =
764
+ swap$ "+" =
765
+ or or
766
+ { #1 'multiresult := }
767
+ { t #2 global.max$ substring$ 't := }
768
+ if$
769
+ }
770
+ while$
771
+ multiresult
772
+ }
773
+ FUNCTION {format.pages}
774
+ { pages duplicate$ empty$ 'skip$
775
+ { duplicate$ multi.page.check
776
+ {
777
+ bbl.pages swap$
778
+ n.dashify
779
+ }
780
+ {
781
+ bbl.page swap$
782
+ }
783
+ if$
784
+ tie.or.space.prefix
785
+ "pages" bibinfo.check
786
+ * *
787
+ }
788
+ if$
789
+ }
790
+ FUNCTION {first.page}
791
+ { 't :=
792
+ ""
793
+ { t empty$ not t #1 #1 substring$ "-" = not and }
794
+ { t #1 #1 substring$ *
795
+ t #2 global.max$ substring$ 't :=
796
+ }
797
+ while$
798
+ }
799
+
800
+ FUNCTION {format.journal.pages}
801
+ { pages duplicate$ empty$ 'pop$
802
+ { swap$ duplicate$ empty$
803
+ { pop$ pop$ format.pages }
804
+ {
805
+ ", " *
806
+ swap$
807
+ first.page
808
+ "pages" bibinfo.check
809
+ *
810
+ }
811
+ if$
812
+ }
813
+ if$
814
+ }
815
+ FUNCTION {format.journal.eid}
816
+ { eid "eid" bibinfo.check
817
+ duplicate$ empty$ 'pop$
818
+ { swap$ duplicate$ empty$ 'skip$
819
+ {
820
+ ", " *
821
+ }
822
+ if$
823
+ swap$ *
824
+ }
825
+ if$
826
+ }
827
+ FUNCTION {format.vol.num.pages}
828
+ { volume field.or.null
829
+ duplicate$ empty$ 'skip$
830
+ {
831
+ "volume" bibinfo.check
832
+ }
833
+ if$
834
+ bolden
835
+ number "number" bibinfo.check duplicate$ empty$ 'skip$
836
+ {
837
+ swap$ duplicate$ empty$
838
+ { "there's a number but no volume in " cite$ * warning$ }
839
+ 'skip$
840
+ if$
841
+ swap$
842
+ "(" swap$ * ")" *
843
+ }
844
+ if$ *
845
+ eid empty$
846
+ { format.journal.pages }
847
+ { format.journal.eid }
848
+ if$
849
+ }
850
+
851
+ FUNCTION {format.chapter.pages}
852
+ { chapter empty$
853
+ 'format.pages
854
+ { type empty$
855
+ { bbl.chapter }
856
+ { type "l" change.case$
857
+ "type" bibinfo.check
858
+ }
859
+ if$
860
+ chapter tie.or.space.prefix
861
+ "chapter" bibinfo.check
862
+ * *
863
+ pages empty$
864
+ 'skip$
865
+ { ", " * format.pages * }
866
+ if$
867
+ }
868
+ if$
869
+ }
870
+
871
+ FUNCTION {format.booktitle}
872
+ {
873
+ booktitle "booktitle" bibinfo.check
874
+ emphasize
875
+ }
876
+ FUNCTION {format.in.ed.booktitle}
877
+ { format.booktitle duplicate$ empty$ 'skip$
878
+ {
879
+ format.bvolume duplicate$ empty$ 'pop$
880
+ { ", " swap$ * * }
881
+ if$
882
+ editor "editor" format.names.ed duplicate$ empty$ 'pop$
883
+ {
884
+ bbl.edby
885
+ " " * swap$ *
886
+ swap$
887
+ "," *
888
+ " " * swap$
889
+ * }
890
+ if$
891
+ word.in swap$ *
892
+ }
893
+ if$
894
+ }
895
+ FUNCTION {empty.misc.check}
896
+ { author empty$ title empty$ howpublished empty$
897
+ month empty$ year empty$ note empty$
898
+ and and and and and
899
+ { "all relevant fields are empty in " cite$ * warning$ }
900
+ 'skip$
901
+ if$
902
+ }
903
+ FUNCTION {format.thesis.type}
904
+ { type duplicate$ empty$
905
+ 'pop$
906
+ { swap$ pop$
907
+ "t" change.case$ "type" bibinfo.check
908
+ }
909
+ if$
910
+ }
911
+ FUNCTION {format.tr.number}
912
+ { number "number" bibinfo.check
913
+ type duplicate$ empty$
914
+ { pop$ bbl.techrep }
915
+ 'skip$
916
+ if$
917
+ "type" bibinfo.check
918
+ swap$ duplicate$ empty$
919
+ { pop$ "t" change.case$ }
920
+ { tie.or.space.prefix * * }
921
+ if$
922
+ }
923
+ FUNCTION {format.article.crossref}
924
+ {
925
+ key duplicate$ empty$
926
+ { pop$
927
+ journal duplicate$ empty$
928
+ { "need key or journal for " cite$ * " to crossref " * crossref * warning$ }
929
+ { "journal" bibinfo.check emphasize word.in swap$ * }
930
+ if$
931
+ }
932
+ { word.in swap$ * " " *}
933
+ if$
934
+ " \cite{" * crossref * "}" *
935
+ }
936
+ FUNCTION {format.crossref.editor}
937
+ { editor #1 "{vv~}{ll}" format.name$
938
+ "editor" bibinfo.check
939
+ editor num.names$ duplicate$
940
+ #2 >
941
+ { pop$
942
+ "editor" bibinfo.check
943
+ " " * bbl.etal
944
+ *
945
+ }
946
+ { #2 <
947
+ 'skip$
948
+ { editor #2 "{ff }{vv }{ll}{ jj}" format.name$ "others" =
949
+ {
950
+ "editor" bibinfo.check
951
+ " " * bbl.etal
952
+ *
953
+ }
954
+ {
955
+ bbl.and space.word
956
+ * editor #2 "{vv~}{ll}" format.name$
957
+ "editor" bibinfo.check
958
+ *
959
+ }
960
+ if$
961
+ }
962
+ if$
963
+ }
964
+ if$
965
+ }
966
+ FUNCTION {format.book.crossref}
967
+ { volume duplicate$ empty$
968
+ { "empty volume in " cite$ * "'s crossref of " * crossref * warning$
969
+ pop$ word.in
970
+ }
971
+ { bbl.volume
972
+ capitalize
973
+ swap$ tie.or.space.prefix "volume" bibinfo.check * * bbl.of space.word *
974
+ }
975
+ if$
976
+ editor empty$
977
+ editor field.or.null author field.or.null =
978
+ or
979
+ { key empty$
980
+ { series empty$
981
+ { "need editor, key, or series for " cite$ * " to crossref " *
982
+ crossref * warning$
983
+ "" *
984
+ }
985
+ { series emphasize * }
986
+ if$
987
+ }
988
+ { key * }
989
+ if$
990
+ }
991
+ { format.crossref.editor * }
992
+ if$
993
+ " \cite{" * crossref * "}" *
994
+ }
995
+ FUNCTION {format.incoll.inproc.crossref}
996
+ {
997
+ editor empty$
998
+ editor field.or.null author field.or.null =
999
+ or
1000
+ { key empty$
1001
+ { format.booktitle duplicate$ empty$
1002
+ { "need editor, key, or booktitle for " cite$ * " to crossref " *
1003
+ crossref * warning$
1004
+ }
1005
+ { word.in swap$ * }
1006
+ if$
1007
+ }
1008
+ { word.in key * " " *}
1009
+ if$
1010
+ }
1011
+ { word.in format.crossref.editor * " " *}
1012
+ if$
1013
+ " \cite{" * crossref * "}" *
1014
+ }
1015
+ FUNCTION {format.org.or.pub}
1016
+ { 't :=
1017
+ ""
1018
+ year empty$
1019
+ { "empty year in " cite$ * warning$ }
1020
+ 'skip$
1021
+ if$
1022
+ address empty$ t empty$ and
1023
+ year empty$ and
1024
+ 'skip$
1025
+ {
1026
+ add.blank "(" *
1027
+ t empty$
1028
+ { address "address" bibinfo.check *
1029
+ }
1030
+ { t *
1031
+ address empty$
1032
+ 'skip$
1033
+ { ", " * address "address" bibinfo.check * }
1034
+ if$
1035
+ }
1036
+ if$
1037
+ year empty$
1038
+ 'skip$
1039
+ { t empty$ address empty$ and
1040
+ 'skip$
1041
+ { ", " * }
1042
+ if$
1043
+ year "year" bibinfo.check
1044
+ *
1045
+ }
1046
+ if$
1047
+ ")" *
1048
+ }
1049
+ if$
1050
+ }
1051
+ FUNCTION {format.publisher.address}
1052
+ { publisher "publisher" bibinfo.warn format.org.or.pub
1053
+ }
1054
+
1055
+ FUNCTION {format.organization.address}
1056
+ { organization "organization" bibinfo.check format.org.or.pub
1057
+ }
1058
+
1059
+ FUNCTION {article}
1060
+ { output.bibitem
1061
+ format.authors "author" output.check
1062
+ add.comma
1063
+ format.title "title" output.check
1064
+ crossref missing$
1065
+ {
1066
+ journal
1067
+ "journal" bibinfo.check
1068
+ "journal" output.check
1069
+ add.blank
1070
+ format.vol.num.pages output
1071
+ format.date "year" output.check
1072
+ }
1073
+ { format.article.crossref output.nonnull
1074
+ format.pages output
1075
+ }
1076
+ if$
1077
+ format.doi output
1078
+ new.block
1079
+ format.url output
1080
+ new.block
1081
+ format.note output
1082
+ fin.entry
1083
+ }
1084
+ FUNCTION {book}
1085
+ { output.bibitem
1086
+ author empty$
1087
+ { format.editors "author and editor" output.check
1088
+ }
1089
+ { format.authors output.nonnull
1090
+ crossref missing$
1091
+ { "author and editor" editor either.or.check }
1092
+ 'skip$
1093
+ if$
1094
+ }
1095
+ if$
1096
+ add.comma
1097
+ format.btitle "title" output.check
1098
+ crossref missing$
1099
+ { format.bvolume output
1100
+ format.edition output
1101
+ new.block
1102
+ format.number.series output
1103
+ new.sentence
1104
+ format.publisher.address output
1105
+ }
1106
+ {
1107
+ new.block
1108
+ format.book.crossref output.nonnull
1109
+ format.date "year" output.check
1110
+ }
1111
+ if$
1112
+ format.doi output
1113
+ new.block
1114
+ format.url output
1115
+ new.block
1116
+ format.note output
1117
+ fin.entry
1118
+ }
1119
+ FUNCTION {booklet}
1120
+ { output.bibitem
1121
+ format.authors output
1122
+ add.comma
1123
+ format.title "title" output.check
1124
+ new.block
1125
+ howpublished "howpublished" bibinfo.check output
1126
+ address "address" bibinfo.check output
1127
+ format.date output
1128
+ format.doi output
1129
+ new.block
1130
+ format.url output
1131
+ new.block
1132
+ format.note output
1133
+ fin.entry
1134
+ }
1135
+
1136
+ FUNCTION {inbook}
1137
+ { output.bibitem
1138
+ author empty$
1139
+ { format.editors "author and editor" output.check
1140
+ }
1141
+ { format.authors output.nonnull
1142
+ crossref missing$
1143
+ { "author and editor" editor either.or.check }
1144
+ 'skip$
1145
+ if$
1146
+ }
1147
+ if$
1148
+ add.comma
1149
+ format.btitle "title" output.check
1150
+ crossref missing$
1151
+ {
1152
+ format.publisher.address output
1153
+ format.bvolume output
1154
+ format.edition output
1155
+ format.chapter.pages "chapter and pages" output.check
1156
+ new.block
1157
+ format.number.series output
1158
+ new.sentence
1159
+ }
1160
+ {
1161
+ format.chapter.pages "chapter and pages" output.check
1162
+ new.block
1163
+ format.book.crossref output.nonnull
1164
+ format.date "year" output.check
1165
+ }
1166
+ if$
1167
+ format.doi output
1168
+ new.block
1169
+ format.url output
1170
+ new.block
1171
+ format.note output
1172
+ fin.entry
1173
+ }
1174
+
1175
+ FUNCTION {incollection}
1176
+ { output.bibitem
1177
+ format.authors "author" output.check
1178
+ add.comma
1179
+ crossref missing$
1180
+ { format.in.ed.booktitle "booktitle" output.check
1181
+ format.edition output
1182
+ format.number.series output
1183
+ format.publisher.address output
1184
+ format.chapter.pages output
1185
+ new.sentence
1186
+ }
1187
+ { format.incoll.inproc.crossref output.nonnull
1188
+ format.chapter.pages output
1189
+ }
1190
+ if$
1191
+ format.doi output
1192
+ new.block
1193
+ format.url output
1194
+ new.block
1195
+ format.note output
1196
+ fin.entry
1197
+ }
1198
+ FUNCTION {inproceedings}
1199
+ { output.bibitem
1200
+ format.authors "author" output.check
1201
+ add.comma
1202
+ crossref missing$
1203
+ { format.in.ed.booktitle "booktitle" output.check
1204
+ new.sentence
1205
+ publisher empty$
1206
+ { format.organization.address output }
1207
+ { organization "organization" bibinfo.check output
1208
+ format.publisher.address output
1209
+ }
1210
+ if$
1211
+ format.bvolume output
1212
+ format.number.series output
1213
+ format.pages output
1214
+ }
1215
+ { format.incoll.inproc.crossref output.nonnull
1216
+ format.pages output
1217
+ }
1218
+ if$
1219
+ format.doi output
1220
+ new.block
1221
+ format.url output
1222
+ new.block
1223
+ format.note output
1224
+ fin.entry
1225
+ }
1226
+ FUNCTION {conference} { inproceedings }
1227
+ FUNCTION {manual}
1228
+ { output.bibitem
1229
+ author empty$
1230
+ { organization "organization" bibinfo.check
1231
+ duplicate$ empty$ 'pop$
1232
+ { output
1233
+ address "address" bibinfo.check output
1234
+ }
1235
+ if$
1236
+ }
1237
+ { format.authors output.nonnull }
1238
+ if$
1239
+ add.comma
1240
+ format.btitle "title" output.check
1241
+ author empty$
1242
+ { organization empty$
1243
+ {
1244
+ address new.block.checka
1245
+ address "address" bibinfo.check output
1246
+ }
1247
+ 'skip$
1248
+ if$
1249
+ }
1250
+ {
1251
+ organization address new.block.checkb
1252
+ organization "organization" bibinfo.check output
1253
+ address "address" bibinfo.check output
1254
+ }
1255
+ if$
1256
+ format.edition output
1257
+ format.date output
1258
+ format.doi output
1259
+ new.block
1260
+ format.url output
1261
+ new.block
1262
+ format.note output
1263
+ fin.entry
1264
+ }
1265
+
1266
+ FUNCTION {mastersthesis}
1267
+ { output.bibitem
1268
+ format.authors "author" output.check
1269
+ add.comma
1270
+ format.title
1271
+ "title" output.check
1272
+ new.block
1273
+ bbl.mthesis format.thesis.type output.nonnull
1274
+ school "school" bibinfo.warn output
1275
+ address "address" bibinfo.check output
1276
+ format.date "year" output.check
1277
+ format.doi output
1278
+ new.block
1279
+ format.url output
1280
+ new.block
1281
+ format.note output
1282
+ fin.entry
1283
+ }
1284
+
1285
+ FUNCTION {misc}
1286
+ { output.bibitem
1287
+ format.authors output
1288
+ title howpublished new.block.checkb
1289
+ format.title output
1290
+ howpublished new.block.checka
1291
+ howpublished "howpublished" bibinfo.check output
1292
+ format.date output
1293
+ format.doi output
1294
+ new.block
1295
+ format.url output
1296
+ new.block
1297
+ format.note output
1298
+ fin.entry
1299
+ empty.misc.check
1300
+ }
1301
+ FUNCTION {phdthesis}
1302
+ { output.bibitem
1303
+ format.authors "author" output.check
1304
+ add.comma
1305
+ format.title
1306
+ "title" output.check
1307
+ new.block
1308
+ bbl.phdthesis format.thesis.type output.nonnull
1309
+ school "school" bibinfo.warn output
1310
+ address "address" bibinfo.check output
1311
+ format.date "year" output.check
1312
+ format.doi output
1313
+ new.block
1314
+ format.url output
1315
+ new.block
1316
+ format.note output
1317
+ fin.entry
1318
+ }
1319
+
1320
+ FUNCTION {proceedings}
1321
+ { output.bibitem
1322
+ editor empty$
1323
+ { organization "organization" bibinfo.check output
1324
+ }
1325
+ { format.editors output.nonnull }
1326
+ if$
1327
+ new.block
1328
+ format.btitle "title" output.check
1329
+ format.bvolume output
1330
+ format.number.series output
1331
+ editor empty$
1332
+ { publisher empty$
1333
+ 'skip$
1334
+ {
1335
+ new.sentence
1336
+ format.publisher.address output
1337
+ }
1338
+ if$
1339
+ }
1340
+ { publisher empty$
1341
+ {
1342
+ new.sentence
1343
+ format.organization.address output }
1344
+ {
1345
+ new.sentence
1346
+ organization "organization" bibinfo.check output
1347
+ format.publisher.address output
1348
+ }
1349
+ if$
1350
+ }
1351
+ if$
1352
+ format.doi output
1353
+ new.block
1354
+ format.url output
1355
+ new.block
1356
+ format.note output
1357
+ fin.entry
1358
+ }
1359
+
1360
+ FUNCTION {techreport}
1361
+ { output.bibitem
1362
+ format.authors "author" output.check
1363
+ add.comma
1364
+ format.title
1365
+ "title" output.check
1366
+ new.block
1367
+ format.tr.number output.nonnull
1368
+ institution "institution" bibinfo.warn output
1369
+ address "address" bibinfo.check output
1370
+ format.date "year" output.check
1371
+ format.doi output
1372
+ new.block
1373
+ format.url output
1374
+ new.block
1375
+ format.note output
1376
+ fin.entry
1377
+ }
1378
+
1379
+ FUNCTION {unpublished}
1380
+ { output.bibitem
1381
+ format.authors "author" output.check
1382
+ add.comma
1383
+ format.title "title" output.check
1384
+ format.date output
1385
+ format.doi output
1386
+ new.block
1387
+ format.url output
1388
+ new.block
1389
+ format.note "note" output.check
1390
+ fin.entry
1391
+ }
1392
+
1393
+ FUNCTION {default.type} { misc }
1394
+ READ
1395
+ STRINGS { longest.label }
1396
+ INTEGERS { number.label longest.label.width }
1397
+ FUNCTION {initialize.longest.label}
1398
+ { "" 'longest.label :=
1399
+ #1 'number.label :=
1400
+ #0 'longest.label.width :=
1401
+ }
1402
+ FUNCTION {longest.label.pass}
1403
+ { number.label int.to.str$ 'label :=
1404
+ number.label #1 + 'number.label :=
1405
+ label width$ longest.label.width >
1406
+ { label 'longest.label :=
1407
+ label width$ 'longest.label.width :=
1408
+ }
1409
+ 'skip$
1410
+ if$
1411
+ }
1412
+ EXECUTE {initialize.longest.label}
1413
+ ITERATE {longest.label.pass}
1414
+ FUNCTION {begin.bib}
1415
+ { preamble$ empty$
1416
+ 'skip$
1417
+ { preamble$ write$ newline$ }
1418
+ if$
1419
+ "\begin{thebibliography}{" longest.label * "}" *
1420
+ write$ newline$
1421
+ "\providecommand{\url}[1]{{#1}}"
1422
+ write$ newline$
1423
+ "\providecommand{\urlprefix}{URL }"
1424
+ write$ newline$
1425
+ "\expandafter\ifx\csname urlstyle\endcsname\relax"
1426
+ write$ newline$
1427
+ " \providecommand{\doi}[1]{DOI \discretionary{}{}{}#1}\else"
1428
+ write$ newline$
1429
+ " \providecommand{\doi}{DOI \discretionary{}{}{}\begingroup \urlstyle{rm}\Url}\fi"
1430
+ write$ newline$
1431
+ }
1432
+ EXECUTE {begin.bib}
1433
+ EXECUTE {init.state.consts}
1434
+ ITERATE {call.type$}
1435
+ FUNCTION {end.bib}
1436
+ { newline$
1437
+ "\end{thebibliography}" write$ newline$
1438
+ }
1439
+ EXECUTE {end.bib}
1440
+ %% End of customized bst file
1441
+ %%
1442
+ %% End of file `spphys.bst'.
1443
+