0% found this document useful (0 votes)
11 views65 pages

29403

Download as pdf or txt
Download as pdf or txt
Download as pdf or txt
You are on page 1/ 65

Download the Full Version of textbook for Fast Typing at textbookfull.

com

Big Data Analytics with Java 1st Edition Rajat


Mehta

https://textbookfull.com/product/big-data-analytics-with-
java-1st-edition-rajat-mehta/

OR CLICK BUTTON

DOWNLOAD NOW

Download More textbook Instantly Today - Get Yours Now at textbookfull.com


Recommended digital products (PDF, EPUB, MOBI) that
you can download immediately if you are interested.

From Big Data to Big Profits Success with Data and


Analytics 1st Edition Russell Walker

https://textbookfull.com/product/from-big-data-to-big-profits-success-
with-data-and-analytics-1st-edition-russell-walker/

textboxfull.com

Big Data Analytics Second International Conference BDA


2013 Mysore India December 16 18 2013 Proceedings 1st
Edition Sameep Mehta
https://textbookfull.com/product/big-data-analytics-second-
international-conference-bda-2013-mysore-india-
december-16-18-2013-proceedings-1st-edition-sameep-mehta/
textboxfull.com

Big data and analytics for insurers 1st Edition Boobier

https://textbookfull.com/product/big-data-and-analytics-for-
insurers-1st-edition-boobier/

textboxfull.com

Big Data Analytics in Cybersecurity First Edition Deng

https://textbookfull.com/product/big-data-analytics-in-cybersecurity-
first-edition-deng/

textboxfull.com
Big Data Analytics Systems Algorithms Applications C.S.R.
Prabhu

https://textbookfull.com/product/big-data-analytics-systems-
algorithms-applications-c-s-r-prabhu/

textboxfull.com

Big Data Analytics for Intelligent Healthcare Management


1st Edition Nilanjan Dey

https://textbookfull.com/product/big-data-analytics-for-intelligent-
healthcare-management-1st-edition-nilanjan-dey/

textboxfull.com

Data Processing with Optimus: Supercharge big data


preparation tasks for analytics and machine learning with
Optimus using Dask and PySpark Leon
https://textbookfull.com/product/data-processing-with-optimus-
supercharge-big-data-preparation-tasks-for-analytics-and-machine-
learning-with-optimus-using-dask-and-pyspark-leon/
textboxfull.com

Emerging Technology and Architecture for Big data


Analytics 1st Edition Anupam Chattopadhyay

https://textbookfull.com/product/emerging-technology-and-architecture-
for-big-data-analytics-1st-edition-anupam-chattopadhyay/

textboxfull.com

Big Data in Practice How 45 Successful Companies Used Big


Data Analytics to Deliver Extraordinary Results 1st
Edition Bernard Marr
https://textbookfull.com/product/big-data-in-practice-
how-45-successful-companies-used-big-data-analytics-to-deliver-
extraordinary-results-1st-edition-bernard-marr/
textboxfull.com
Big Data Analytics with Java
Table of Contents
Big Data Analytics with Java
Credits
About the Author
About the Reviewers
www.PacktPub.com
eBooks, discount offers, and more
Why subscribe?
Customer Feedback
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Downloading the color images of this book
Errata
Piracy
Questions
1. Big Data Analytics with Java
Why data analytics on big data?
Big data for analytics
Big data – a bigger pay package for Java developers
Basics of Hadoop – a Java sub-project
Distributed computing on Hadoop
HDFS concepts
Design and architecture of HDFS
Main components of HDFS
HDFS simple commands
Apache Spark
Concepts
Transformations
Actions
Spark Java API
Spark samples using Java 8
Loading data
Data operations – cleansing and munging
Analyzing data – count, projection, grouping, aggregation, and max/min
Actions on RDDs
Paired RDDs
Transformations on paired RDDs
Saving data
Collecting and printing results
Executing Spark programs on Hadoop
Apache Spark sub-projects
Spark machine learning modules
MLlib Java API
Other machine learning libraries
Mahout – a popular Java ML library
Deeplearning4j – a deep learning library
Compressing data
Avro and Parquet
Summary
2. First Steps in Data Analysis
Datasets
Data cleaning and munging
Basic analysis of data with Spark SQL
Building SparkConf and context
Dataframe and datasets
Load and parse data
Analyzing data – the Spark-SQL way
Spark SQL for data exploration and analytics
Market basket analysis – Apriori algorithm
Full Apriori algorithm
Implementation of the Apriori algorithm in Apache Spark
Efficient market basket analysis using FP-Growth algorithm
Running FP-Growth on Apache Spark
Summary
3. Data Visualization
Data visualization with Java JFreeChart
Using charts in big data analytics
Time Series chart
All India seasonal and annual average temperature series dataset
Simple single Time Series chart
Multiple Time Series on a single chart window
Bar charts
Histograms
When would you use a histogram?
How to make histograms using JFreeChart?
Line charts
Scatter plots
Box plots
Advanced visualization technique
Prefuse
IVTK Graph toolkit
Other libraries
Summary
4. Basics of Machine Learning
What is machine learning?
Real-life examples of machine learning
Type of machine learning
A small sample case study of supervised and unsupervised learning
Steps for machine learning problems
Choosing the machine learning model
What are the feature types that can be extracted from the datasets?
How do you select the best features to train your models?
How do you run machine learning analytics on big data?
Getting and preparing data in Hadoop
Preparing the data
Formatting the data
Storing the data
Training and storing models on big data
Apache Spark machine learning API
The new Spark ML API
Summary
5. Regression on Big Data
Linear regression
What is simple linear regression?
Where is linear regression used?
Predicting house prices using linear regression
Dataset
Data cleaning and munging
Exploring the dataset
Running and testing the linear regression model
Logistic regression
Which mathematical functions does logistic regression use?
Where is logistic regression used?
Predicting heart disease using logistic regression
Dataset
Data cleaning and munging
Data exploration
Running and testing the logistic regression model
Summary
6. Naive Bayes and Sentiment Analysis
Conditional probability
Bayes theorem
Naive Bayes algorithm
Advantages of Naive Bayes
Disadvantages of Naive Bayes
Sentimental analysis
Concepts for sentimental analysis
Tokenization
Stop words removal
Stemming
N-grams
Term presence and Term Frequency
TF-IDF
Bag of words
Dataset
Data exploration of text data
Sentimental analysis on this dataset
SVM or Support Vector Machine
Summary
7. Decision Trees
What is a decision tree?
Building a decision tree
Choosing the best features for splitting the datasets
Advantages of using decision trees
Disadvantages of using decision trees
Dataset
Data exploration
Cleaning and munging the data
Training and testing the model
Summary
8. Ensembling on Big Data
Ensembling
Types of ensembling
Bagging
Boosting
Advantages and disadvantages of ensembling
Random forests
Gradient boosted trees (GBTs)
Classification problem and dataset used
Data exploration
Training and testing our random forest model
Training and testing our gradient boosted tree model
Summary
9. Recommendation Systems
Recommendation systems and their types
Content-based recommendation systems
Dataset
Content-based recommender on MovieLens dataset
Collaborative recommendation systems
Advantages
Disadvantages
Alternating least square – collaborative filtering
Summary
10. Clustering and Customer Segmentation on Big Data
Clustering
Types of clustering
Hierarchical clustering
K-means clustering
Bisecting k-means clustering
Customer segmentation
Dataset
Data exploration
Clustering for customer segmentation
Changing the clustering algorithm
Summary
11. Massive Graphs on Big Data
Refresher on graphs
Representing graphs
Common terminology on graphs
Common algorithms on graphs
Plotting graphs
Massive graphs on big data
Graph analytics
GraphFrames
Building a graph using GraphFrames
Graph analytics on airports and their flights
Datasets
Graph analytics on flights data
Summary
12. Real-Time Analytics on Big Data
Real-time analytics
Big data stack for real-time analytics
Real-time SQL queries on big data
Real-time data ingestion and storage
Real-time data processing
Real-time SQL queries using Impala
Flight delay analysis using Impala
Apache Kafka
Spark Streaming
Typical uses of Spark Streaming
Base project setup
Trending videos
Sentiment analysis in real time
Summary
13. Deep Learning Using Big Data
Introduction to neural networks
Perceptron
Problems with perceptrons
Sigmoid neuron
Multi-layer perceptrons
Accuracy of multi-layer perceptrons
Deep learning
Advantages and use cases of deep learning
Flower species classification using multi-Layer perceptrons
Deeplearning4j
Hand written digit recognizition using CNN
Diving into the code:
More information on deep learning
Summary
Index
Big Data Analytics with Java
Big Data Analytics with Java
Copyright © 2017 Packt Publishing

All rights reserved. No part of this book may be reproduced, stored in a retrieval
system, or transmitted in any form or by any means, without the prior written
permission of the publisher, except in the case of brief quotations embedded in
critical articles or reviews.

Every effort has been made in the preparation of this book to ensure the accuracy
of the information presented. However, the information contained in this book is
sold without warranty, either express or implied. Neither the author, nor Packt
Publishing, and its dealers and distributors will be held liable for any damages
caused or alleged to be caused directly or indirectly by this book.

Packt Publishing has endeavored to provide trademark information about all of


the companies and products mentioned in this book by the appropriate use of
capitals. However, Packt Publishing cannot guarantee the accuracy of this
information.

First published: July 2017

Production reference: 1270717

Published by Packt Publishing Ltd.

Livery Place

35 Livery Street

Birmingham B3 2PB, UK.

ISBN 978-1-78728-898-0

www.packtpub.com
Credits
Author

Rajat Mehta

Reviewers

Dave Wentzel

Roberto Casati

Commissioning Editor

Veena Pagare

Acquisition Editor

Chandan Kumar

Content Development Editor

Deepti Thore

Technical Editors

Jovita Alva

Sneha Hanchate

Copy Editors

Safis Editing

Laxmi Subramanian

Project Coordinator

Shweta H Birwatkar
Proofreader

Safis Editing

Indexer

Pratik Shirodkar

Graphics

Tania Dutta

Production Coordinator

Shantanu N. Zagade

Cover Work

Shantanu N. Zagade
About the Author
Rajat Mehta is a VP (technical architect) in technology at JP Morgan Chase in
New York. He is a Sun certified Java developer and has worked on Java-related
technologies for more than 16 years. His current role for the past few years
heavily involves the use of a big data stack and running analytics on it. He is
also a contributor to various open source projects that are available on his
GitHub repository, and is also a frequent writer for dev magazines.
About the Reviewers
Dave Wentzel is the CTO of Capax Global, a data consultancy specializing in
SQL Server, cloud, IoT, data science, and Hadoop technologies. Dave helps
customers with data modernization projects. For years, Dave worked at big
independent software vendors, dealing with the scalability limitations of
traditional relational databases. With the advent of Hadoop and big data
technologies everything changed. Things that were impossible to do with data
were suddenly within reach.

Before joining Capax, Dave worked at Microsoft, assisting customers with big
data solutions on Azure. Success for Dave is solving challenging problems at
companies he respects, with talented people who he admires.

Roberto Casati is a certified enterprise architect working in the financial


services market. Roberto lives in Milan, Italy, with his wife, their daughter, and a
dog.

In a former life, after graduating in engineering, he worked as a Java developer,


Java architect, and presales architect for the most important telecommunications,
travel, and financial services companies.

His interests and passions include data science, artificial intelligence,


technology, and food.
www.PacktPub.com
eBooks, discount offers, and more
Did you know that Packt offers eBook versions of every book published, with
PDF and ePub files available? You can upgrade to the eBook version at
www.PacktPub.com and as a print book customer, you are entitled to a discount
on the eBook copy. Get in touch with us at <customercare@packtpub.com> for
more details.

At www.PacktPub.com, you can also read a collection of free technical articles,


sign up for a range of free newsletters and receive exclusive discounts and offers
on Packt books and eBooks.

https://www.packtpub.com/mapt

Get the most in-demand software skills with Mapt. Mapt gives you full access to
all Packt books and video courses, as well as industry-leading tools to help you
plan your personal development and advance your career.
Why subscribe?
Fully searchable across every book published by Packt
Copy and paste, print, and bookmark content
On demand and accessible via a web browser
Customer Feedback
Thanks for purchasing this Packt book. At Packt, quality is at the heart of our
editorial process. To help us improve, please leave us an honest review on this
book’s Amazon page at https://www.amazon.com/dp/1787288986.

If you’d like to join our team of regular reviewers, you can e-mail us at
customerreviews@packtpub.com. We award our regular reviewers with free
eBooks and videos in exchange for their valuable feedback. Help us be relentless
in improving our products!

This book is dedicated to my mother Kanchan, my wife Harpreet, my daughter


Meher, my father Ashwini and my son Vivaan.
Preface
Even as you read this content, there is a revolution happening behind the scenes
in the field of big data. From every coffee that you pick up from a coffee store to
everything you click or purchase online, almost every transaction, click, or
choice of yours is getting analyzed. From this analysis, a lot of deductions are
now being made to offer you new stuff and better choices according to your
likes. These techniques and associated technologies are picking up so fast that as
developers we all should be a part of this new wave in the field of software. This
would allow us better prospects in our careers, as well as enhance our skill set to
directly impact the business we work for.

Earlier technologies such as machine learning and artificial intelligence used to


sit in the labs of many PhD students. But with the rise of big data, these
technologies have gone mainstream now. So, using these technologies, you can
now predict which advertisement the user is going to click on next, or which
product they would like to buy, or it can also show whether the image of a tumor
is cancerous or not. The opportunities here are vast. Big data in itself consists of
a whole lot of technologies whether cluster computing frameworks such as
Apache Spark or Tez or distributed filesystems such as HDFS and Amazon S3 or
real-time SQL on underlying data using Impala or Spark SQL.

This book provides a lot of information on big data technologies, including


machine learning, graph analytics, real-time analytics and an introductory
chapter on deep learning as well. I have tried to cover both technical and
conceptual aspects of these technologies. In doing so, I have used many real-
world case studies to depict how these technologies can be used in real life. So
this book will teach you how to run a fast algorithm on the transactional data
available on an e-commerce site to figure out which items sell together, or how
to run a page rank algorithm on a flight dataset to figure out the most important
airports in a country based on air traffic. There are many content gems like these
in the book for readers.
What this book covers
Chapter 1, Big Data Analytics with Java, starts with providing an introduction to
the core concepts of Hadoop and provides information on its key components. In
easy-to-understand explanations, it shows how the components fit together and
gives simple examples on the usage of the core components HDFS and Apache
Spark. This chapter also talks about the different sources of data that can put
their data inside Hadoop, their compression formats, and the systems that are
used to analyze that data.

Chapter 2, First Steps in Data Analysis, takes the first steps towards the field of
analytics on big data. We start with a simple example covering basic statistical
analytic steps, followed by two popular algorithms for building association rules
using the Apriori Algorithm and the FP-Growth Algorithm. For all case studies,
we have used realistic examples of an online e-commerce store to give insights
to users as to how these algorithms can be used in the real world.

Chapter 3, Data Visualization, helps you to understand what different types of


charts there are for data analysis, how to use them, and why. With this
understanding, we can make better decisions when exploring our data. This
chapter also contains lots of code samples to show the different types of charts
built using Apache Spark and the JFreeChart library.

Chapter 4, Basics of Machine Learning, helps you to understand the basic


theoretical concepts behind machine learning, such as what exactly is machine
learning, how it is used, examples of its use in real life, and the different forms
of machine learning. If you are new to the field of machine learning, or want to
brush up your existing knowledge on it, this chapter is for you. Here I will also
show how, as a developer, you should approach a machine learning problem,
including topics on feature extraction, feature selection, model testing, model
selection, and more.

Chapter 5, Regression on Big Data, explains how you can use linear regression
to predict continuous values and how you can do binary classification using
logistic regression. A real-world case study of house price evaluation based on
the different features of the house is used to explain the concepts of linear
regression. To explain the key concepts of logistic regression, a real-life case
study of detecting heart disease in a patient based on different features is used.

Chapter 6, Naive Bayes and Sentimental Analysis, explains a probabilistic


machine learning model called Naive Bayes and also briefly explains another
popular model called the support vector machine. The chapter starts with basic
concepts such as Bayes Theorem and then explains how these concepts are used
in Naive Bayes. I then use the model to predict the sentiment whether positive or
negative in a set of tweets from Twitter. The same case study is then re-run using
the support vector machine model.

Chapter 7, Decision Trees, explains that decision trees are like flowcharts and
can be programmatically built using concepts such as Entropy or Gini Impurity.
The golden egg in this chapter is a case study that shows how we can predict
whether a person's loan application will be approved or not using decision trees.

Chapter 8, Ensembling on Big Data, explains how ensembling plays a major role
in improving the performance of the predictive results. I cover different concepts
related to ensembling in this chapter, including techniques such as how multiple
models can be joined together using bagging or boosting thereby enhancing the
predictive outputs. We also cover the highly popular and accurate ensemble of
models, random forests and gradient-boosted trees. Finally, we predict loan
default by users in a dataset of a real-world Lending Club (a real online lending
company) using these models.

Chapter 9, Recommendation Systems, covers the particular concept that has


made machine learning so popular and it directly impacts business as well. In
this chapter, we show what recommendation systems are, what they can do, and
how they are built using machine learning. We cover both types of
recommendation systems: content-based and collaborative, and also cover their
good and bad points. Finally, we cover two case studies using the MovieLens
dataset to show recommendations to users for movies that they might like to see.

Chapter 10, Clustering and Customer Segmentation on Big Data, speaks about
clustering and how it can be used by a real-world e-commerce store to segment
their customers based on how valuable they are. I have covered both k-Means
clustering and bisecting k-Means clustering, and used both of them in the
corresponding case study on customer segmentation.
Chapter 11, Massive Graphs on Big Data, covers an interesting topic, graph
analytics. We start with a refresher on graphs, with basic concepts, and later go
on to explore the different forms of analytics that can be run on the graphs,
whether path-based analytics involving algorithms such as breadth-first search,
or connectivity analytics involving degrees of connection. A real-world flight
dataset is then used to explore the different forms of graph analytics, showing
analytical concepts such as finding top airports using the page rank algorithm.

Chapter 12, Real-Time Analytics on Big Data, speaks about real-time analytics
by first seeing a few examples of real-time analytics in the real world. We also
learn about the products that are used to build real-time analytics system on top
of big data. We particularly cover the concepts of Impala, Spark Streaming, and
Apache Kafka. Finally, we cover two real-life case studies on how we can build
trending videos from data that is generated in real-time, and also do sentiment
analysis on tweets by depicting a Twitter-like scenario using Apache Kafka and
Spark Streaming.

Chapter 13, Deep Learning Using Big Data, speaks about the wide range of
applications that deep learning has in real life whether it's self-driving cars,
disease detection, or speech recognition software. We start with the very basics
of what a biological neural network is and how it is mimicked in an artificial
neural network. We also cover a lot of the theory behind artificial neurons and
finally cover a simple case study of flower species detection using a multi-layer
perceptron. We conclude the chapter with a brief introduction to the
Deeplearning4j library and also cover a case study on handwritten digit
classification using convolution neural networks.
What you need for this book
There are a few things you will require to follow the examples in this book: a
text editor (I use Sublime Text), internet access, admin rights to your machine to
install applications and download sample code, and an IDE (I use Eclipse and
IntelliJ).

You will also need other software such as Java, Maven, Apache Spark, Spark
modules, the GraphFrames library, and the JFreeChart library. We mention the
required software in the respective chapters.

You also need a good computer with a good RAM size, or you can also run the
samples on Amazon AWS.
Who this book is for
If you already know some Java and understand the principles of big data, this
book is for you. This book can be used by a developer who has mostly worked
on web programming or any other field to switch into the world of analytics
using machine learning on big data.

A good understanding of Java and SQL is required. Some understanding of


technologies such as Apache Spark, basic graphs, and messaging will also be
beneficial.
Conventions
In this book, you will find a number of styles of text that distinguish between
different kinds of information. Here are some examples of these styles, and an
explanation of their meaning.

A block of code is set as follows:


Dataset<Row> rowDS = spark.read().csv("data/loan_train.csv");
rowDS.createOrReplaceTempView("loans");
Dataset<Row> loanAmtDS = spark.sql("select _c6 from loans");

When we wish to draw your attention to a particular part of a code block, the
relevant lines or items are set in bold:
Dataset<Row>data = spark.read().csv("data/heart_disease_data.csv");
System.out.println("Number of Rows -->" + data.count());

Note
Warnings or important notes appear in a box like this.
Tip
Tips and tricks appear like this.
Reader feedback
Feedback from our readers is always welcome. Let us know what you think
about this book—what you liked or may have disliked. Reader feedback is
important for us to develop titles that you really get the most out of.

To send us general feedback, simply send an e-mail to


<feedback@packtpub.com>, and mention the book title via the subject of your
message.

If there is a topic that you have expertise in and you are interested in either
writing or contributing to a book, see our author guide on
www.packtpub.com/authors.

If you have any questions, don't hesitate to look me up on LinkedIn via my


profile https://www.linkedin.com/in/rajatm/, I will be more than glad to help a
fellow software professional.
Customer support
Now that you are the proud owner of a Packt book, we have a number of things
to help you to get the most from your purchase.
Downloading the example code
You can download the example code files for all Packt books you have
purchased from your account at http://www.packtpub.com. If you purchased this
book elsewhere, you can visit http://www.packtpub.com/support and register to
have the files e-mailed directly to you.

You can download the code files by following these steps:


1. Log in or register to our website using your e-mail address and password.
2. Hover the mouse pointer on the SUPPORT tab at the top.
3. Click on Code Downloads & Errata.
4. Enter the name of the book in the Search box.
5. Select the book for which you're looking to download the code files.
6. Choose from the drop-down menu where you purchased this book from.
7. Click on Code Download.

You can also download the code files by clicking on the Code Files button on
the book's webpage at the Packt Publishing website. This page can be accessed
by entering the book's name in the Search box. Please note that you need to be
logged in to your Packt account.

Once the file is downloaded, please make sure that you unzip or extract the
folder using the latest version of:
WinRAR / 7-Zip for Windows
Zipeg / iZip / UnRarX for Mac
7-Zip / PeaZip for Linux

The code bundle for the book is also hosted on GitHub at


https://github.com/PacktPublishing/Big-Data-Analytics-with-Java. We also have
other code bundles from our rich catalog of books and videos available at
https://github.com/PacktPublishing/. Check them out!
Exploring the Variety of Random
Documents with Different Content
Soon four heavy guns were playing on the church tower, and the
tower crumbled. So are churches and other things destroyed in war
time.
It was now nearly ten, and we returned to our trench. Soon bullets
came whistling overhead, and we knew the attack had been
launched. We lay low in the dug-outs waiting till we were wanted.
Knowing the ground, I could picture clearly what was going on in
front, and I did not envy the Westshires their task. I could imagine
them getting out of their trenches and advancing in line over that
murderous stretch of ploughland. When we had been in the trenches
they were then leaving we had hardly dared show our noses above
them; but now the Westshires had the order, and out they had to
go, and forward. Phzz-phzz-phzz. The bullets began to come over
more quickly, and we could hear the answering fire of the
Westshires. It may have been half an hour that we lay there, and
then a hot, dusty figure crawled round the corner of the trench.
"Is the Captain of B Company there?"
"Yes, I'm here," Goyle answered.
The new arrival squatted down in the trench. It was the Adjutant of
the Westshires. He pulled out his pouch and started to fill his pipe.
His hands shook so that he could hardly get the tobacco into the
bowl. I shall never forget the way he breathed—hard, noisy gasps.
The man was evidently at breaking-point.
"How is it going?" Goyle asked.
"Oh, it's hell," the Adjutant of the Westshires answered.
"It is impossible to expect men to advance over such ground. We
have only got about twenty yards. We have had a hundred down
already—Leary and Blake are gone—Jones and Barty wounded. It is
no good—they can't carry on. Look here; what I came back for was,
would you send an officer with me, so that I can show him where
we want your men? Our fellows are rather shaken. I think it would
be a good thing if they would close up behind. One never knows
what might happen."
I could read the Adjutant's thoughts. He dreaded lest his men should
break. He knew if they had to advance farther they would be shot
down like rabbits. Poor man, he as Adjutant of the regiment was
responsible for the men's lives and conduct. The regiment was in
danger of being wiped out. No wonder his hand shook, and he
breathed in great gasps. Never have I seen a man so cruelly
strained. He grew calmer as he sat there, and presently Goyle sent
me back with him.
The Adjutant of the Westshires was quite calm as we returned to the
firing-line. We found the Colonel of the regiment sitting on the
ground behind a wall. He held a message in his hands. "Look there!"
He read out the message to the Adjutant.
"The —th Brigade will continue their attack on —— at 11.30 a.m. The
attack will be pressed home at all costs."
Both men looked at each other. They knew they had received the
regiment's death warrant. No attack could succeed over such
ground. The Colonel looked at his watch. I looked at the little iron-
grey man sitting there waiting for the hour when he was to send his
regiment to their doom. Then the Adjutant took me quietly, and
showed me the places where he wished our men to come up. He
was quite calm now as we peeped round the corner of a house at
the lines which had to be taken at all costs. The firing had stopped
now. The Westshires were lying out in the ploughland at the point
they had reached. The Germans lined their trenches waiting for
them to move.
But the time never came. Ten minutes later a staff officer had come
up, inspected the ground, and cancelled the second order for the
attack.
XIX. BY THE SKIN OF OUR TEETH
WE were moved to the village very suddenly. There was no reason
that we could see for the move. However, this transpired later. It was
getting dusk when we reached the village. A and C Companies were
sent at once up to the firing-line, and B and D Companies were lined
along a ditch in support. The ditch had been prepared for habitation
by the regiment who had held it before. At one point they had
thrown some boards across the ditch and made a house underneath.
This proved a very welcome shelter when later it came on to rain.
We lay in the ditch for an hour or two listening to the last shells
before nightfall, from one of our heavy batteries, singing overhead.
The shells were sent in groups of three, and we could plainly hear
each, whizz-whizz-whizz, chasing each other through the air, perhaps
not more than twenty yards apart. We were comfortable enough
where we were, and idly speculated on what errand of destruction
the shells were bent. They sounded nasty great things to have
coming in the wrong direction, and we wished the Germans joy of
them.
About eight I felt hungry, and got out of the trench to have a look
round. I had two tins of Mc'Conochie in my haversack, which I put in
a pan of boiling water. Across a field to the front I saw a farm, and
decided to go over and explore. In the field there were two or three
curious heaps of straw, which proved to be the burial piles of dead
cows, killed by shell fire, and covered over by the farmer in this
rather ineffective fashion. The cows were getting smelly, and I did
not stay long looking at them. I found the farm occupied by two old
men and an old woman. One of the old men, over eighty, they told
me, had taken to his bed and lain there with the shutters up for
three days. He was half-dead from fright, and could not be induced
to move. The old woman said they had had Germans billeted in the
farm a week before. They had treated her and her old husband none
too gently, driving them out of the house while they made soup in
her cauldron. She had managed to hide one or two little bits of
bread, and was making supper off a crust and some coffee. She put
the fire at my disposal for getting supper ready for Goyle and the
other officers in the company. They all came across a quarter of an
hour later, Evans with a great possession—a tin of cocoa. There was
plenty of milk to be had from the farm—indeed, it was a godsend to
the old people to get a man to milk their cows—and we soon had a
beautiful jug of thick, steaming cocoa. We then prepared the
Mc'Conochie, and what proved to be our last meal all together was a
good one.
It was getting late when we had finished, and we had to hurry back
to the support trench. On the way, as I was going along at a quick
trot, I came head over heels over a big object and nearly impaled
myself on a spike. Apart from the smell of the cow, it was really
most dangerous lying out there at night-time, and I sent a party of
men back to bury it.
The trenches we were to take over lay just beyond the village along
the crest of a slope. The section my company was responsible for
ran just in front of three haystacks. A company extended away to
our right, and the Dorchester Regiment continued the line to our
left. The officer of the regiment we were relieving said to me: "You
see those stacks—well, I should keep clear of them; the enemy have
them set." I nodded, very tired at finding myself back in the firing-
line, where we had been almost continuously for ten days, and not
particularly interested in what the enemy had set or what they had
not. In fact, as soon as I had seen the men distributed along the
trench, and had given one or two orders about its improvement, I
made straight for the centre stack, pulled as much hay as I could out
of the side of it, rolled myself up, and went to sleep.
I was awakened by a sharp blow in the back. Looking up I saw
Evans drawing his foot back to give me a second and harder kick.
"Get up, you blithering fool," he said; "your men are out all over the
place."
I jumped to my feet, and, fastening my belt as I ran, dashed for the
trench. I owed a lot to Evans for waking me. As Evans said, the men
were all walking about outside the trench. I got them in immediately,
and was preparing to follow when I thought of my bed, and went off
to fetch it. One never knew when the next chance of leaving the
trench might come. I was bending down, gathering a good armful of
hay, when there was a report, a sensation like red-hot iron running
through one, followed by acute pain, and I pitched head-forward
into the hay. I had been hit. Very frightened and hurt, I crawled as
fast as I could round to the side farthest from the enemy and sat
down. I examined my wounds—a bullet through each leg. The shots
were low down and did not look very serious. They hurt infernally,
and I made a mental note to call the next man who said he never
noticed he had been hit in the heat of an action a liar. I examined
the wounds. Were they serious enough to warrant a visit to the field-
dressing station and a possible return to England? I hoped devoutly
they were. An attempt to stand soon satisfied me, and I fell down
again, much relieved. All these thoughts were a matter of seconds;
in the meanwhile there was a good deal going on round the stack.
An enemy battery was playing round it with high-explosive shrapnel.
The shells burst first one side, then the other, in front, behind, in all
directions. The noise was deafening, and the lead in the air was just
like a hailstorm; however, it was a stout stack, and kept me dry,
though I confess I doubted getting away alive. After a few minutes
the firing stopped, and, throwing myself on my side, I rolled as fast
as I could for a support trench. I pitched head-first into the trench
and landed on the top of two privates who were sheltering in the
bottom expecting more shrapnel over at any minute. They were not
expecting me, and thought their last hour had come when I fell on
top of them. Getting our breath, we all three cursed each other.
Then, seeing I was an officer, they became respectful. I explained I
was wounded, and they helped me off with my puttees and bound
up the wounds with the first-aid bandage which I ripped from my
coat. In the meanwhile word was sent back for stretcher-bearers. As
the firing had stopped these came up immediately, lifted me out of
the trench, put me on a stretcher, and started off with me. We had
to go down a road in full view of the enemy. For some providential
reason they never fired at us, though I was about the last wounded
man to be brought down that road. Halfway down the road the
stretcher-bearers began to show signs of feeling my weight. I
coaxed them on a few more yards, but when they came to the lee of
a cottage they put me down and shook their heads; another bearer
came to the rescue, and with the extra help the party proceeded. A
hundred yards more brought us to a cottage which was being used
as a field-dressing station. The cottage was beginning to fill, and
wounded men lay about all over the floor.
"Oh, Gawd! Oh—! ——ooh!!"
"Shut up, can't yer?" a man shouted from the far corner of the room.
"I've got a 'ole in me big enough to put yer 'and in," the sufferer
explained, and began again to groan and swear.
"Got a cigarette, mate?" A man deathly pale on a stretcher held out
his hand to a comrade who was slightly wounded and standing
beside him. The latter extricated a Woodbine from a crumpled
packet and passed it down. The man on the stretcher lit the
cigarette and puffed at it phlegmatically. It was doubtful whether he
would live, and though he did not know this, he knew he must not
have anything to eat or drink for many hours.
About fifteen or twenty of us were lying on the floor of a cottage.
Outside, four or five hundred yards up the street, a lively fight was
in progress for the possession of the village. After the firing-line the
cottage seemed a haven of peace and safety.
"Hullo, they've got you."
"Morning, Doctor."
A young fellow, fresh from his training at a hospital, was standing
beside me. He was our regimental doctor, and I'd always thought of
him as a lucky fellow who rode on a horse when we were on the
march, got his rations regularly at all times, and during a scrap
enjoyed the security of the extra few hundred yards which he was
supposed to have between his dressing-station and the firing-line.
Well, here he was to look after me, anyhow.
"Got a bit of work to do to-day, Doctor," I said as he bound me up.
"Yes," he answered, adjusting a blanket as a pad under me, "there,
just keep in that position and the bleeding will soon stop." He turned
to the man next me.
"I've got some across the way, too," he said, as the orderly handed
him fresh bandages. "They've been shelling the poor beggars,
knocking all the slates off the roof."
As he spoke some shrapnel crashed against the roof of our cottage,
sending a few tiles rattling to the ground. The doctor looked up.
"I think we're all right here," he said. "We've got a double roof. I
always try to pick a cottage with a double roof. But those poor devils
over the way are getting awful scared; I think I'll slip across to
them."
The bit of road he had to "slip across" was catching most of the
shells which the cottage did not, and was also the channel for a
steady stream of rifle and machine-gun fire. I began to see there
wasn't much in it, whether one was a doctor or a platoon
commander.
More especially did I realize a doctor's difficulties when, later in the
day, just as our doctor had finished looking at my dressings, a
message came that the field-dressing station belonging to the
regiment on our left had been set alight by a shell. He hastily
organized a party of stretcher-bearers and orderlies and went off at
once. Later he came back. He said it had been terrible to see the
wounded lying helpless in the barn waiting for the flames, but
somehow they had managed to rescue all and move them to a safer
place, though the whole operation had to be carried out under rifle
and shell fire. Each time a regiment is seriously engaged with the
enemy at least 100 men are hit, often four times the number. The
regimental doctor is supposed to bind up each one of these, and
often when times are slack and a stray man here or there gets hit he
will be sent for to come up to the trenches.
"'Allo, Jock," loud greetings were shouted by every one in the room
to a little man standing in the doorway with a bandolier across his
chest and rifle with bayonet still fixed. He was a grubby little fellow,
with blood and mud caked all down his cheek, ragged clothes, and—
as I had seen as he came up the cottage steps—a pronounced limp.
It was Private Mutton, scallawag, humorist, and well-known
character in the regiment.
"Yus, they got me," he said in answer to inquiries, "fro' me calf," he
pointed to his leg, "and right acrost the top of me 'ead"—he raised
his cap and showed where a bullet had parted his hair, grazing the
scalp. "But I give the bloke somethink what did it." Private Mutton
grinned at his bayonet. "Got 'im fair, right fro' 'is stomick."
I could not help feeling delighted, for I recognized in the muddy,
gory, highly-pleased-with-himself little man the original of Thomas
Atkins, of whose doings along the Indian frontier I had read thrilling
accounts by Mr. Kipling, and whose quaint mannerisms I had often
laughed at as represented on the stage of music-halls at home....
At 9 p.m. the ambulances came up.
The doctor went round quickly attending to each man. He bound up
my wounds afresh and had me carried into an inner room. I lay
there all day, and never shall I forget the experience. I could see
nothing except a bit of the wall on the opposite side of the street.
But I could hear. Just after I had been brought in fresh firing broke
out. Rifle fire this time, sharp and insistent. Then there was a sound
of stamping feet, and I heard an officer rallying the men at the
corner of the street. The firing continued all day and sometimes
seemed to rage almost at the door of the cottage. I gathered that
the Germans were attacking the village in masses, and that it was
touch-and-go whether we could hold out. Sometimes there would be
a rush of men outside the window, and I would look to see if the
pale grey uniform was there or if khaki still held the place. Every
now and then a shower of shrapnel struck the roof of the cottage,
and tiles went rattling to the road. All the while a section of our
artillery fired incessantly. How gallant those guns of ours sound—
Boom-boom-boom. They were fighting to their last shell. If the
village went, they went with it. No horses could be brought up to
draw them away in such an inferno. The doctor worked on quietly.
His work extended now to houses on the left and right. He said it
was terrible to see the fear of death on the faces of men shot
through the stomach. He found time once to have a cup of tea with
me and smoke a cigarette. Night began to fall and the room grew
dark. I was glad of his company for five minutes. We were in the
same boat, he told me—if the Germans got the village he was going
to stay behind with the wounded.
At half-past five Evans came in with a smashed arm.
"Goyle has gone," he said. "He was hit twice before during the day.
He was holding out with a few men there and got a third through
the chest which did him. Edwards was shot through the knee, and
we had to leave him. All the company officers are down. A company
has been surrounded and cut off. Whew! you can't live out there."
As he spoke the firing swelled to a din unequalled through the day.
We heard shouts and curses. The Germans were making a final
tremendous effort to break through.
"Our boys may do it," said Evans, "but there are not many left." I lay
back against the wall, pulled out a cigarette, and threw one to
Evans. We could only wait. Suddenly outside we heard a stamp of
feet, a hoarsely yelled order, "Fix bayonets!" another word of
command, and a mass of men rushed past the window up the
street, cheering madly.
"That's the ——s," cried a stretcher-bearer, who came in excitedly.
"They have been sent up from the reserve."
The doctor came in. "We've got two more regiments up; we shall be
all right now," he said.
For a moment the firing continued, then died down. Night came and
found us still holding the village, and at ten o'clock the ambulance
took us away.
XX. "AND THENCE TO BED"
THE horse ambulance took us back some three miles to the field
ambulance, where we spent the night after being given some food
and tea and having our wounds dressed. The accommodation was
rough, just some straw on the floor, but to feel there were three
miles between ourselves and the enemy gave one quite a feeling of
being rested. At these field ambulances the work of dressing the
wounded goes on incessantly day and night, and it is here that many
a case of lockjaw or gangrene is prevented by the timely application
of antitetanus injection or iodine. Among the wounded was a young
German boy, not more than eighteen years old. The other wounded
Tommies and the orderlies were very good to him, making quite a
pet of the boy and giving him tea and cigarettes and asking him
what he thought about the war. He had only had six weeks' training
before being sent into the firing-line, and was a gentle enough
creature bewildered by the fierce struggle into which he had been
thrown.
In the morning a fleet of motor ambulances came to take us to the
clearing hospital at railhead. Most of these ambulances were private
cars fitted up at their owners' expense and driven in many cases by
the owners too. Only those who have been wounded and travelled in
a Government horse ambulance can appreciate the good work done
by these volunteer Red Cross workers and their cars. After the
lumbering horse vehicle rubber tyres and the well-hung body of a
private car are an unspeakable relief to broken bones. Our driver
was a young fellow who looked as though he had just left Oxford or
Cambridge. He drove us very slowly and carefully over the twelve
miles of bumpy road, and took us straight to the station in time to
have us put on a hospital train which was leaving that morning for
the base. How often at the beginning of the war on my way up to
the Front had I seen these hospital trains go by and wondered—with
a very pious hope that it might be so—if it would ever be my lot to
take a passage in one. In those days as now every one knew that it
was only a question of time before they were killed or wounded—
few last long enough to become diseased—and to be stowed safely
away in a hospital train labelled for England was the best fate that
could befall anyone.
It was, then, with a feeling of supreme contentment that I allowed
myself to be laid along the seat of a first-class carriage and propped
up behind with a greatcoat and a pillow. On the opposite seat was a
young gentleman not nearly so contented. He had been hit in the
shoulder. He said his wound was hurting him; that he was not
comfortable on the seat of the carriage; and that he considered
tinned stew (which had just been brought us) a very nasty luncheon.
I thought him a peevish and graceless cub and, when he snapped at
the orderly who came to clear away lunch, rebuked him.
I said that he ought to be thankful for being where he was at all;
that his wound was nothing compared to those of others in the
train; that his whining and peevishness brought discredit on his
uniform and regiment; and that he ought to be ashamed of himself
for making such a fuss. As he was a second lieutenant just fresh
from Sandhurst and I was an elderly subaltern of several years'
service he did not argue with me, but looked at the floor, while I
scowled at him from time to time across the carriage.
Eventually the train started and we began our journey to Boulogne.
We had been told it would take about nine hours, and so prepared
to make ourselves as comfortable as possible and sleep. Except for a
visit from the doctor to ask if we wanted anything, and from a
hospital nurse, nothing much happened for the rest of the day. The
visit from the hospital nurse is one of the things I remember most
clearly from an otherwise clouded period. It was the first taste of the
infinite sympathy and solicitude which women give to men returned
from the war. All who have experienced it—as every wounded man
has in abundant measure—must have felt that anything he has
suffered was worth such a reward.
After the visit from the hospital nurse we had some dinner and
settled down for the night. About this time I began to notice that the
blanket which had been folded in four and placed under my injured
leg was slightly rucked at the corner. I could not reach it to adjust it
myself and after the scene with my stable mate did not like to ask
his assistance. Presently an orderly came by and I called him in to
put it right. Half an hour later the same thing happened again and I
had to call in another orderly. The little subaltern, who was dozing,
opened one eye and looked at me reproachfully, but said nothing.
Later, when the train pulled up with a jerk which nearly threw us off
our seats, we both groaned softly, and when it did the same thing
again I swore, and received a grateful look from the rebuked
grumbler. In fact, to shorten the story, by noon the next day, when
we were finally taken out of the train, I was half hysterical with pain,
discomfort, and fatigue, and the little subaltern had nearly forgotten
his troubles in his efforts to adjust my blankets with his sound arm
and running to and fro fetching the orderly: the moral of this story
needs no pointing....
At Boulogne we were taken by motor ambulance to one of the base
hospitals. The hospital was a marvellous example of efficient
emergency organization. Three days before it had been a hotel; and
in this space of time—i.e. three days—the entire building had been
converted into a thoroughly modern hospital with wards and
operating-theatre. Most of the work had been done by the members
of the hospital staff themselves, and, as we were taken in, the last
bits of hotel furniture were still standing in the hall waiting to be
removed.
By this time I was rather exhausted, and I cannot remember more
than a matron in a dark silk dress with a very gentle, pretty face
bending over me and asking me if I was comfortable, and my
replying in a voice that was little above a whisper that it was good to
be in bed. I think she said, too, something to the nurse about "not
putting him to bed like that." I had been in the same clothes for a
fortnight and they were very muddy, and I remember having my
breeches cut off and being helped into a flannel night-shirt. I woke
later to find a nurse beside me with a basin of water. "Would you like
to wash?" she asked. I gazed at her apathetically. "Come on then, I'll
do it for you," she said kindly. She dipped a piece of flannel in the
basin and rubbed it gently over my face. Then she took one of my
hands and rubbed that; then streaks of white appeared down my
fingers as the caked mud was cleared. "There, I think that is all we'll
do for the present," she said, and feeling beautifully clean—though
in reality with ten days' beard and looking perfectly filthy—I lay back
on the pillow.
After tea I sat up, accepted a cigarette from my neighbour, and took
stock of the rest of the ward.
In the bed on my right was a man with a bandaged head; he had an
orderly beside him and was dictating a letter. He was evidently
feeling very weak, for he spoke with an obvious effort. The letter
was about some lost baggage, and dictated with the utmost
precision and detail. He ended by saying, "Signed James Brown,
Captain and Adjutant"; and I couldn't help smiling, for it was so like
an Adjutant to dictate a precise letter about some lost baggage, but
it seemed so funny for him, weakened by his wounds as he was, to
be lying there in bed doing it, and I felt sure it was more from force
of habit than anything else.
At eight o'clock the day-sister made a round of the wards with the
night-sister, handing over her patients till the next day. The night-
sister was followed by a sort of understudy who, I remember, was
tall and thin with rather a long nose. This understudy, who was
referred to as "nurse" by the other two, was, I gathered, a sort of
probationer, and not allowed to take much responsibility on herself.
By ten the ward was in darkness except for one green-shaded light,
and I think I must have dozed a little, for I remember looking up
suddenly to see the night-sister's understudy standing at the foot of
my bed and gazing at me with a puzzled expression. Seeing me
open my eyes she stretched out her arm and pulled towards her a
glass-topped table with a bowl of dressings on it. Then she studied
me again. I was still half asleep and watched her with half-closed
eyes.
"Is it your feet?" she asked.
I nodded.
She lifted the bedclothes back from the foot of the bed and surveyed
my bandaged feet for a minute or two. Then with a sudden air of
determination she bent down and, catching my right foot by the big
toe, lifted it deftly off the pillow on which it was resting. I gave one
piercing scream which woke the whole ward and brought the night-
sister running in. For the rest of the night I lay with one eye peeping
over the sheet prepared to yell for help at the top of my voice if the
young lady assistant came near my bed. The next day she returned
to England for further instruction.
The following afternoon I was operated on and the bullet extracted
from my ankle. A sergeant brought it me wrapped in cotton-wool
and left me feeling quite reassured about the success of the
operation....
I remember very well on the way up to the Front seeing a hospital
ship leave one of the base ports. She was a beautiful looking vessel,
painted white, with a great red cross painted on either side
amidships. That hospital ship certainly looked comfortable, and I
don't mind admitting that, at the time, I wished most heartily I was
on board her with my job done instead of having to go up to the
firing-line and do it. The wounded men on board all looked so happy
and comfortable.
However, everything comes to him who waits—nothing more quickly
than a bullet in these sanguinary days—and after a week at the base
hospital at Boulogne I was given a ticket marked "cot case" and told
I was going to be put on board a hospital ship for England. I smiled
gratefully at the doctor, tied the ticket round my neck, put on a
woollen waistcoat, muffler, and dressing-gown (all presented to me
by the hospital) over my pyjamas, and waited my turn to be carried
downstairs. In due course, with three others, I was taken in a motor
ambulance to the ship, and from thenceforward was in the charge of
the naval authorities.
We were carried up the gangway on our stretchers and placed on a
sort of luggage lift which in the twinkling of an eye transported us
below, where we were lifted on to swinging cots arranged in a large
saloon. The quick, handy way in which everything was done was
typical of the Navy, and having once spent six weeks on board a
battleship, I felt quite at home again. Dinner was brought round
soon after getting on board, and I ate soup, fish, roast mutton, and
apple tart with the heartiest of appetites. Unfortunately, also, in the
happiness of the moment, I drank a large bottle of Bass which
seriously affected my slumbers during the night.
We did not leave until the following night, arriving at Plymouth at
nine o'clock the next morning. However, it was no hardship to be
aboard the hospital ship.
The cots were just as comfortable as beds; there was every
appliance for dressing our wounds, and the nurses and doctors
looked after us indefatigably. In such surroundings aspects of the
war which are taken more seriously elsewhere are made light of. The
patients made jokes about each other's wounds and their own, and
all were so glad to be alive that pain and suffering were almost
forgotten. There was one fellow in the cot next to mine who in the
middle of a silence suddenly uttered an exclamation of annoyance.
Asked what was the matter, he said he wanted to know the time and
had just discovered he had lost his watch. It was a wrist watch, he
explained, and must have been left on the arm they had amputated
at the field ambulance.
At Plymouth we were taken on board a launch and landed at a quay
close by the naval hospital. The ingenious cots devised by the Navy
enable a wounded man to be moved bodily in his bed, all wrapped
up and warm, to the bed in the hospital. They are so made that they
can either be carried as stretchers, or slung from a ship's side, or put
on hand-trolleys and wheeled. The Naval Hospital at Plymouth is a
model of neatness and smartness, each patient in the officers'
quarters gets a small room to himself which is called a cabin; the
orderlies are all ex-sailors and handy and obliging as only sailors can
be; and the naval nurses in their smart blue uniforms are a pleasure
to watch.
I stayed at Plymouth for five days, when I was allowed to travel to
London.
PRINTED AT
THE BALLANTYNE PRESS
LONDON & EDINBURGH

SOLDIERS' TALES OF THE GREAT WAR


Each Volume Crown 8vo, Cloth, 3s 6d net
I
WITH MY REGIMENT
By "PLATOON COMMANDER"

[Ready
To be followed by
II
DIXMUDE
A chapter in the History of the Naval Brigade, Oct.-Nov.
1914
By CHARLES LE GOFFIC

Illustrated
III
IN THE FIELD (1914-15)
The Impressions of an Officer of Light Cavalry
IV
IN THE DARDANELLES AND SERBIA
Notes of a French Army Doctor
Illustrated
LONDON: WILLIAM HEINEMANN
21 Bedford Street, W.C.
*** END OF THE PROJECT GUTENBERG EBOOK WITH MY
REGIMENT ***

Updated editions will replace the previous one—the old editions will
be renamed.

Creating the works from print editions not protected by U.S.


copyright law means that no one owns a United States copyright in
these works, so the Foundation (and you!) can copy and distribute it
in the United States without permission and without paying
copyright royalties. Special rules, set forth in the General Terms of
Use part of this license, apply to copying and distributing Project
Gutenberg™ electronic works to protect the PROJECT GUTENBERG™
concept and trademark. Project Gutenberg is a registered trademark,
and may not be used if you charge for an eBook, except by following
the terms of the trademark license, including paying royalties for use
of the Project Gutenberg trademark. If you do not charge anything
for copies of this eBook, complying with the trademark license is
very easy. You may use this eBook for nearly any purpose such as
creation of derivative works, reports, performances and research.
Project Gutenberg eBooks may be modified and printed and given
away—you may do practically ANYTHING in the United States with
eBooks not protected by U.S. copyright law. Redistribution is subject
to the trademark license, especially commercial redistribution.

START: FULL LICENSE


THE FULL PROJECT GUTENBERG LICENSE
PLEASE READ THIS BEFORE YOU DISTRIBUTE OR USE THIS WORK

To protect the Project Gutenberg™ mission of promoting the free


distribution of electronic works, by using or distributing this work (or
any other work associated in any way with the phrase “Project
Gutenberg”), you agree to comply with all the terms of the Full
Project Gutenberg™ License available with this file or online at
www.gutenberg.org/license.

Section 1. General Terms of Use and


Redistributing Project Gutenberg™
electronic works
1.A. By reading or using any part of this Project Gutenberg™
electronic work, you indicate that you have read, understand, agree
to and accept all the terms of this license and intellectual property
(trademark/copyright) agreement. If you do not agree to abide by all
the terms of this agreement, you must cease using and return or
destroy all copies of Project Gutenberg™ electronic works in your
possession. If you paid a fee for obtaining a copy of or access to a
Project Gutenberg™ electronic work and you do not agree to be
bound by the terms of this agreement, you may obtain a refund
from the person or entity to whom you paid the fee as set forth in
paragraph 1.E.8.

1.B. “Project Gutenberg” is a registered trademark. It may only be


used on or associated in any way with an electronic work by people
who agree to be bound by the terms of this agreement. There are a
few things that you can do with most Project Gutenberg™ electronic
works even without complying with the full terms of this agreement.
See paragraph 1.C below. There are a lot of things you can do with
Project Gutenberg™ electronic works if you follow the terms of this
agreement and help preserve free future access to Project
Gutenberg™ electronic works. See paragraph 1.E below.
1.C. The Project Gutenberg Literary Archive Foundation (“the
Foundation” or PGLAF), owns a compilation copyright in the
collection of Project Gutenberg™ electronic works. Nearly all the
individual works in the collection are in the public domain in the
United States. If an individual work is unprotected by copyright law
in the United States and you are located in the United States, we do
not claim a right to prevent you from copying, distributing,
performing, displaying or creating derivative works based on the
work as long as all references to Project Gutenberg are removed. Of
course, we hope that you will support the Project Gutenberg™
mission of promoting free access to electronic works by freely
sharing Project Gutenberg™ works in compliance with the terms of
this agreement for keeping the Project Gutenberg™ name associated
with the work. You can easily comply with the terms of this
agreement by keeping this work in the same format with its attached
full Project Gutenberg™ License when you share it without charge
with others.

1.D. The copyright laws of the place where you are located also
govern what you can do with this work. Copyright laws in most
countries are in a constant state of change. If you are outside the
United States, check the laws of your country in addition to the
terms of this agreement before downloading, copying, displaying,
performing, distributing or creating derivative works based on this
work or any other Project Gutenberg™ work. The Foundation makes
no representations concerning the copyright status of any work in
any country other than the United States.

1.E. Unless you have removed all references to Project Gutenberg:

1.E.1. The following sentence, with active links to, or other


immediate access to, the full Project Gutenberg™ License must
appear prominently whenever any copy of a Project Gutenberg™
work (any work on which the phrase “Project Gutenberg” appears,
or with which the phrase “Project Gutenberg” is associated) is
accessed, displayed, performed, viewed, copied or distributed:
This eBook is for the use of anyone anywhere in the United
States and most other parts of the world at no cost and with
almost no restrictions whatsoever. You may copy it, give it away
or re-use it under the terms of the Project Gutenberg License
included with this eBook or online at www.gutenberg.org. If you
are not located in the United States, you will have to check the
laws of the country where you are located before using this
eBook.

1.E.2. If an individual Project Gutenberg™ electronic work is derived


from texts not protected by U.S. copyright law (does not contain a
notice indicating that it is posted with permission of the copyright
holder), the work can be copied and distributed to anyone in the
United States without paying any fees or charges. If you are
redistributing or providing access to a work with the phrase “Project
Gutenberg” associated with or appearing on the work, you must
comply either with the requirements of paragraphs 1.E.1 through
1.E.7 or obtain permission for the use of the work and the Project
Gutenberg™ trademark as set forth in paragraphs 1.E.8 or 1.E.9.

1.E.3. If an individual Project Gutenberg™ electronic work is posted


with the permission of the copyright holder, your use and distribution
must comply with both paragraphs 1.E.1 through 1.E.7 and any
additional terms imposed by the copyright holder. Additional terms
will be linked to the Project Gutenberg™ License for all works posted
with the permission of the copyright holder found at the beginning
of this work.

1.E.4. Do not unlink or detach or remove the full Project


Gutenberg™ License terms from this work, or any files containing a
part of this work or any other work associated with Project
Gutenberg™.

1.E.5. Do not copy, display, perform, distribute or redistribute this


electronic work, or any part of this electronic work, without
prominently displaying the sentence set forth in paragraph 1.E.1
with active links or immediate access to the full terms of the Project
Gutenberg™ License.

1.E.6. You may convert to and distribute this work in any binary,
compressed, marked up, nonproprietary or proprietary form,
including any word processing or hypertext form. However, if you
provide access to or distribute copies of a Project Gutenberg™ work
in a format other than “Plain Vanilla ASCII” or other format used in
the official version posted on the official Project Gutenberg™ website
(www.gutenberg.org), you must, at no additional cost, fee or
expense to the user, provide a copy, a means of exporting a copy, or
a means of obtaining a copy upon request, of the work in its original
“Plain Vanilla ASCII” or other form. Any alternate format must
include the full Project Gutenberg™ License as specified in
paragraph 1.E.1.

1.E.7. Do not charge a fee for access to, viewing, displaying,


performing, copying or distributing any Project Gutenberg™ works
unless you comply with paragraph 1.E.8 or 1.E.9.

1.E.8. You may charge a reasonable fee for copies of or providing


access to or distributing Project Gutenberg™ electronic works
provided that:

• You pay a royalty fee of 20% of the gross profits you derive
from the use of Project Gutenberg™ works calculated using the
method you already use to calculate your applicable taxes. The
fee is owed to the owner of the Project Gutenberg™ trademark,
but he has agreed to donate royalties under this paragraph to
the Project Gutenberg Literary Archive Foundation. Royalty
payments must be paid within 60 days following each date on
which you prepare (or are legally required to prepare) your
periodic tax returns. Royalty payments should be clearly marked
as such and sent to the Project Gutenberg Literary Archive
Foundation at the address specified in Section 4, “Information
about donations to the Project Gutenberg Literary Archive
Foundation.”

• You provide a full refund of any money paid by a user who


notifies you in writing (or by e-mail) within 30 days of receipt
that s/he does not agree to the terms of the full Project
Gutenberg™ License. You must require such a user to return or
destroy all copies of the works possessed in a physical medium
and discontinue all use of and all access to other copies of
Project Gutenberg™ works.

• You provide, in accordance with paragraph 1.F.3, a full refund of


any money paid for a work or a replacement copy, if a defect in
the electronic work is discovered and reported to you within 90
days of receipt of the work.

• You comply with all other terms of this agreement for free
distribution of Project Gutenberg™ works.

1.E.9. If you wish to charge a fee or distribute a Project Gutenberg™


electronic work or group of works on different terms than are set
forth in this agreement, you must obtain permission in writing from
the Project Gutenberg Literary Archive Foundation, the manager of
the Project Gutenberg™ trademark. Contact the Foundation as set
forth in Section 3 below.

1.F.

1.F.1. Project Gutenberg volunteers and employees expend


considerable effort to identify, do copyright research on, transcribe
and proofread works not protected by U.S. copyright law in creating
the Project Gutenberg™ collection. Despite these efforts, Project
Gutenberg™ electronic works, and the medium on which they may
be stored, may contain “Defects,” such as, but not limited to,
incomplete, inaccurate or corrupt data, transcription errors, a
copyright or other intellectual property infringement, a defective or
damaged disk or other medium, a computer virus, or computer
codes that damage or cannot be read by your equipment.

1.F.2. LIMITED WARRANTY, DISCLAIMER OF DAMAGES - Except for


the “Right of Replacement or Refund” described in paragraph 1.F.3,
the Project Gutenberg Literary Archive Foundation, the owner of the
Project Gutenberg™ trademark, and any other party distributing a
Project Gutenberg™ electronic work under this agreement, disclaim
all liability to you for damages, costs and expenses, including legal
fees. YOU AGREE THAT YOU HAVE NO REMEDIES FOR
NEGLIGENCE, STRICT LIABILITY, BREACH OF WARRANTY OR
BREACH OF CONTRACT EXCEPT THOSE PROVIDED IN PARAGRAPH
1.F.3. YOU AGREE THAT THE FOUNDATION, THE TRADEMARK
OWNER, AND ANY DISTRIBUTOR UNDER THIS AGREEMENT WILL
NOT BE LIABLE TO YOU FOR ACTUAL, DIRECT, INDIRECT,
CONSEQUENTIAL, PUNITIVE OR INCIDENTAL DAMAGES EVEN IF
YOU GIVE NOTICE OF THE POSSIBILITY OF SUCH DAMAGE.

1.F.3. LIMITED RIGHT OF REPLACEMENT OR REFUND - If you


discover a defect in this electronic work within 90 days of receiving
it, you can receive a refund of the money (if any) you paid for it by
sending a written explanation to the person you received the work
from. If you received the work on a physical medium, you must
return the medium with your written explanation. The person or
entity that provided you with the defective work may elect to provide
a replacement copy in lieu of a refund. If you received the work
electronically, the person or entity providing it to you may choose to
give you a second opportunity to receive the work electronically in
lieu of a refund. If the second copy is also defective, you may
demand a refund in writing without further opportunities to fix the
problem.

1.F.4. Except for the limited right of replacement or refund set forth
in paragraph 1.F.3, this work is provided to you ‘AS-IS’, WITH NO
OTHER WARRANTIES OF ANY KIND, EXPRESS OR IMPLIED,
INCLUDING BUT NOT LIMITED TO WARRANTIES OF
MERCHANTABILITY OR FITNESS FOR ANY PURPOSE.

1.F.5. Some states do not allow disclaimers of certain implied


warranties or the exclusion or limitation of certain types of damages.
If any disclaimer or limitation set forth in this agreement violates the
law of the state applicable to this agreement, the agreement shall be
interpreted to make the maximum disclaimer or limitation permitted
by the applicable state law. The invalidity or unenforceability of any
provision of this agreement shall not void the remaining provisions.

1.F.6. INDEMNITY - You agree to indemnify and hold the Foundation,


the trademark owner, any agent or employee of the Foundation,
anyone providing copies of Project Gutenberg™ electronic works in
accordance with this agreement, and any volunteers associated with
the production, promotion and distribution of Project Gutenberg™
electronic works, harmless from all liability, costs and expenses,
including legal fees, that arise directly or indirectly from any of the
following which you do or cause to occur: (a) distribution of this or
any Project Gutenberg™ work, (b) alteration, modification, or
additions or deletions to any Project Gutenberg™ work, and (c) any
Defect you cause.

Section 2. Information about the Mission


of Project Gutenberg™
Project Gutenberg™ is synonymous with the free distribution of
electronic works in formats readable by the widest variety of
computers including obsolete, old, middle-aged and new computers.
It exists because of the efforts of hundreds of volunteers and
donations from people in all walks of life.

Volunteers and financial support to provide volunteers with the


assistance they need are critical to reaching Project Gutenberg™’s
goals and ensuring that the Project Gutenberg™ collection will
remain freely available for generations to come. In 2001, the Project
Gutenberg Literary Archive Foundation was created to provide a
secure and permanent future for Project Gutenberg™ and future
generations. To learn more about the Project Gutenberg Literary
Archive Foundation and how your efforts and donations can help,
see Sections 3 and 4 and the Foundation information page at
www.gutenberg.org.

Section 3. Information about the Project


Gutenberg Literary Archive Foundation
The Project Gutenberg Literary Archive Foundation is a non-profit
501(c)(3) educational corporation organized under the laws of the
state of Mississippi and granted tax exempt status by the Internal
Revenue Service. The Foundation’s EIN or federal tax identification
number is 64-6221541. Contributions to the Project Gutenberg
Literary Archive Foundation are tax deductible to the full extent
permitted by U.S. federal laws and your state’s laws.

The Foundation’s business office is located at 809 North 1500 West,


Salt Lake City, UT 84116, (801) 596-1887. Email contact links and up
to date contact information can be found at the Foundation’s website
and official page at www.gutenberg.org/contact

Section 4. Information about Donations to


the Project Gutenberg Literary Archive
Foundation
Project Gutenberg™ depends upon and cannot survive without
widespread public support and donations to carry out its mission of
increasing the number of public domain and licensed works that can
be freely distributed in machine-readable form accessible by the
widest array of equipment including outdated equipment. Many
small donations ($1 to $5,000) are particularly important to
maintaining tax exempt status with the IRS.

The Foundation is committed to complying with the laws regulating


charities and charitable donations in all 50 states of the United
States. Compliance requirements are not uniform and it takes a
considerable effort, much paperwork and many fees to meet and
keep up with these requirements. We do not solicit donations in
locations where we have not received written confirmation of
compliance. To SEND DONATIONS or determine the status of
compliance for any particular state visit www.gutenberg.org/donate.

While we cannot and do not solicit contributions from states where


we have not met the solicitation requirements, we know of no
prohibition against accepting unsolicited donations from donors in
such states who approach us with offers to donate.

International donations are gratefully accepted, but we cannot make


any statements concerning tax treatment of donations received from
outside the United States. U.S. laws alone swamp our small staff.

Please check the Project Gutenberg web pages for current donation
methods and addresses. Donations are accepted in a number of
other ways including checks, online payments and credit card
donations. To donate, please visit: www.gutenberg.org/donate.

Section 5. General Information About


Project Gutenberg™ electronic works
Professor Michael S. Hart was the originator of the Project
Gutenberg™ concept of a library of electronic works that could be
freely shared with anyone. For forty years, he produced and
distributed Project Gutenberg™ eBooks with only a loose network of
volunteer support.
Project Gutenberg™ eBooks are often created from several printed
editions, all of which are confirmed as not protected by copyright in
the U.S. unless a copyright notice is included. Thus, we do not
necessarily keep eBooks in compliance with any particular paper
edition.

Most people start at our website which has the main PG search
facility: www.gutenberg.org.

This website includes information about Project Gutenberg™,


including how to make donations to the Project Gutenberg Literary
Archive Foundation, how to help produce our new eBooks, and how
to subscribe to our email newsletter to hear about new eBooks.
Welcome to our website – the ideal destination for book lovers and
knowledge seekers. With a mission to inspire endlessly, we offer a
vast collection of books, ranging from classic literary works to
specialized publications, self-development books, and children's
literature. Each book is a new journey of discovery, expanding
knowledge and enriching the soul of the reade

Our website is not just a platform for buying books, but a bridge
connecting readers to the timeless values of culture and wisdom. With
an elegant, user-friendly interface and an intelligent search system,
we are committed to providing a quick and convenient shopping
experience. Additionally, our special promotions and home delivery
services ensure that you save time and fully enjoy the joy of reading.

Let us accompany you on the journey of exploring knowledge and


personal growth!

textbookfull.com

You might also like