Sleep Diary - University of Texas at San...

Preview:

Citation preview

Sleep DiaryIt’s dangerous to go alone. Here take this with you!

Pre-requisite

• Preferred that you use the VDI machine since they already have MATLAB installed.

• Have a sleep diary prepared.

Download the Script

• Go to class website• Click on “Homework

Assignments”

Download the Script

• Click on“../resources/SleepDiarySpr2020.zip”

Download the Script

• Should automatically download a zip file.

• Open the zip file.

Extract the files

• Click and drag the “SleepDiarySummer2020”folder to your V drive.

(picture doesn’t show V drive)

Extract the files

• On your V drive, open the folder.• Then open another folder inside

that.

Update the sleep diary

• Open “CS1173SleepDiarySpreadsheet”

• Excel should open up.

Update the sleep diary

• Fill out the respective columns correctly.

Update the sleep diary

• Make sure your cells format are similar to the picture.

• (1=YES, 0=NO) and 24-Hour must be used!!!

• Do not put 0 in front of the 24hr clock

• 01:00 is bad, 1:00 is good• If you pulled an all nighter, then

0:00 bedtime, 0:01 waketime• Everything must be filled!• When done, click “File”

Save the sleep diary

• Click “Export”• Click “Change File Type”• Click “CSV (Comma delimited)”• Click “Save As”

Save the sleep diary

• Click “Save”

Save the sleep diary

• Click “OK”

Save the sleep diary

• Click “Yes”

Create the mat file

• Close Excel• Click open “testScript”

Create the mat file

• MATLAB should open

Create the mat file

• Start replacing • lastName = [your last name]• firstName = [your first name]• gender = [your gender]• Section = [your section #]

• Do not touch “diaryFile”!• Gender must be all lowercase!

Create the mat file

• Run the code!

Create the mat file

• The output should be all black text

• If you do have any red text, then you should read the error of the code, fix any mistake in the excel and repeat the save again, and try to run the code again.

• Make sure to run the code, when excel is closed.

Submit the zip

• Hold ctrl and left click both “.csv” and “.mat” file

• Release ctrl and right click on selected files

• Click on “Create zip file”

Submit the zip

• Now we can submit the zip file to Blackboard.

Submit the zip

• On BB, click on “Labs/HW Turn-in”

• This might have a different location, based on your section, but the words are the same.

Submit the zip

• Choose the “Sleep Diary Turnin”

Submit the zip

• Click on “Browse My Computer”• Select the zip file.• Click OK• Click “Submit”

DONE!Remember where (directory) you did this,

as it is your dataset for Labs 3 and 4.

Recommended