0% found this document useful (0 votes)
172 views4 pages

Week 1 Solutions

This document provides solutions to exercises from an online course on data analysis. It addresses questions about analyzing a dataset with stock market data, using formulas like FIND, LEFT, and TREND. It also covers using conditional formulas, extracting data from strings like addresses, and splitting combined data like state codes and postal codes. The goal is to practice using formulas to analyze and extract information from different types of real-world datasets.

Uploaded by

Rahul More
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
172 views4 pages

Week 1 Solutions

This document provides solutions to exercises from an online course on data analysis. It addresses questions about analyzing a dataset with stock market data, using formulas like FIND, LEFT, and TREND. It also covers using conditional formulas, extracting data from strings like addresses, and splitting combined data like state codes and postal codes. The goal is to practice using formulas to analyze and extract information from different types of real-world datasets.

Uploaded by

Rahul More
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

SolutionsforWeek1ofEX101x:DataanalysistotheMAX()

Section1.3:Strings
Questions
1.WHATISTHEDATAYOUHAVE?
Howmanycolumnsdoestheimporteddatahave?
Thedatayouimportedshouldhavehad5columns:Symbol,Name,LastTrade,Change,and
Volume
Whatisthenameofthesecondcolumn?
ThenameofthesecondcolumnisName
Note:Bothoftheseanswerscanbeverifiedbyusingthespreadsheetprovidedbyusforthose
havingtroublewithimporting.

2.THEFINDFUNCTION
WhatshouldbethefirstargumentoftheFINDfunctioninthiscolumn?
ThefirstargumentoftheFINDfunctionwas,whichfindsthespaceinthetextintheChange
column.

3.THELEFTFUNCTION
WhatisthefirstargumentfortheLEFTfunctioninrow8?
ThefirstargumentoftheLEFTfunctioninrow8wasD8,whichindicateswhichtexttobetaking
theleftsideof.

4.THETRENDFORMULA
Pleaseassembletherightformulaforthe2ndrowbydraggingthepiecesoftheformulatothe
correctplace.
Thisquestionwasdraganddrop,thesolutionwastheformulashownhere:

WefindthepositioninD2andthensubtractonesowegetthepositionofthelastletter
beforethespace.ThiswaywegrabonlythewordUporDownwithoutthespace.

Intheexercisesinthissection,youhadtocreateanewcolumninthestocksdatacalledTrend.
Theexpectedresultisshowbelow.

Section1.5:Conditionals
Questions
1.FINDTHEPROBLEM
SomethingiswrongwiththespreadsheetthatFeliennecurrentlyhas,doyouknowwhat?
Theproblemwiththespreadsheetwasthattheprofitcolumncalculationisbasedonwrong
information.Thecalculationwasmultiplyingthevalueofthesharestimesthetotalnumberof
sharesowned,ratherthanthenumberofsharesmeanttobesold.Pleaseseelecture1.5at
time2:45fortheexplanation.

Section1.7:Assignment

1.BYHAND!
Tomakesureyoufullyunderstandtheproblem,weaskyoutofirstanalyseonerowbyhand.
Forthiswehavechosenrow42.

Whatisthehousenumberandstreetofrow42?
Thehousenumberonrow42was423CarriageDrive

WhatistheStatecodeofrow42?
Thestatecodeonrow42wasRI

2.GETTINGPOSTAL
SinceweassumethatUSstatecodes+postalcodesarealwaysinthefollowingformat:"AB
12345"wecanquiteeasilyextractthemfromtheline.
Whichformulamatchestheentirestatecodeandpostalcodeofthe42ndrow?

Thestateandpostalcodetogetheraresimplyformedbythelast8charactersofthestring.

3.GETTINGPOSTAL
Nowthatwehavethecombinedresult,weneedtosplititintwotogetthestatecodeandthe
postalcode.Notethatinpractice,wewouldswap"RI02895"intheformulasbelowwiththe
formulafromthepreviousexercise.

Whichformulagetsthestateabbreviationfromthecombinedstring?

HereweuseLEFTtotakethefirsttwocharactersfromthestring

Whichformulagetsthepostalcodefromthecombinedstring?

HereweuseRIGHTtotakethelastfivecharactersfromthestring

4.HITTINGTHESTREET
Forthefinalexercisewewouldliketoextractthestreetwithhousenumberfromthestring.
Unfortunatelythestreetnamesarenotallequalinlength,sowewillrequiretheuseofmore
complexfunctions.

Whichformulawouldgetusthefullstreetwithhousenumberofrow18?

WhatwesayhereisthatwewanttofindthefirstcommaintheStringandthentakethetext
fromplace1totheplaceofthiscomma(butminus1,becausewedon'tactuallywantthe
commaitself).

Alternatively=LEFT(A18,FIND(",",A18,1)1)wouldalsowork,butthiswasnotoneofthe
options)

ExtractingtheCity
Thiswasnotoneoftheexercisesbutwethoughtwewouldshareoursolutionforextractingthe
cityasaswell.Toextractcity,wecanmakeuseofthelengthofthestreetnameandnumber
(usingtheLENfunction).RememberthatthestreetnameandnumberisincolumnB.

You might also like