Q: How to create a password-protected website?

Use "be.stat.ubc.ca"
$ssh  username@stat.ubc.ca

Here are the simplified instructions on how to make a password protected web folder for our site:

1) Create the private web folder in your web directory. This is the directory for which you want to curtail access to.

$mkdir -p  /nfs/fil-data/username/public_html/private
$mkdir -p  /nfs/fil-data/username/keys

2) Within this private web directory, create a file called


which contains the following text:

AuthType Basic
AuthName "Title of your protected folder"
AuthUserFile /nfs/fil-data/username/keys/.htpasswd
Require valid-user
ErrorDocument 403 https://www.stat.ubc.ca/~username/private/
Notes: www.ugrad.stat.ubc.ca 
DONOT use "SSLRequireSSL" and "ErrorDocument 403 https://www.ugrad.stat.ubc.ca/~myusername/private/"
3) To create a password file with an initial user and password, use this command:
	$/usr/local/bin/htpasswd -c /nfs/fil-data/username/keys/.htpasswd user1
	... enter password for users1

To add additional users, run this command:

$/usr/local/bin/htpasswd /nfs/fil-data/username/keys/.htpasswd user2
	... enter password for users2
Note: There is no "-c" for creating second users

To delete users
$/usr/local/bin/htpasswd  -D /nfs/fil-data/username/keys/.htpasswd users

4) Make sure your files and directories have the correct permissions:

	$chmod 0711 /nfs/fil-data/username/public_html/private
	$chmod 0644 /nfs/fil-data/username/public_html/private/.htaccess
	$chmod 0711 /nfs/fil-data/username/keys
	$chmod 0644 /nfs/fil-data/username/keys/.htpasswd


Test the setup by using a browser and going to your private web folder:


It is important to note that this will offer some protection of your web files against unauthorized access via a web browser, but it does not protect you from StatNet users reading your files since they can go directly to your web directory via regular filesystem commands like 'cd' and 'less' and access your files.

In this case, you ought to encrypt your files (for example, by using the zip utility to created an encrypted zip archive). This is for for highly confidential information that need to be desseminated.

Q: Help with PHP and XML?Help with PHP and XML?
Q: Is it possible to complete the statistics major in two more years if I plan to take Math/Stat 302 in term 1 of year 3?

Yes, if you have credit for Math 200 and Math 221 (or their equivalents), and can fit in the Science breadth requirements and the thematic concentation requirements.
For example, take STAT/MATH 302, Stat 300, Stat 344 in term 1 of year 3; STAT 305, Stat 306 in term 2 of year 3. Then you have the prerequisites for Stat 400 level courses.

Q: CPSC 100 and 210 may be difficult to register into. When should CPSC 110 and CPSC 210 (or Math 210) be taken?

Take them as soon as possible but not necessarily by the end of year 2 if there are registration issues.
Credit for CPSC 110 and one of CPSC 210 or Math 210 is required for promotion to year 4.

Q: What are the Statistics course requirements for Promotion to year 4?

STAT 305 and STAT 306 (or ECON 326 for the BA Combined Major in Econ/Stat) must be completed for promotion to year 4. Please also see the Faculty of Science general requirements for promotion. For example:

Q: What are the Statistics course requirements for Promotion to year 3?

For Major in Statistics and Combined Major with Statistics: an average of at least 60% on their first attempts in their best 3 of the 5 "named" courses in Year 2. These five "named" courses in Year 2 are: MATH 200, MATH 220, MATH 221, STAT 200, and STAT/MATH 302. STAT 200 (or equivalent) must be completed for promotion to year 3.

Q: I am a Statistics major. How can I apply to the Statistics co-op program and what are the qualifications?

If you are in year 3, there is a deadline in early October. If you are in year 2, there is a deadline in early March.
Please see web site https://sciencecoop.ubc.ca/prospective/apply/statistics for instructions, qualifications and possible schedules for co-op terms.

Q: I am a Statistics major and would like to change to a combined CPSC/Stat Major program. What is the procedure?

You would have to apply to the CPSC Department. For the form, please see https://www.cs.ubc.ca/students/undergrad/prospective/switching/computer-.... It opens in April, and is closed for parts of the year.

Q: I am a Statistics major and would like to change to a combined Econ/Stat Major program. What is the procedure?

Please see the Department of Economics find web link for more information. The deadline to apply is around May 20th.

Q: I have previously applied for admission to the Statistics major but I was not successful. Can I apply again?

If you have continued to take Stat / Math courses at the 300 level and above, and your grades have improved, then you can apply again at: