Unit 4: Probability Distributions
In this set of notes, you will learn about common probability distributions.
Preparation
Before class you will need to do the following:
- Read Section 3.1.1: Probability Basics in Fox [Required Textbook]
Read Sections 3.3.1–3.3.4 (Continuous Distributions) in Fox [Required Textbook]
Refresh your knowledge about probability distributions by going though the Kahn Academy: Random Variables and Probability Distributions tutorial.
4.1 Dataset and Research Question
In this set of notes, we will not be using a specific dataset.
# Load libraries
library(broom)
library(dplyr)
library(ggplot2)
library(readr)
library(sm)
library(tidyr)
4.2 Normal Distribution
The probability distribution of a normal distribution is mathematically defined as:
\[ p(x) = \frac{1}{\sigma\sqrt{2\pi}}\exp\left[-\frac{(x-\mu)^2}{2\sigma^2}\right] \]
for \(-\infty \leq x \leq \infty\). Consider a normal distribution with a mean (\(\mu\)) of 50, and a standard deviation (\(\sigma\)) of 10. We can compute the probability density (\(p(x)\)) for a particular \(x\) value by using this equation. For example, the probability density for \(x=65\) can be found using,
\[ p(65) = \frac{1}{10\sqrt{2\pi}}\exp\left[-\frac{(65-50)^2}{2\times10^2}\right] = 0.01295176 \]
Using R, we can carry out the computation,
(1 / (10 * sqrt(2 * pi))) * exp(-(225) / 200)
[1] 0.01295
There is also a more direct way to compute this using the dnorm()
function. This function computes the density of x
from a normal distribution with a specified mean
and sd
.
dnorm(x = 65, mean = 50, sd = 10)
[1] 0.01295
If we compute the density for several \(x\) values and plot them, we get the familiar normal shape; the graphical depiction of the mathematical equation.
# Create dataset
fig_01 = data.frame(
X = seq(from = 10, to = 90, by = 0.01)
) %>%
rowwise() %>%
mutate(
Y = dnorm(x = X, mean = 50, sd = 10)
)
# Create plot
ggplot(data = fig_01, aes(x = X, y = Y)) +
geom_line() +
theme_bw() +
geom_point(x = 65, y = 0.01295176, size = 3)
4.2.1 Other Useful R Functions for Working with Probability Distributions
There are four primary functions for working with the normal probability distribution:
dnorm()
: To compute the probability density (point on the curve)pnorm()
: To compute the probability (area under the PDF)qnorm()
: To compute the \(x\) value given a particular probabilityrnorm()
: To draw a random observation from the distribution
Each of these requires the arguments mean=
and sd=
. Let’s look at some of them in use.
4.2.2 Finding Cumulative Probability
The function pnorm()
gives the probability \(x\) is less than or equal to some quantile value in the distribution; the cumulative probability. For example, to find the probability that \(x \leq 65\) we would use,
pnorm(q = 65, mean = 50, sd = 10)
[1] 0.9332
This is akin to finding the proportion of the area under the normal PDF that is to the left of 65.
For the mathematically inclined, the grey-shaded area is expressed as an integral
\[ \int_{-\infty}^{65} p(x) dx \]
where \(p(x)\) is the PDF for the normal distribution.
4.2.3 Cumulative Density and \(p\)-Value
This type of computation is used most commonly to find a \(p\)-value. The \(p\)-value is just the area under the distribution (curve) that is AT LEAST as extreme as some observed value. Consider a hypothesis test of whether a population parameter is equal to 0. Also consider that we observed a statistic (that has been standardized) of \(z=2.5\). Then, the \(p\)-value can be graphically displayed in the standard normal distribution as follows:
In most hypothesis tests, we test whether the parameter IS EQUAL to 0. Thus the values in the standard normal distribution more extreme than 2.5 encompass evidence against the hypothesis; those values greater than 2.5 and also those values less than \(-2.5\). (This is akin to testing a fair coin when both 8 heads OR 8 tails would provide evidence against fairness we have to consider evidence in both directions).
To compute this we use pnorm()
. Remember, it computes the proportion of the area under the curve TO THE LEFT of a particular value. Here we will compute the are to the left of \(-2.5\) and then double it to produce the actual \(p\)-value.
2 * pnorm(q = -2.5, mean = 0, sd = 1)
[1] 0.01242
4.2.4 Finding Quantiles
The qnorm()
function is essentially the inverse of the pnorm()
function. The p
functions find the cumulative probability GIVEN a particular quantile. The q
functions find the quantile GIVEN a cumulative probability. For example, in the normal distribution we defined earlier, half of the area is below the quantile value of 50 (the mean).
qnorm(p = 0.5, mean = 50, sd = 10)
[1] 50
4.3 Student’s \(t\)-Distribution
Student’s \(t\)-distribution looks like a standard normal distribution. In the figure below, Student’s \(t\)-distribution is depicted with a solid, black line and the standard normal distribution (\(M=0\), \(SD=1\)) is depicted with a dotted, red line.
Both the standard normal distribution and Student’s \(t\)-distribution have a mean (expected value) of 0. The standard deviation for Student’s \(t\)-distribution is larger than the standard deviation for the standard normal distribution (\(SD>1\)). You can see this in the distribution because the tails in Student’s \(t\)-distribution are fatter (more error) than the standard normal distribution.
In practice, we often use Student’s \(t\)-distribution rather than the standard normal distribution when we are using sample data to estimate the population. This estimation increases the error and thus is typically modeled using Student’s \(t\)-distribution.
Student’s \(t\)-distribution constitutes a family of distributions—not just a single distribution. The specific shape (and thus probability density) is defined by the degrees of freedom; df. The plot below shows the standard normal distribution (purple) and four \(t\)-distributions with varying df-values.
df M SD
1 03 0 2.00
2 05 0 1.50
3 10 0 1.22
4 25 0 1.08
5 z 0 1.00
If we compare the means and SDs for these distributions, we find that the mean for all the \(t\)-distributions is 0, same as the standard normal distribution. All \(t\)-distributions are unimodal and symmetric around zero. The SD for every \(t\)-distribution is higher than the SD for the standard normal distribution. Student \(t\)-distributions with higher df values have less variation. It turns out that the standard normal distribution is a \(t\)-distribution with \(\infty\) df. For the formula for the SD in a \(t\)-distribution, see Fox (2009).
There are four primary functions for working with Student’s \(t\)-distribution:
dt()
: To compute the probability density (point on the curve)pt()
: To compute the probability (area under the PDF)qt()
: To compute the \(x\) value given a particular probabilityrt()
: To draw a random observation from the distribution
Each of these requires the arguments df=
. Let’s look at some of them in use.
4.3.1 Comparing Probability Densities
How do the probability densities for a value of \(X\) compare across these distributions? Let’s examine the \(X\) value of 2.
# Standard normal distribution
pnorm(q = 2, mean = 0, sd = 1)
[1] 0.9772
# t-distribution with 3 df
pt(q = 2, df = 3)
[1] 0.9303
# t-distribution with 5 df
pt(q = 2, df = 5)
[1] 0.949
# t-distribution with 10 df
pt(q = 2, df = 10)
[1] 0.9633
# t-distribution with 25 df
pt(q = 2, df = 25)
[1] 0.9718
We are essentially comparing the height of these distributions at \(X=2\).
4.3.2 Comparing Cumulative Densities
What if we wanted to look at cumulative density? Consider out hypothesis test of whether a population parameter is equal to 0. Also consider that we observed a statistic (that has been standardized) of 2.5 using a sample size of \(n=15\).
If we can assume that the SAMPLING DISTRIBUTION is normally-distributed then we can use the cumulative density in a normal distribution to compute a \(p\)-value:
2 * pnorm(q = -2.5, mean = 0, sd = 1)
[1] 0.01242
If, however, the SAMPLING DISTRIBUTION is \(t\)-distributed then we need to use the cumulative density for a \(t\)-distribution with the appropriate df to compute a \(p\)-value. For example if we use \(df=n-1\), the two-tailed \(p\)-value would be:
2 * pt(q = -2.5, df = 14)
[1] 0.02547
The \(p\)-value using the \(t\)-distribution is larger than the \(p\)-value computed based on the standard normal distribution. This is again because of the increased error (uncertainty) we are introducing when we estimate from sample. This added uncertainty makes it harder for us to reject a hypothesis.
4.4 Using the \(t\)-Distribution in Regression
To illustrate how probability distributions are used in practice, we will will use the riverview.csv (see the data codebook here) and fit a regression model that uses education level and seniority to predict variation in employee income.
# Read in data
city = read_csv(file = "~/Documents/github/epsy-8252/data/riverview.csv")
head(city)
# A tibble: 6 x 6
education income seniority gender male party
<dbl> <dbl> <dbl> <chr> <dbl> <chr>
1 8 37449 7 male 1 Democrat
2 8 26430 9 female 0 Independent
3 10 47034 14 male 1 Democrat
4 10 34182 16 female 0 Independent
5 10 25479 1 female 0 Republican
6 12 46488 11 female 0 Democrat
# Fit regression model
lm.1 = lm(income ~ 1 + education + seniority, data = city)
# Coefficient-level output
tidy(lm.1)
# A tibble: 3 x 5
term estimate std.error statistic p.value
<chr> <dbl> <dbl> <dbl> <dbl>
1 (Intercept) 6769. 5373. 1.26 0.218
2 education 2252. 335. 6.73 0.000000220
3 seniority 739. 210. 3.52 0.00146
How do we obtain the \(p\)-value for each of the coefficients? Recall that the coefficients and SEs for the coefficients are computed directly from the raw data. Then we can compute a test-statistic by dividing the coefficient estimate by the SE. For example, to compute the test-statistic associated with education level:
\[ t = \frac{2252}{335} = 6.72 \]
Since we are estimating the SE using sample data, our test statistic is likely \(t\)-distributed. Which value should we use for df? Well, for that, statistical theory tells us that we should use the error df value. In our data,
\[ \begin{split} n &= 32 \\ \mathrm{Total~df} &= 32-1 = 31\\ \mathrm{Model~df} &= 2~\mathrm{(two~predictors)} \\ \mathrm{Error~df} &= 31-2 = 29 \end{split} \]
Using the \(t\)-distribution with 29 df,
2 * pt(q = -6.72, df = 29)
[1] 0.0000002257
For seniority (and the intercept), we would use the same \(t\)-distribution, but our test statistic would differ:
\[ \begin{split} t_{\mathrm{Intercept}} &= \frac{6769}{5373} = 1.26 \\ t_{\mathrm{Seniority}} &= \frac{739}{210} = 3.52 \\ \end{split} \]
The associated \(p\)-values are:
# Intercept p-value
2 * pt(q = -1.26, df = 29)
[1] 0.2177
# Seniority p-value
2 * pt(q = -3.52, df = 29)
[1] 0.001446
4.5 Model-Level Inference: The \(F\)-Distribution
The model-level inference for regression is based on an \(F\)-statistic, which is a standardized measure of \(R^2\).
# Model-level output
glance(lm.1)
# A tibble: 1 x 11
r.squared adj.r.squared sigma statistic p.value df logLik AIC BIC
<dbl> <dbl> <dbl> <dbl> <dbl> <int> <dbl> <dbl> <dbl>
1 0.742 0.724 7646. 41.7 2.98e-9 3 -330. 668. 674.
# … with 2 more variables: deviance <dbl>, df.residual <int>
In this example, the sample \(R^2\) value is 0.742. Computation of the \(F\)-statistic relies on two df values—the model degrees of freedom (2) and the error degrees of freedom (29). To compute the \(F\)-statistics from \(R^2\) we use:
\[ F = \frac{R^2}{1-R^2} \times \frac{\mathrm{df}_{\mathrm{Error}}}{\mathrm{df}_{\mathrm{Model}}} \]
In our example, we compute \(F\) as:
\[ \begin{split} F &= \frac{0.742}{1-0.742} \times \frac{29}{2} \\ &= 41.7 \end{split} \]
We write this standardization of \(R^2\) as \(F(2,29)=41.7\).
4.5.1 Testing the Model-Level Null Hypothesis
It is often worth testing whether the model explains a statistically significant amount of variation in the population. To do this we test the null hypothesis:
\[ H_0:\rho^2 = 0 \]
Similar to the tests of the coefficients, we evaluate our test statistic (\(F\) in this case) in the appropriate test distribution, in this case an \(F\)-distribution with 2 and 29 degrees of freedom. (The shape of the \(F\)-distribution is based on two df values.) The figure below, shows the \(F(2,29)\)-distribution as a solid, black line.
The \(F\)-distribution, like the \(t\)-distribution is a family of distributions. They are positively skewed and generally have a lower-limit of 0. Because of this, when we use the \(F\)-distribution to compute a \(p\)-value, we only compute the cumulative density GREATER THAN OR EQUAL TO the value of the standardized test statistic.
<IP_ADDRESS> Computing F from the ANOVA Partitioning
We can also compute the model-level \(F\)-statistic using the partitioning of variation from the ANOVA table.
anova(lm.1)
Analysis of Variance Table
Response: income
Df Sum Sq Mean Sq F value Pr(>F)
education 1<PHONE_NUMBER><PHONE_NUMBER> 70.9 0.0000000028 ***
seniority 1 722883649 722883649 12.4 0.0015 **
Residuals 29<PHONE_NUMBER> 58459079
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
The \(F\)-statistic is a ratio of the mean square for the model and the mean square for the error. To compute a mean square we use the general computation
\[ \mathrm{MS} = \frac{\mathrm{SS}}{\mathrm{df}} \]
The model includes both the education and seniority predictor, so we combine the SS and df. The MS model is:
\[ \begin{split} \mathrm{MS}_{\mathrm{Model}} &= \frac{\mathrm{SS}_{\mathrm{Model}}}{\mathrm{df}_{\mathrm{Model}}} \\ &= \frac{4147330492 + 722883649}{1 + 1} \\ &= \frac{4870214141}{2} \\ &=<PHONE_NUMBER> \end{split} \]
The MS error is:
\[ \begin{split} \mathrm{MS}_{\mathrm{Error}} &= \frac{\mathrm{SS}_{\mathrm{Error}}}{\mathrm{df}_{\mathrm{Error}}} \\ &= \frac{1695313285 }{29} \\ &= 58459079 \end{split} \]
Then, we compute the \(F\)-statistic by computing the ratio of these two mean squares.
\[ \begin{split} F &= \frac{\mathrm{MS}_{\mathrm{Model}}}{\mathrm{MS}_{\mathrm{Error}}} \\ &= \frac{2435107070}{58459079} \\ &= 41.7 \end{split} \]
This is the observed \(F\)-statistic for the model. Note that this is an identical computation (although reframed) as the initial computation for \(F\).
$$ \begin{split} F &= \[1em] &= \[1em] &= \[1em] &= \[1em]
&= _{} \[1em] &= \end{split} $$
To test the null hypothesis, \(H_0:\rho^2=0\), we evaluate this observed \(F\)-statistic in an \(F\)-distribution with the 2 and 29 degrees of freedom.
The computation using the cumulative density function, pf()
, to obtain the \(p\)-value is:
1 - pf(41.7, df1 = 2, df2 = 29)
[1] 0.000000002942
4.6 Mean Squares are Variance Estimates
Mean squares are estimates of the variance. Consider the computational formula for the sample variance,
\[ \hat{\sigma}^2 = \frac{\sum(Y - \bar{Y})^2}{n-1} \]
This is the total sum of squares divided by the total df. When we compute an \(F\)-statistic, we are finding the ratio of two different variance estimates—one based on the model (explained variance) and one based on the error (unexplained variance). Under the null hypothesis that \(\rho^2 = 0\), we are assuming that all the variance is unexplained. In that case, our \(F\)-statistic would be close to zero. When the model explains a significant amount of variation, the numerator gets larger relative to the denominator and the \(F\)-value is larger.
The mean squared error (from the anova()
output) plays a special role in regression analysis. It is the variance estimate for the conditional distributions of the residuals in our visual depiction of the distributional assumptions of the residuals underlying linear regression.
Recall that we made implicit assumptions about the conditional distributions of the residuals, namely that they were identically and normally distributed with a mean of zero and some variance. Based on the estimate of the mean squared error, the variance of each of these distributions is 58,459,079.
While the variance is a mathematical convenience, the standard deviation is a better descriptor of the variation in these distributions. The standard deviation is 7646.
sqrt(58459079)
[1] 7646
We can also obtain this value from the model-level regression output. Here it is typically referred to as the Root Mean Squared Error (RMSE). In the glance()
output this value is in the sigma
column.
glance(lm.1)
# A tibble: 1 x 11
r.squared adj.r.squared sigma statistic p.value df logLik AIC BIC
<dbl> <dbl> <dbl> <dbl> <dbl> <int> <dbl> <dbl> <dbl>
1 0.742 0.724 7646. 41.7 2.98e-9 3 -330. 668. 674.
# … with 2 more variables: deviance <dbl>, df.residual <int>
Why is this value important? It gives the expected variation in the distribution. For example, since all of the conditional distributions of the residuals are normally distributed, we would expect that 95% of the residuals would fall between \(\pm2\) standard errors from 0; or, in this case, between \(-15292\) and 15292. Observations with residuals that are more extreme may be regression outliers.
References
Fox, J. (2009). A mathematical primer for social statistics. Thousand Oaks, CA: Sage.


Famous Train Depot
Only Famous Trains Come Through Here
Current Train Schedule
Train Name
Destination
Frequency (min)
Next Arrival
Minutes Away
Additional Train Schedules
Train Name
Destination
First Train Time (HH:mm - military time)
Frequency (min)
Submit


Range Modeling
Species Range Modeling with Maxent
Scope
This lesson will take us through the steps involved in creating a species range model using the Maximum Entropy probability distribution.
Before we load in any data we should set the project projection.
To add this to QGIS you can go into the top menu:
Settings > Custom CRS…
Click Add new CRS to create a new custom projection
In the box labeled Name: enter New World LAEA
Under parameters enter the following Proj4 string:
+proj=laea +lat_0=15 +lon_0=-80 +x_0=0 +y_0=0 +ellps=WGS84 +toWGS84=0,0,0,0,0,0,0 +units=m +no_defs
The window should look like this:
Click OK to exit the window
To make set the project projection, in the top menu select Project > Project Properies
You will need to select Enable ‘on the fly’ CRS transformation to set the projection.
You can either scroll through the choices in the second window, or filter them by the string “New World”
Select the projection in the second window and Click Apply
Data Collection
This model will require a comma-separated list of species observation locations.
There are two viable inputs to the modeling algorithm:
CSV with species name, longitude, latitude
SWD file with raster values sampled from points
Since the SWD files make the Maximum entropy algorithm much more performant, we will create one from a regular csv.
We can use QGIS to create these files.
The workflow is as follows:
Load a species shapefile:
We will be loading the layers for this exercise using the QGIS Irods plugin.
To install the plugin, in the Top Menu go to Plugins > Manage and Install Plugins…
In the left sidebar click Get more
You can either scroll through the plugins or search for iRods
You can install the plugin by clicking Install plugin and you should receive this message
You can now click on Installed in the left sidebar to ensure that the iRods plugin is both installed and enabled.
If you have already set up your iPlant account and were given permissions to the Bootcamp dataset continue to the next steps.
If not, make sure to register for iPlant access, and request access to the data store.
Once, you have access to the data store you can open up the iRods plugin to view the available datasets.
Once you click on the iRods icon, a window should show up where you can enter in your iplant account credentials
This should open up a window with your local files, to get to the Bootcamp files, you will have to set the directory using Set Datastore
In the bottom right of the window click Set Datastore
In the next prompt, enter “/iplant/home/shared/aegis/Spatial-bootcamp”
Click set to close the dialog.
You should see a new window with a series of directories.
For this exercise our files will be found under “Range-model”
We can use the Abies amabilis shapefile titled: Abies_amabilis.shp
The layer name should come up in the left Table of Contents and the points should show up on the center panel.
Since the Species CSV comes in EPSG:4326, and the environmental variables come in a custom projection, we will need to repojrect the species layer.
To check the species projection you can right-click the Abies_amabilis in the Table of Contents and select Properties
The Layer properties window will display the layer’s Coordinate Reference System:
To change the projection, you can close out of the Layer Properties window.
Right click the Abies_amabilis layer in the Table of Contents and select Save as…
You can leave the format as ESRI Shapefile
Click browse to set the location for the output file and name it abies_projected.
Under CRS select Project CRS
Finally check the Add saved file to map option
Right click the new layer and check the layer Properties to make sure the Coordinate Reference System is New World LAEA
If the projection matches, you can remove the original Abies_amabilis layer from the Table of Contents by Right-clicking and selecting Remove
Now that you have the points projected. We need to import the environmental layers.
These files will be stored in the sub-directory Range-model/env
They will need to be downloaded however, so the gdal drivers can merge them.
The environmental layers can be found in the iPlant data store in the env.zip file.
To download the layers, sign in to the iPlant Discovery Environment and open the Data Store.
The layers should be available under /iplant/home/shared/aegis/Spatial-bootcamp/Range-model/env.zip
To download the archive, check the file and click Download > Simple Download in the Menu bar.
Download the zip file to your workspace and unzip the directory. You should find a group of ascii rasters.
You can load the ascii rasters into QGIS as Raster datasets.
Click the Add Raster button, navigate to the unzipped directory and select all of the ascii rasters.
Once all the rasters are loaded, you should see them in your Table of Contents, but not on the map.
If you check the layer properties on one of the rasters, you can see that they default to EPSG:4326, although we had previously stated they come in the New World LAEA.
This happens because Ascii Grid Format doesn’t store any projection information.
To allow any analysis, we will have to define the projection for the raster data sets.
To do this, you can click on the layer name in the Table of Contents and Select Set Layer CRS
Select New WOrld LAEA from the list of projections and click OK
Check the layer properties to make sure the projection has been set.
Repeat the above steps for each of the ascii rasters until they all have the proper projection.
SWD creation
To create the SWD, we need to sample the environmental variable layers at the observation points. To do this, we will need to install the Point Sampling Plugin.
In the top menu, click Plugins > Manage and Install Plugins…
Click Get more in the left menu and Search for Point sampling
Click Install plugin and check that it is enabled under the list of installed plugins.
Navigate to Plugins > Analyses > Point Sampling Tool
In the dialog that opens, select abies_projected as the Layer containing sampling points
Under Layers with fields/bands to get values from: Select all of the environmental layers with type (raster)
Under Output point vector layer: Click Browse and select the location for the output.
Name the output Abies_swd.shp and make sure Add created layer to the TOC is checked
To make sure that the point sampling worked, we will check the new attribute table.
We are almost done with our SWD, the next step is to add a column with the species name.
While we are in the attribute table you can add a column using the field calculator.
First, we need to Start an editing session on our attribute table by clicking the Toggle Edits Button in the upper left corner of the table.
Next, open the Raster Calculator on the right side of the toolbar.
In the dialog that opens, make sure that *Create a new field is checked.
Set the output field name to species with a field type of Text (string) and a length of 14
Set the expression to ‘Abies_amabils’ to set the value for each row to the species name.
Once the column has been added, save your edits by hitting the Save Edits Button next to the Toggle Edits Button.
Now that we have our species name in the table, we need to create a csv for Maxent to read.


{% extends "minimal.html" %} {% load humanize %} {% block title %} Appointment Letter — Human Resources — Carthage College {% endblock %} {% block extra_style %} {% endblock %} {% block content %}
{% now "F j, Y" %}
{{data.first_name}} {{data.last_name}}
{{data.home_address}}
{{data.city}}, {{data.state}} {{data.postal_code}}
Dear {{data.first_name}},
It is my pleasure to offer you the position of {{data.position_title}} beginning {{data.expected_start_date}}, reporting to {{data.reporting_to}}. This position is designated as {{data.position_type}} {{data.pay_type}} at the rate of ${{data.offered_compensation|intcomma}}.
{{data.other_arrangements}}
As we discussed during the interview process. Carthage College offers employees and their eligible dependents a variety of group health insurance benefits. Coverage under these programs commences on the first day of employment. Information about these programs and other company benefits are contained in the summary plan description which will be sent to you electronically in onboarding materials.
Upon acceptance, you will receive an email linking you to the necessary paperwork for employment. Please keep an eye on your email for these materials. During your first week, the Human Resources team will meet with you to conduct your benefits orientation and complete any paperwork that is outstanding. It is important to bring the required forms of identification for the Form I-9 completion (required by federal law to verify eligibility to work in the U.S).
This offer is based on confidence that your employment with Carthage College will be mutually rewarding and enriching experience, but this offer does not constitute a contract of employment, nor does it guarantee a lifetime security. Employment at Carthage College is employment-at-will. Please note this offer is also contingent upon the successful completion of a background check.
{{data.first_name}}, I am delighted that you have decided to join our team and look forward to working with you. Our rich academic experience equips students with foundational knowledge and skills, preparing graduates to be lifelong learners, and to lead meaningful, productive lives. It is a very exciting time for our entire organization and we are happy that you have chosen to be a part of it.
We ask you sign and return this letter, indicating acceptance of the position.
I ____________________________________________________ accept the position as stated above.
Signature _____________________________________________________
Date _________________________________________________________
Sincerely,
{{data.reporting_to}}


What is an Array?
An array is a collection of objects(programming objects). They could be strings, integers, or even other arrays(multi-dimensional arrays).
The kind of information an array holds is entirely up to you. When you define an array, you can put the things you want inside of it. You can add on to it, or remove from it, later at any time. It could be all strings, all integers, a mix of any objects you want it to hold.
They don't just sit there though. We can at any time access the elements we placed inside the array. We do this by using the array's index. array[0]
refers to the 1st element we put in the array. array[1]
is the second. array[-1]
is the last item on the array(no matter the size). array[-2]
would be the second to last element.
Arrays are set up to be ordered in the way you added them. If you remove an element from anywhere but the end, all the rest after the removed element shift down one index.
This can get confusing and messy if you're not exactly sure which elements you're moving around and where the rest end up afterwards. But in Ruby you can use another information container...a hash!
What is a Hash?
A hash, like an array, is a collection of objects. Also, like an array, they can be any mixture of objects, and the objects can be access at any time. The elements are ordered by the order you place them in the hash.
However, we don't access them via an index starting from 0 and moving on. We can, in fact, give the objects their own identifier. We call them keys, and the objects we call values.
When to use what?
This section will be fairly short.
We can use them for the most part, interchangeably. However, as I said earlier, using arrays can get messy sometimes. Generally, use a hash when you have specific important information. A contact book would be great. You can use their name as a key, and it points to their phone number. An array would probably be a better place for something like grocery list of sorts, where specificity isn't needed, and items can be removed from anywhere and it won't much matter.


Stars on stage at concert for Andre
A talented line-up of past and present students from Ashburton College, as well as a trio of current teachers, will perform at a variety fundraising concert on November 29.
The event is called Performing For Andre and will raise money for Andre Van Rooyen, the former Mid Canterbury Tennis coach who is battling Stage 4 lung cancer and having costly drug treatment.
Mr Van Rooyen's wife, Debbie, is the Gateway co-ordinator at Ashburton College and the concert is being promoted and supported by the college and tennis communities.
On stage will be singers, dancers, bands and there's also a bit of comedy thrown in.
The MC for the event is Ashburton College deputy principal Ron Cresswell, who is also a performer, as is dance and drama teacher Jack Hanrahan and dance teacher Hannah Wakelin.
Former students taking to the stage include Jack Bubb, who is at jazz school in Christchurch, Libby Higson, who has just graduated from NASDA, Luke Glendining and Lucy Clough.
Talented students include singer Ocean Waitokia, hip-hop group leader Carl Cayanan and polyfest group leader Sonia Stephens-Tahuri.
Two college rock bands will also play.
Ashburton College head of senior school Claire Bubb said the concert was set to be a great night of entertainment.
There would be a wealth of talent on stage and the goal was to raise $10,000 for the Van Rooyen family, enough to fund Mr Van Rooyen's drug treatment for a month.
All performers would come together as a collective to sing a special finale song for the guests of honour.
The evening would also include a number of auctions.
Food and drink prizes had been donated by Somerset Grocer, Speight's Ale House, Cleavers Corner and Robert Harris Cafe.
Mid Canterbury tennis coach Jack Tiller had given coaching vouchers and there was wood from Jag Firewood.
"This event is about supporting the Van Rooyens during this very difficult time, creating memories for them, and raising as much money as we can,'' said Mrs Bubb.
The Ashburton College Auditorium is the venue for the concert.
An eftpos will be operating on the night and donations can be made to support Mr Van Rooyen's treatment.
Tickets ($20) can be bought from the college office, or by calling 308 4193.


PBoC's Yi: Will continue to push real lending rates lower
by Eren SengezerYi Gang, the Governor of the People's Bank of China (PBoC), crossed the wires in the last minutes repeating that they will step up counter-cyclical adjustments for the economy and added that they will increase credit support as well.
"We will continue to push real lending rates lower," the governor added. "We will promote capital replenishment for banks to increase lending capability. Stable operation of China's macroeconomy and financial sector face challenges."
These comments don't seem to be having an impact on the market sentiment. As of writing, the 10-year US Treasury bond yield was up 0.4% on a daily basis at 1.826%.


Our editor outputs blocks of texts with paragraph tags.
Note that we also sprinkle in sibling helper classes with story-body. For example, the t-linkstyle helper gives us the ability to style links like this.
Use a horizontal rule to break up content. A horizontal rule is displayed below.
The hr tag has built in top and bottom margin. We do this because it's normally used as a spacing element and the need for cushion is assumed.
Plugins are special and have their own rules for positioning. A div without the plugin class will still align with the story text, but any div prefixed with "c-plugin" will be excluded from the max-width and margin declaration the other elements adhere to.
This is a standard paragraph. Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
"This is a blockquote. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem. Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl."
This is a standard paragraph. Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
The first rule sets a sitewide font and a baseline font size of 10px. These are inherited by everything on the page.
Rules 2 and 3 set relative font sizes for the headings, different list types (the children of the list elements inherit these), and paragraphs. This means that each paragraph and list will have the same font size and top and bottom spacing, helping to keep the vertical rhythm consistent.
Rule 4 sets the same line-height on the paragraphs and list items — so the paragraphs and each individual list item will have the same spacing between lines. This will also help to keep the vertical rhythm consistent.
Rules 5 and 6 apply to the description list — we set the same line-height on the description list terms and descriptions as we did with the paragraphs and list items. Again, consistency is good! We also make the description terms have bold font, so they visually stand out easier.
This is a standard paragraph. Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
The details example text. It may be styled differently based on what browser or operating system you are using.
The a element and external a element examples
The abbr element and an abbr element with title examples
The ACRONYM element example
The b element example
The cite element example
The code element
example
The data element example
The del element example
The dfn element and dfn element with title examples
The em element example
The i element example
The ins element example
The kbd element example
The mark element example
The q element
example
The q element
example
inside
a q element
The s element example
The samp element example
The small element example
The span element example
The strong element example
The sub element example
The sup element example
The example
The u element example
The var element example
Code block wrapped in "pre" and "code" tags
// Loop through Divs using Javascript.
var divs = document.querySelectorAll('div'), i;
for (i = 0; i < divs.length; ++i) {
divs[i].style.color = "green";
}
Monospace Text wrapped in "pre" tags
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Nullam dignissim convallis est. Quisque aliquam. Donec faucibus. Nunc iaculis suscipit dui. Nam sit amet sem. Aliquam libero nisi, imperdiet at, tincidunt nec, gravida vehicula, nisl.


I have been training Muay Thai and MMA for awhile now and doing a fight was something that has always been in the back of my mind. Fighting is the ultimate flow state where their is no time to think, you are relying on your instincts, muscle memory and just flowing as you should. I am not one to shy away from a challenge.  For instance - discipline, confidence, patience, respect and learning to trust in myself. I believe that everyone should put themselves in a similar situation at least once in their life to see how they react and find out who they are.
To be Continued.
Weight Cutting process
Fortunately I had to only lose 2kg on fight week. I followed this rough guide for water loading/cutting and adapted it based on my situation: https://tim.blog/2013/05/06/how-to-cut-weight-ufc/
I weighed in at 67.1 kg, well under the fight weight of 68 kg. This is the lightest I had been in years.
Training
TODO:
- Ended up being sick a week out from the fight, and then on the fight night itself
- Running 2x a week
- Occasionally gym
- All classes at MTI (2 weeks out from fight)
Mental Preparation
- Staredown in the ring, noticed that he flinched which gave me confidence.
The Fight / Inside the Ring
TODO: Some comments on my experience:
- Ended up being sick on night
- Adreneline
- Tunnel vision, you almost forget about the crowd, just feels like there’s you and your opponent
- Flow state
- Fully focused, immersed in concentration, patient, surprising silent for such a loud environment
- Tried to control the distance, shutdown any moves with teeps, patiently stalk my opponent, and strike when I had confidence I was going to land. I was cautious in there.
- Fast paced, no time to think, you are almost limited in your moves (i.e. I did not even try any fancy moves like question mark kicks that I was planning to before the fight)
- Ring was a lot slippery than I thought so was hestitant to throw too many kicks and slip.
- Difficult to hear your corner when you’re in there, and a lot harder to execute moves than expected
- Actually forgot to breath out during each punch and kick.


Sundaram BNP Paribas HF renamed
by Special CorrespondentThe name of Sundaram BNP Paribas Home Finance Ltd. has been changed to Sundaram Home Finance Ltd. with effect from Monday, following the receipt of all regulatory approvals relating to the acquisition of BNP Paribas Personal Finance S.A. France.
In June 2019, Sundaram Finance Ltd. (SFL) and BNP Paribas Personal Finance had reached an agreement, whereby BNP Paribas Personal Finance had agreed to sell its entire 49.9% equity stake in Sundaram BNP Paribas Home Finance Ltd. to SFL.
The transaction was completed on September 30 after regulatory approvals. The name change is a consequence to this, the company said.


Input target genes
>
Submit
Currently 12,374 genes are available.
link to a list of genes
Please reload the page in case the select box could not work well.
(e.g.: If you cannot enter gene name from keyboard)


The following table describes the OrderStatus
enumeration members:
| Member | Value | Description |
|---|---|---|
| New | 0 | New order pre-submission to the order processor (0) |
| Submitted | 1 | Order submitted to the market (1) |
| PartiallyFilled | 2 | Partially filled, In Market Order (2) |
| Filled | 3 | Completed, Filled, In Market Order (3) |
| Canceled | 5 | Order cancelled before it was filled (5) |
| None | 6 | No Order State Yet (6) |
| Invalid | 7 | Order invalidated before it hit the market (e.g. insufficient capital) (7) |
| CancelPending | 8 | Order waiting for confirmation of cancellation (6) |
| UpdateSubmitted | 9 | Order update submitted to the market (9) |


See: Description
| Interface | Description |
|---|---|
| AppletInitializer |
This interface is designed to work in collusion with java.beans.Beans.instantiate.
|
| BeanInfo |
Use the
BeanInfo interface
to create a BeanInfo class
and provide explicit information about the methods,
properties, events, and other features of your beans. |
| Customizer |
A customizer class provides a complete custom GUI for customizing
a target Java Bean.
|
| DesignMode |
This interface is intended to be implemented by, or delegated from, instances
of java.beans.beancontext.BeanContext, in order to propagate to its nested hierarchy
of java.beans.beancontext.BeanContextChild instances, the current "designTime" property.
|
| ExceptionListener |
An ExceptionListener is notified of internal exceptions.
|
| PropertyChangeListener |
A "PropertyChange" event gets fired whenever a bean changes a "bound"
property.
|
| PropertyEditor |
A PropertyEditor class provides support for GUIs that want to
allow users to edit a property value of a given type.
|
| VetoableChangeListener |
A VetoableChange event gets fired whenever a bean changes a "constrained"
property.
|
| Visibility |
Under some circumstances a bean may be run on servers where a GUI
is not available.
|
| Class | Description |
|---|---|
| BeanDescriptor |
A BeanDescriptor provides global information about a "bean",
including its Java class, its displayName, etc.
|
| Beans |
This class provides some general purpose beans control methods.
|
| DefaultPersistenceDelegate |
The
DefaultPersistenceDelegate is a concrete implementation of
the abstract PersistenceDelegate class and
is the delegate used by default for classes about
which no information is available. |
| Encoder |
An
Encoder is a class which can be used to create
files or streams that encode the state of a collection of
JavaBeans in terms of their public APIs. |
| EventHandler |
The
EventHandler class provides
support for dynamically generating event listeners whose methods
execute a simple statement involving an incoming event object
and a target object. |
| EventSetDescriptor |
An EventSetDescriptor describes a group of events that a given Java
bean fires.
|
| Expression |
An
Expression object represents a primitive expression
in which a single method is applied to a target and a set of
arguments to return a result - as in "a.getFoo()" . |
| FeatureDescriptor |
The FeatureDescriptor class is the common baseclass for PropertyDescriptor,
EventSetDescriptor, and MethodDescriptor, etc.
|
| IndexedPropertyChangeEvent |
An "IndexedPropertyChange" event gets delivered whenever a component that
conforms to the JavaBeans™ specification (a "bean") changes a bound
indexed property.
|
| IndexedPropertyDescriptor |
An IndexedPropertyDescriptor describes a property that acts like an
array and has an indexed read and/or indexed write method to access
specific elements of the array.
|
| Introspector |
The Introspector class provides a standard way for tools to learn about
the properties, events, and methods supported by a target Java Bean.
|
| MethodDescriptor |
A MethodDescriptor describes a particular method that a Java Bean
supports for external access from other components.
|
| ParameterDescriptor |
The ParameterDescriptor class allows bean implementors to provide
additional information on each of their parameters, beyond the
low level type information provided by the java.lang.reflect.Method
class.
|
| PersistenceDelegate |
The PersistenceDelegate class takes the responsibility
for expressing the state of an instance of a given class
in terms of the methods in the class's public API.
|
| PropertyChangeEvent |
A "PropertyChange" event gets delivered whenever a bean changes a "bound"
or "constrained" property.
|
| PropertyChangeListenerProxy |
A class which extends the
EventListenerProxy
specifically for adding a PropertyChangeListener
with a "bound" property. |
| PropertyChangeSupport |
This is a utility class that can be used by beans that support bound
properties.
|
| PropertyDescriptor |
A PropertyDescriptor describes one property that a Java Bean
exports via a pair of accessor methods.
|
| PropertyEditorManager |
The PropertyEditorManager can be used to locate a property editor for
any given type name.
|
| PropertyEditorSupport |
This is a support class to help build property editors.
|
| SimpleBeanInfo |
This is a support class to make it easier for people to provide
BeanInfo classes.
|
| Statement |
A
Statement object represents a primitive statement
in which a single method is applied to a target and
a set of arguments - as in "a.setFoo(b)" . |
| VetoableChangeListenerProxy |
A class which extends the
EventListenerProxy
specifically for adding a VetoableChangeListener
with a "constrained" property. |
| VetoableChangeSupport |
This is a utility class that can be used by beans that support constrained
properties.
|
| XMLDecoder |
The
XMLDecoder class is used to read XML documents
created using the XMLEncoder and is used just like
the ObjectInputStream . |
| XMLEncoder |
The
XMLEncoder class is a complementary alternative to
the ObjectOutputStream and can used to generate
a textual representation of a JavaBean in the same
way that the ObjectOutputStream can
be used to create binary representation of Serializable
objects. |
| Exception | Description |
|---|---|
| IntrospectionException |
Thrown when an exception happens during Introspection.
|
| PropertyVetoException |
A PropertyVetoException is thrown when a proposed change to a
property represents an unacceptable value.
|
| Annotation Type | Description |
|---|---|
| ConstructorProperties |
An annotation on a constructor that shows how the parameters of
that constructor correspond to the constructed object's getter
methods.
|
| Transient |
Indicates that an attribute called "transient"
should be declared with the given
value
when the Introspector constructs
a PropertyDescriptor or EventSetDescriptor
classes associated with the annotated code element. |
PropertyChangeEvent
). However, most of the classes in this
package are meant to be used by a bean editor (that is, a development environment
for customizing and putting together beans to create an application). In
particular, these classes help the bean editor create a user
interface that the user can use to customize the bean. For example, a bean may
contain a property of a special type that a bean editor may not know how to handle.
By using the PropertyEditor
interface, a bean developer can
provide an editor for this special type.
To minimize the resources used by a bean, the classes used by bean editors are loaded only
when the bean is being edited. They are not needed while the bean is running in an application
and therefore not loaded. This information is kept in what's called a bean-info (see BeanInfo
).
Unless explicitly stated, null values or empty Strings are not valid parameters for the methods in this package. You may expect to see exceptions if these parameters are used.
java.beans
package provides support for
long-term persistence -- reading and
writing a bean as a textual representation of its property values.
The property values are treated as beans,
and are recursively read or written to capture
their publicly available state.
This approach is suitable for long-term storage
because it relies only on public API,
rather than the likely-to-change private implementation.
Note: The persistence scheme cannot automatically instantiate custom inner classes, such as you might use for event handlers. By using theEventHandler
class instead of inner classes for custom event handlers, you can avoid this problem.
You read and write beans in XML format using the
XMLDecoder
and
XMLEncoder
classes, respectively.
One notable feature of the persistence scheme is that
reading in a bean requires no special knowledge of the bean.
Writing out a bean, on the other hand,
sometimes requires special knowledge of the bean's type.
If the bean's state can be
expressed using only the no-argument constructor and
public getter and setter methods for properties,
no special knowledge is required.
Otherwise, the bean requires a custom persistence delegate --
an object that is in charge of writing out beans of a particular type.
All classes provided in the JDK that descend
from java.awt.Component
,
as well as all their properties,
automatically have persistence delegates.
If you need (or choose) to provide a persistence delegate for a bean,
you can do so either by using a
DefaultPersistenceDelegate
instance
or by creating your own subclass of PersistenceDelegate
.
If the only reason a bean needs a persistence delegate
is because you want to invoke the bean's constructor with
property values as arguments,
you can create the bean's persistence delegate
with the one-argument
DefaultPersistenceDelegate
constructor.
Otherwise,
you need to implement your own persistence delegate,
for which you're likely to need the following classes:
PersistenceDelegate
Statement
s and Expression
s
are necessary to create the bean
and restore its state.
Statement
Expression
Statement
used for methods that return a value.
Once you create a persistence delegate,
you register it using the
setPersistenceDelegate
method of
XMLEncoder
.
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2015, Oracle and/or its affiliates. All rights reserved.


Touch slider jquery Plugin
<script>
$('#pbSlider').pbTouchSlider({
slider_Wrap: '#pbSliderWrap',
slider_Threshold: 50,
slider_Speed:400,
slider_Ease:'linear',
slider_Drag : false,
slider_Arrows: {
enabled : false
},
slider_Breakpoints: {
default: {
height: 300
},
tablet: {
height: 250,
media: 1024
},
smartphone: {
height: 200,
media: 768
}
}
});
</script>
This is a title
This is a sub title
This is a title
This is a sub title
This is a title
This is a sub title
This is a title
This is a sub title
This is a title
This is a sub title
This is a title
This is a sub title
<script>
$('#pbSlider2').pbTouchSlider({
slider_Wrap: '#pbSliderWrap2',
slider_Threshold: 25,
slider_Speed:1000 ,
slider_Ease:'cubic-bezier(.16,.92,0,.8)',
slider_Dots: {
class:'.slider-pagination',
enabled : false
},
slider_Breakpoints: {
default: {
height: 300
},
tablet: {
height: 250,
media: 1024
},
smartphone: {
height: 200,
media: 768
}
}
});
</script>
This is a title
This is a sub title
This is a title
This is a sub title
This is a title
This is a sub title
This is a title
This is a sub title
This is a title
This is a sub title
This is a title
This is a sub title
<script>
$('#pbSlider3').pbTouchSlider({
slider_Wrap: '#pbSliderWrap3',
slider_Threshold: 50 ,
slider_Speed:400 ,
slider_Ease:'linear',
slider_Breakpoints: {
default: {
height: 400
},
tablet: {
height: 300,
media: 1024
},
smartphone: {
height: 200,
media: 768
}
}
});
</script>


Morris White is the sous-chef at a first-rate Philadelphia restaurant, Le Tour de Cochon. All he wants is to leave behind his past and open his own spot. His dream comes one step closer to reality when the affair he's having with Vicky Ward heats up. Not only is she the manager of the restaurant he's working at, she also comes from money and a privileged background. She wants to make his dream come true, and the only thing that could stop them from doing it together is the one thing Morris hasn't told her about: his half-brother, Vince Kramer, is about to get out of Graterford Prison.


Overwatch’s Mercy’s Recall challenge is now live
by Aran SuddiBlizzard has updated Overwatch with a new challenge for players to tackle and that is Mercy’s Recall challenge in which players can get a new player icon, new sprays and a Dr Ziegler skin. There are two ways to earning rewards and they include either playing Overwatch or watching streamers on Twitch play Overwatch.
The reward distribution for both playing and watching is as follows:
- Win 3 Games | 1 Player Icon
- Win 6 Games | 2 New Sprays
- Win 9 Games | New legendary skin: Dr. Ziegler skin
- Watch 2 Hours | 1 New Spray
- Watch 4 Hours | 2 New Sprays
- Watch 6 Hours | 3 New Sprays
The Mercy Recall challenge is live until December 2nd. A couple of weeks ago Overwatch 2 was announced at BlizzCon with confirmation that this sequel would feature story missions and PvE events. In terms of multiplayer, the PvP will be compatible with the first Overwatch title. All of the maps and heroes that are added to Overwatch 2 will also be accessible to those who have Overwatch, so the sequel’s real new additions are the story content.
To sum it up Jeff from the Overwatch team said:
The other thing that I think a lot of us are thinking about is all of those cool accomplishments and cosmetics that we’ve been unlocked over the years. You know, how hard did you work for your Witch Mercy skin, for example? We want to make sure that all Overwatch cosmetics come forward with you to Overwatch 2, so all your progress matters. Nothing’s getting left behind, no one’s getting left behind.
A release date for Overwatch 2 is to be confirmed.
Source: Press Release


How to clear (delete) all logged event records from the Log Viewer module. This deletes all records from all sites. Restricted to SuperUsers.
Note: The next time you navigate to the Log Viewer it will contain a single event record explaining that "The log has been cleared" and will include the name of the SuperUser who cleared the log.


Chucky has had many movies of him killing people but we never get see what pushed him to become the way he is. Later in chucky movies he becomes conflicted, he finally gets the chance to turn back into a real human but refuses. He has now become addicted to killing and no longer cares about turning back into a human.
Charles Lee "Chucky" Ray is a fictional character and the main antagonist of the Child's Play slasher film franchise. Chucky is portrayed as a notorious serial killer whose spirit inhabits a "Good Guy" doll and continuously tries to transfer his soul from the doll to a human body. The character has become one of the most recognizable horror icons, often mentioned alongside Freddy Krueger, Jason Voorhees, Ghostface, Leatherface, Pennywise, Pinhead, Leprechaun, Jigsaw and Michael Myers, and has been referenced numerous times in popular culture. In 1999, the Chucky character was nominated for the MTV Movie Award for Best Villain for the film Bride of Chucky. He was created by writer-director Don Mancini and is portrayed by Brad Dourif in both live action and voice over.
Chucky has many fans all around the world. We grew up watching these movies as it was unique in its time, not many horror movies like it. So it later began to lose its touch by slowly transitionning to almost a comedy.


gdal_contour
Builds vector contour lines from a raster elevation model.
Synopsis
gdal_contour [-b <band>] [-a <attribute_name>] [-amin <attribute_name>] [-amax <attribute_name>]
[-3d] [-inodata]
[-snodata n] [-i <interval>]
[-f <formatname>] [[-dsco NAME=VALUE] ...] [[-lco NAME=VALUE] ...]
[-off <offset>] [-fl <level> <level>...] [-e <exp_base>]
[-nln <outlayername>] [-q] [-p]
<src_filename> <dst_filename>
Description
The gdal_contour generates a vector contour file from the input raster elevation model (DEM).
The contour line-strings are oriented consistently and the high side will be on the right, i.e. a line string goes clockwise around a top.
- -b <band>
Picks a particular band to get the DEM from. Defaults to band 1.
- -a <name>
Provides a name for the attribute in which to put the elevation. If not provided no elevation attribute is attached. Ignored in polygonal contouring (
-p
) mode.
- -amin <name>
Provides a name for the attribute in which to put the minimum elevation of contour polygon. If not provided no minimum elevation attribute is attached. Ignored in default line contouring mode.
New in version 2.4.0.
- -amax <name>
Provides a name for the attribute in which to put the maximum elevation of contour polygon. If not provided no maximum elevation attribute is attached. Ignored in default line contouring mode.
New in version 2.4.0.
- -3d
Force production of 3D vectors instead of 2D. Includes elevation at every vertex.
- -inodata
Ignore any nodata value implied in the dataset - treat all values as valid.
- -snodata <value>
Input pixel value to treat as "nodata".
- -f <format>
Create output in a particular format.
New in version 2.3.0: If not specified, the format is guessed from the extension (previously was ESRI Shapefile).
- -dsco <NAME=VALUE>
Dataset creation option (format specific)
- -lco <NAME=VALUE>
Layer creation option (format specific)
- -i <interval>
Elevation interval between contours.
- -off <offset>
Offset from zero relative to which to interpret intervals.
- -fl <level>
Name one or more "fixed levels" to extract.
- -e <base>
Generate levels on an exponential scale: base ^ k, for k an integer.
New in version 2.4.0.
- -nln <name>
Provide a name for the output vector layer. Defaults to "contour".
- -p
Generate contour polygons rather than contour lines.
New in version 2.4.0.
- -q
Be quiet.
C API
Functionality of this utility can be done from C with GDALContourGenerate()
.
Example
This would create 10-meter contours from the DEM data in dem.tif
and
produce a shapefile in contour.shp|shx|dbf
with the contour elevations
in the elev
attribute.
gdal_contour -a elev dem.tif contour.shp -i 10.0


Polanski film tops French box office despite rape claim
'An Officer and a Spy' surged in the charts despite campaign in wake of latest claims against the veteran filmmaker.
Roman Polanski's new film is topping the French box office despite a new rape allegation against the controversial director.
An Officer and a Spy surged ahead of the Matt Damon racing car epic Ford v Ferrari - which is top of the US box office - despite the publicity campaign for the movie being suspended in the wake of the latest claims against the veteran filmmaker.
More:
French photographer Valentine Monnier threw the release of the historical thriller about the Dreyfus Affair into disarray by accusing Polanski of raping her in 1975 when she was 18 after beating her "into submission" at his Swiss chalet.
But despite protests outside cinemas and a call by feminists to boycott the movie starring Oscar-winning actor Jean Dujardin, nearly 400,000 people had flocked to see it by late Monday.
Polanski, 86, denies attacking Monnier, a former model and actress, and has threatened to sue his accusers.
The unexpectedly strong turnout for the film is the seventh-best opening weekend by a French film in 2019, according to figures from CBO Box-Office.
Its success angered critics of the French-Polish maker of Rosemary's Baby and Chinatown, who has been a fugitive from US justice since admitting to the statutory rape of a 13-year-old girl in 1977 in a plea bargain to avoid a trial on more serious charges.
Melissa Silverstein, the US founder of Women and Hollywood, was scathing.
"WTF France?" she tweeted.
'Heads in the ground'
"In the column of how much more work needs to be done (on women in the film industry) - Roman Polanski's movie led the box office in France."
Silverstein had lacerated the organisers of the Venice film festival earlier this year for selecting the film, which went on to win the Silver Lion and the critics' prize despite the head of the jury, Argentine filmmaker Lucrecia Martel, admitting she was "uncomfortable" about Polanski.
Industry insiders said that An Officer and a Spy, based on the anti-Semitic persecution of the French Jewish army officer Alfred Dreyfus, might have done even better had it not been for the new rape claim.
They told the film industry bible Variety that the movie's success was clearly driven by word of mouth, and that its strong run in cinemas was set to continue.
As the box office figures were released on Monday, the French directors guild ARP passed a proposal that could see Polanski suspended from the organisation next year when its members meet to discuss a rule change on sexual abuse claims.
"We cannot put our heads in the ground and pretend that the world hasn't changed," Pierre Jolivet, the head of the ARP, told AFP.
Polanski has already been expelled from the US Academy of Motion Picture Arts and Sciences, although he has mounted a legal challenge to the decision.
Meanwhile, veteran French director Nadine Trintignant rowed back on her earlier support for the veteran after saying that she was "more inclined to believe him than a woman who has taken 44 years to think about denouncing him".

It came after her family - one of France's theatrical dynasties - said they "believed Monnier", and without naming Polanski, stressed that "even an immense artist is first of all a human being".


In this step, you will add a feature to let your users control the order of the items in the phone list. The dynamic ordering is implemented by creating a new model property, wiring it together with the repeater, and letting the data binding magic do the rest of the work.
app/index.html
:
Search: <input ng-model="query">
Sort by:
<select ng-model="orderProp">
<option value="name">Alphabetical</option>
<option value="age">Newest</option>
</select>

{{phone.name}}

{{phone.snippet}}

We made the following changes to the index.html
template:
<select>
html element named orderProp
, so that our users can pick from the
two provided sorting options.filter
filter with orderBy
filter to further process the input into the repeater. orderBy
is a filter that takes an input
array, copies it and reorders the copy which is then returned.Angular creates a two way data-binding between the select element and the orderProp
model.
orderProp
is then used as the input for the orderBy
filter.
As we discussed in the section about data-binding and the repeater in step 3, whenever the model changes (for example because a user changes the order with the select drop down menu), Angular's data-binding will cause the view to automatically update. No bloated DOM manipulation code is necessary!
app/js/controllers.js
:
var phonecatApp = angular.module('phonecatApp', []);
phonecatApp.controller('PhoneListCtrl', function ($scope) {
$scope.phones = [
{'name': 'Nexus S',
'snippet': 'Fast just got faster with Nexus S.',
'age': 1},
{'name': 'Motorola XOOM™ with Wi-Fi',
'snippet': 'The Next, Next Generation tablet.',
'age': 2},
{'name': 'MOTOROLA XOOM™',
'snippet': 'The Next, Next Generation tablet.',
'age': 3}
];
$scope.orderProp = 'age';
});
We modified the phones
model - the array of phones - and added an age
property to each phone
record. This property is used to order phones by age.
We added a line to the controller that sets the default value of orderProp
to age
. If we had
not set a default value here, the orderBy
filter would remain uninitialized until our
user picked an option from the drop down menu.
This is a good time to talk about two-way data-binding. Notice that when the app is loaded in the
browser, "Newest" is selected in the drop down menu. This is because we set orderProp
to 'age'
in the controller. So the binding works in the direction from our model to the UI. Now if you
select "Alphabetically" in the drop down menu, the model will be updated as well and the phones
will be reordered. That is the data-binding doing its job in the opposite direction — from the UI
to the model.
The changes we made should be verified with both a unit test and an end-to-end test. Let's look at the unit test first.
test/unit/controllersSpec.js
:
describe('PhoneCat controllers', function() {
describe('PhoneListCtrl', function(){
var scope, ctrl;
beforeEach(module('phonecatApp'));
beforeEach(inject(function($controller) {
scope = {};
ctrl = $controller('PhoneListCtrl', {$scope:scope});
}));
it('should create "phones" model with 3 phones', function() {
expect(scope.phones.length).toBe(3);
});
it('should set the default value of orderProp model', function() {
expect(scope.orderProp).toBe('age');
});
});
});
The unit test now verifies that the default ordering property is set.
We used Jasmine's API to extract the controller construction into a beforeEach
block, which is
shared by all tests in the parent describe
block.
You should now see the following output in the Karma tab:
Chrome 22.0: Executed 2 of 2 SUCCESS (0.021 secs / 0.001 secs)
Let's turn our attention to the end-to-end test.
test/e2e/scenarios.js
:
...
it('should be possible to control phone order via the drop down select box', function() {
var phoneNameColumn = element.all(by.repeater('phone in phones').column('phone.name'));
var query = element(by.model('query'));
function getNames() {
return phoneNameColumn.map(function(elm) {
return elm.getText();
});
}
query.sendKeys('tablet'); //let's narrow the dataset to make the test assertions shorter
expect(getNames()).toEqual([
"Motorola XOOM\u2122 with Wi-Fi",
"MOTOROLA XOOM\u2122"
]);
element(by.model('orderProp')).element(by.css('option[value="name"]')).click();
expect(getNames()).toEqual([
"MOTOROLA XOOM\u2122",
"Motorola XOOM\u2122 with Wi-Fi"
]);
});...
The end-to-end test verifies that the ordering mechanism of the select box is working correctly.
You can now rerun npm run protractor
to see the tests run.
In the PhoneListCtrl
controller, remove the statement that sets the orderProp
value and
you'll see that Angular will temporarily add a new blank ("unknown") option to the drop-down list and the
ordering will default to unordered/natural order.
Add an {{orderProp}}
binding into the index.html
template to display its current value as
text.
Reverse the sort order by adding a -
symbol before the sorting value: <option value="-age">Oldest</option>
Now that you have added list sorting and tested the app, go to step 5 to learn about Angular services and how Angular uses dependency injection.


BTS’ latest summer anthem “Butter” released on May 21 is a dance pop track that easily becomes listeners’ favorite earworm, with its distinctive baseline and crisp synth sounds.  Sweeter! Cooler? Butter!
Get it, let it roll
🎼 Spotify 🎬 official MV


Documentation for building and running the latest source on windows can be found in the "Windows Developers Guide" in the CVS
Documentation for building and running the latest source on Linux can be found in the "Linux Installation Guide " and "Linux User Guide in the CVS
Linux Installation Guide
Linux User Guide
Windows Installation Guide
Windows User Guide
Windows Developer's Guide