100% found this document useful (13 votes)
480 views14 pages

Forest Analytics With R An Introduction Scribd Download

The document is an introduction to the book 'Forest Analytics with R', which aims to provide a comprehensive guide for forestry analysts using R for data handling and analysis. It is intended for students, researchers, and practitioners in forestry, emphasizing the importance of R as a free and open-source software for statistical computing. The book includes practical examples and exercises to engage readers in applying R to solve real-world forestry problems.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (13 votes)
480 views14 pages

Forest Analytics With R An Introduction Scribd Download

The document is an introduction to the book 'Forest Analytics with R', which aims to provide a comprehensive guide for forestry analysts using R for data handling and analysis. It is intended for students, researchers, and practitioners in forestry, emphasizing the importance of R as a free and open-source software for statistical computing. The book includes practical examples and exercises to engage readers in applying R to solve real-world forestry problems.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

Forest Analytics with R An Introduction

Visit the link below to download the full version of this book:

https://medipdf.com/product/forest-analytics-with-r-an-introduction/

Click Download Now


1100 Fairview Avenue, N. M2-B876

Austria

Seattle,Washington 98109

USA

Giovanni Parmigiani

The Sidney Kimmel Comprehensive

Cancer Center at Johns Hopkins University

550 North Broadway

Baltimore, MD 21205-2011

USA

ISBN 978-1-4419-7761-8 e-ISBN 978-1-4419-7762-5

DOI 10.1007/978-1-4419-7762-5

Springer New York Dordrecht Heidelberg London

© Springer Science+Business Media, LLC 2011

All rights reserved. This work may not be translated or copied in whole or
in part without the written permission of the publisher (Springer
Science+Business Media, LLC, 233 Spring Street, New York, NY

10013, USA), except for brief excerpts in connection with reviews or


scholarly analysis. Use in connection with any form of information storage
and retrieval, electronic adaptation, computer software, or by similar or
dissimilar methodology now known or hereafter developed is forbidden.

The use in this publication of trade names, trademarks, service marks, and
similar terms, even if they are not identified as such, is not to be taken as an
expression of opinion as to whether or not they are subject to proprietary
rights.

Printed on acid-free paper

Springer is part of Springer Science+Business Media (www.springer.com)

This book is dedicated to Grace, Felix, and M’Liss, (and Henry and Yohan)

with grateful thanks for inspiration and patience.

Preface

R is an open-source and free software environment for statistical computing


and graphics. R compiles and runs on a wide variety of UNIX platforms
(e.g., GNU/Linux and FreeBSD), Windows, and Mac OSX. Since the late
1990s, R has been developed by hundreds of contributors and new
capabilities are added each month. The software is gaining popularity
because: 1) it is platform independent, 2) it is free, and 3) the source code is
freely available and can be inspected to determine exactly what R is doing.

Our objectives for this book are to 1) demonstrate the use of R as a solid
platform upon which forestry analysts can develop repeatable and clearly
documented methods; 2) provide guidance in the broad area of data
handling and analysis for forest and natural resources analytics; and 3) to
use R to solve problems we face each day as forest data analysts.

This book is intended for two broad audiences: students, researchers, and
software people who commonly handle forestry data; and forestry
practition-ers who need to develop actionable solutions to common
operational, tactical, and strategic problems. We often mention better and
more complete treatments of specific subject material for further reference
(e.g., forest sampling, spatial statistics, or operations research).

We hope that this book will serve as a field manual for practicing forest
analysts, managers, and researchers. We hope that it will be dog-eared,
defaced, coffee/tea-stained, and sticky-noted to near destruction. We hope
the reader will engage in the exercises, scrutinize its contents, forgive our
weaknesses, possibly and carefully absorb suggestions, and constructively
criticize.

Acknowledgments

This book would not have been possible without the patient and generous
assistance of many people. We first thank all the authors of the literature we
cite, who were willing to publish their data as part of their research.

vii

viii

Preface

These data are often our only link between repeatable research and
anecdotal opinion.

We thank Valerie LeMay and Timothy Gregoire for their kind contribution
of tree measurement data and for their encouragement and leadership in the
field. We thank Boris Zeide for his generous contribution of the von
Guttenberg data. We thank Don Wallace and Bruce Alber for supplying an
interesting dataset to demonstrate the data management, plotting, and file
functions in Chapter 2. We thank the Oregon State University College of
Forestry Research Forests web site for posting a publicly available forest
inventory for Chapters 2 and 4. Without those data, many of the examples
and topics in this book would have to have been performed using simulated
data and frankly would have been much less interesting. We thank Martin
Ritchie for providing data, funding, and snippets of code once lost and
found again during the development of the rconifers package, used in
Chapter 8. We thank David Hann for, years ago, providing an original copy
of the manuscript that we used to generate the shared library example
(chambers-1980.so) in Chapter 8 (Chambers, 1980).

We have received considerable constructive criticism via the review


process, only some of which we can source. We especially thank John
Kershaw for generous and detailed comments on Chapter 3, Jeff Gove for
his support and useful commentary on Chapter 5, and David Ratkowsky
and Graham Hepworth for their thoughtful and thought-provoking
comments on Chapters 6 and 7, respectively. Numerous other useful
comments were made by anonymous reviewers. The collection of review
comments improved the book immeasurably.

We thank R Core, the R community, and all the package authors and main-
tainers we have come to rely upon. Specifically, we thank the following
people, in no particular order: David B. Dahl (xtable); Lopaka Lee (R-
GLPK); Andrew Makhorin (GLPK); Roger Bivand (maptools); Deepayan
Sarkar (lattice); Hadley Wickham (ggplot2); Brian Ripley (MASS, class,
boot); Jose Pinheiro and Douglas Bates (nlme); Frank Harrell (Hmisc);
Alvaro Novo and Joe Schafer (norm); Greg Warnes (gmodels et al.);
Reinhard Furrer, Douglas Nychka, and Stephen Sain (fields); Thomas
Lumley (survey); and Nicholas J. Lewin-Koh and Roger Bivand
(maptools).

We thank John Kimmel, our managing editor at Springer, for showing in-
credible patience and Hal Henglein, our copy editor, for keeping us
consistent.

AR wishes to thank Mark Burgman for providing space to finish this book
within a packed ACERA calendar, and for his substantial support and
guidance. AR also wishes to thank Geoff Wood, Brian Turner, Alan Ek, and
Albert Stage for their kindness and intellectual support along the way.

JH wishes to thank Martin Ritchie, David Marshall, Kevin Boston, and


John Sessions for their support along the way.

Finally, we wish to thank our wives, children, and friends for cheerful
perseverance and support in the face of a task that seemed at times like a
little slice of Sisyphus.

Preface

ix

Melbourne and Corvallis


Andrew Robinson

August 16, 2010

Jeff D. Hamann

Contents

Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
.

vii

Part I Introduction and Data Management

Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

1.1

This Book . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

1.1.1

Topics Covered in This Book . . . . . . . . . . . . . . . . . . . . . .

1.1.2

Conventions Used in This Book . . . . . . . . . . . . . . . . . . . .

1.1.3
The Production of the Book . . . . . . . . . . . . . . . . . . . . . . .

1.2

Software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

1.2.1

Communicating with R . . . . . . . . . . . . . . . . . . . . . . . . . . .

1.2.2

Getting Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

1.2.3

Using Scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

11

1.2.4

Extending R . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

12

1.2.5

Programming Suggestions . . . . . . . . . . . . . . . . . . . . . . . . .

13
1.2.6

Programming Conventions . . . . . . . . . . . . . . . . . . . . . . . . .

14

1.2.7

Speaking Other Languages . . . . . . . . . . . . . . . . . . . . . . . .

15

1.3

Notes about Data Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

16

Forest Data Management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

19

2.1

Basic Concepts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

19

2.2

File Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

20

2.2.1

Text Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
20

2.2.2

Spreadsheets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

25

2.2.3

Using SQL in R . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

26

2.2.4

The foreign Package . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

26

2.2.5

Geographic Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

28

2.2.6

Other Data Formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

29

2.3

Data Management Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

30

2.3.1
Herbicide Trial Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

31

2.3.2

Simple Error Checking . . . . . . . . . . . . . . . . . . . . . . . . . . . .

33

xi

xii

Contents

2.3.3

Graphical error checking . . . . . . . . . . . . . . . . . . . . . . . . . .

34

2.3.4

Data Structure Functions . . . . . . . . . . . . . . . . . . . . . . . . . .

37

2.4

Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

43

2.4.1

Upper Flat Creek in the UIEF . . . . . . . . . . . . . . . . . . . . .

43
2.4.2

Sweetgum Stem Profiles . . . . . . . . . . . . . . . . . . . . . . . . . . .

46

2.4.3

FIA Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

51

2.4.4

Norway Spruce Profiles . . . . . . . . . . . . . . . . . . . . . . . . . . .

52

2.4.5

Grand Fir Profiles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

53

2.4.6

McDonald–Dunn Research Forest . . . . . . . . . . . . . . . . . .

55

2.4.7

Priest River Experimental Forest . . . . . . . . . . . . . . . . . . .

61

2.4.8

Leuschner . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
72

2.5

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

72

Part II Sampling and Mapping

Data Analysis for Common Inventory Methods . . . . . . . . . . .

75

3.1

Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

75

3.1.1

Infrastructure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

76

3.1.2

Example Datasets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

77

3.2

Estimate Computation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

77
3.2.1

Sampling Distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . .

77

3.2.2

Intervals from Large-Sample Theory . . . . . . . . . . . . . . . .

80

3.2.3

Intervals from Linearization . . . . . . . . . . . . . . . . . . . . . . .

81

3.2.4

Intervals from the Jackknife . . . . . . . . . . . . . . . . . . . . . . .

82

3.2.5

Intervals from the Bootstrap . . . . . . . . . . . . . . . . . . . . . . .

84

3.2.6

A Simulation Study . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

92

3.3

Single-Level Sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
94

3.3.1

Simple Random Sampling . . . . . . . . . . . . . . . . . . . . . . . . .

94

3.3.2

Systematic Sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

96

3.4

Hierarchical Sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

97

3.4.1

Cluster Sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

97

3.4.2

Two-Stage Sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100

3.5

Using Auxiliary Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104

3.5.1

Stratified Sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104

3.5.2

You might also like