Toggle navigation
Home
▼ Details
Products and pricing
Chart gallery
User stories
Text analytics
CDC NAMCS Library
Blog
Tutorials
Contact
Sign in
Post Editor
← All blog posts
View post
Save
<p><script src="/javascripts/lodash.js"></script></p> <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/KaTeX/0.3.0/katex.min.css"> <style> .blog .post .img { display: block; margin: 20px auto!important;} .bar { fill: #39c; } .bar:hover { fill: #eee; } .figure { margin-bottom: 40px; } .chart-title { font-weight: bold; color: #444; font-size: 18px; margin-top: 20px; } .axis path, .axis line { fill: none; stroke: black; shape-rendering: crispEdges; } .hover { stroke: #fc0; stroke-width: 4px; } .line-random { stroke: #aaa; } .line-theory { stroke: #9b6; stroke-width: 4px; } .dot-actual { fill: #39C; stroke: #26a; r: 5px; stroke-width: 1px; } .line-actual { fill: none; stroke: #39c; stroke-width: 4px; } .line-estimate { fill: none; stroke: #ccc; stroke-width: 4px; } .axis text { font-family: sans-serif; font-size: 14px; } .tw-bs .label { font-family: sans-serif; font-size: 14px; font-weight: normal; } </style> <p>Coding verbatims into concepts is a common task in text analytics. But how many concepts should you expect to find given your sample size? How big should your sample be to identify 20 concepts?</p> <p>That may sound abstract, but when budgeting research that's the bet we make with actual dollars. It'd be good to know the odds.</p> <svg style="height: 400px; width: 600px;"><g class="axis" transform="translate(0, 350)"><g class="tick" transform="translate(60,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">0</text></g><g class="tick" transform="translate(185,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">50</text></g><g class="tick" transform="translate(310,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">100</text></g><g class="tick" transform="translate(435,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">150</text></g><g class="tick" transform="translate(560,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">200</text></g><path class="domain" d="M60,6V0H560V6"></path></g><g class="axis" transform="translate(60, 0)"><g class="tick" transform="translate(0,350)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">0</text></g><g class="tick" transform="translate(0,267.5)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">5</text></g><g class="tick" transform="translate(0,185)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">10</text></g><g class="tick" transform="translate(0,102.5)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">15</text></g><g class="tick" transform="translate(0,20)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">20</text></g><path class="domain" d="M-6,20H0V350H-6"></path></g><defs><linearGradient id="gradient" x1="0%" y1="100%" x2="100%" y2="100%"><stop offset="0%" stop-color="#36f" stop-opacity="0.2"></stop><stop offset="50%" stop-color="#36f" stop-opacity="1"></stop><stop offset="100%" stop-color="#fff" stop-opacity="0.1"></stop></linearGradient></defs><text class="x label" text-anchor="end" x="300" y="394">Respondent #</text><text class="y label" transform="rotate(-90)" x="-200" dy="1em" style="text-anchor: middle;">Cumulative # Unique Codes</text><path d="M62.5,350L65,322.01105L67.5,311.5080338407917L70,303.6212278154287L72.5,297.0636998243365L75,291.34525955869015L77.5,286.2173239998589L80,281.5334924414347L82.5,277.19904551777284L85,273.14858151704993L87.5,269.334727306882L90,265.7218830136717L92.5,262.28250412605047L95,258.9947671189288L97.5,255.84103755291014L100,252.80682753469958L102.5,249.88006422934936L105,247.05056311283403L107.5,244.30964007106843L110,241.64982012080827L112.5,239.06461490242373L115,236.54835010488316L117.5,234.09602979034412L120,231.70322842158092L122.5,229.36600398548143L125,227.08082738947235L127.5,224.84452455811797L130,222.65422854798433L132.5,220.50733964298237L135,218.4014918644631L137.5,216.33452468061714L140,214.30445896264408L142.5,212.30947643459317L145,210.34790201656114L147.5,208.41818857905196L150,206.51890371840935L152.5,204.64871823562584L155,202.80639605816629L157.5,200.9907853901636L160,199.2008109130546L162.5,197.43546688837392L165,195.69381103852442L167.5,193.9749591010315L170,192.2780799679667L172.5,190.60239133558198L175,188.9471558002741L177.5,187.3116773462348L180,185.69529817786736L182.5,184.0973958565463L185,182.517380706776L187.5,180.9546934614441L190,179.40880311981076L192.5,177.87920499523744L195,176.36541893253812L197.5,174.86698767730616L200,173.38347538169762L202.50000000000003,171.9144662329892L205,170.45956319281876L207.5,169.0183868363985L210,167.59057428219342L212.5,166.17577820360617L215,164.77366591512907L217.5,163.38391852622678L220,162.0062301569238L222.5,160.64030720969126L225,159.28586769277916L227.5,157.94264059062698L230,156.61036527741481L232.50000000000003,155.28879097020277L235.00000000000003,153.9776762184445L237.5,152.67678842696506L240,151.38590340976518L242.5,150.10480497225367L245,148.83328451973L247.5,147.57114069013045L250,146.31817900922826L252.5,145.07421156663506L255,143.8390567110913L257.5,142.61253876366365L260,141.39448774758108L262.5,140.18473913354643L265,138.9831335994555L267.5,137.78951680354137L270,136.60373917003963L272.5,135.42565568654098L275,134.25512571226395L277.5,133.09201279653638L280,131.93618450683147L282.5,130.78751226575113L285,129.64587119639484L287.5,128.51113997559406L290,127.38320069452911L292.5,126.26193872627977L295,125.14724259989472L297.5,124.03900388059071L300,122.93711705572295L302.5,121.84147942618964L305,120.75199100295845L307.5,119.66855440842383L310,118.59107478232156L312.5,117.51945969194674L315,116.45361904643804L317.5,115.39346501490462L320,114.33891194818807L322.5,113.28987630406465L325,112.24627657570454L327.5,111.20803322321657L330,110.17506860811844L332.5,109.14730693058004L335,108.12467416929897L337.5,107.10709802387456L340,106.09450785955445L342.50000000000006,105.08683465423584L345.00000000000006,104.08401094761058L347.50000000000006,103.08597079234855L350,102.09264970722052L352.5,101.10398463206815L355,100.11991388453183L357.5,99.1403771184545L360,98.16531528388191L362.5,97.19467058858612L365,96.22838646104103L367.5,95.26640751478482L370,94.30867951410511L372.5,93.35514934098853L375,92.40576496327799L377.5,91.46047540398325L380,90.5192307116962L382.5,89.58198193206084L385,88.64868108025325L387.5,87.71928111442844L390,86.79373591009244L392.5,85.87200023536093L395,84.95402972706762L397.5,84.03978086768507L400,83.12921096302841L402.5,82.22227812070514L405.00000000000006,81.31894122928423L407.50000000000006,80.41915993815388L410.00000000000006,79.5228946380409L412.5,78.63010644216524L415,77.74075716800354L417.5,76.85480931964048L420,75.97222607068238L422.5,75.09297124771189L425,74.21700931426449L427.5,73.34430535530498L430,72.4748250621862L432.5,71.60853471807138L435,70.74540118380276L437.5,69.88539188420043L440,69.02847479477492L442.5,68.17461842883841L445,67.32379182500057L447.5,66.47596453503485L450,65.63110661210158L452.5,64.78918859931571L455,63.95018151864673L457.5,63.1140568601387L460,62.2807865714401L462.5,61.45034304763158L465,60.62269912134229L467.50000000000006,59.7978280531446L470.00000000000006,58.975703522216634L472.50000000000006,58.15629961726586L475.00000000000006,57.339590827702466L477.5,56.52555203505585L480,55.71415850462506L482.5,54.90538587735608L485,54.09921016193863L487.5,53.295607727114316L490,52.494555294190036L492.5,51.69602992975058L495,50.90000903856213L497.5,50.106470356662726L500,49.31539194463221L502.5,48.52675218103661L505,47.740529756041724L507.5,46.95670366518931L510,46.175253203333284L512.5,45.396157958728054L515,44.61939780726675L517.5,43.84495290686317L520,43.072803691973945L522.5,42.30293086825657L525,41.535315407358326L527.5,40.76993854183428L530,40.00678176018749L532.5,39.24582680203076L535,38.48705565336451L537.5,37.73045054196797L540,36.97599393290028L542.5,36.22366852410897" stroke="blue" stroke-width="1" fill="none" class="line-estimate"></path><path d="M60,333.5L62.5,317L65,300.5L67.5,300.5L70,284L72.5,267.5L75,267.5L77.5,251L80,251L82.5,251L85,251L87.5,234.5L90,234.5L92.5,218L95,218L97.5,218L100,218L102.5,218L105,218L107.5,218L110,218L112.5,218L115,218L117.5,218L120,218L122.5,201.5L125,201.5L127.5,201.5L130,201.5L132.5,201.5L135,201.5L137.5,201.5L140,201.5L142.5,201.5L145,185L147.5,185L150,168.49999999999997L152.5,168.49999999999997L155,168.49999999999997L157.5,168.49999999999997L160,168.49999999999997L162.5,168.49999999999997L165,168.49999999999997L167.5,168.49999999999997L170,168.49999999999997L172.5,168.49999999999997L175,168.49999999999997L177.5,168.49999999999997L180,168.49999999999997L182.5,151.99999999999997L185,151.99999999999997L187.5,151.99999999999997L190,151.99999999999997L192.5,151.99999999999997L195,135.5L197.5,135.5L200,135.5L202.50000000000003,135.5L205,135.5L207.5,135.5L210,135.5L212.5,135.5L215,135.5L217.5,135.5L220,135.5L222.5,135.5L225,135.5L227.5,135.5L230,135.5L232.50000000000003,135.5L235.00000000000003,135.5L237.5,135.5L240,135.5L242.5,135.5L245,135.5L247.5,135.5L250,135.5L252.5,135.5L255,135.5L257.5,135.5L260,135.5L262.5,135.5L265,135.5L267.5,135.5L270,135.5L272.5,135.5L275,135.5L277.5,135.5L280,118.99999999999997L282.5,118.99999999999997L285,118.99999999999997L287.5,118.99999999999997L290,118.99999999999997L292.5,118.99999999999997L295,118.99999999999997L297.5,118.99999999999997L300,118.99999999999997L302.5,102.5L305,102.5L307.5,86L310,86L312.5,86L315,86L317.5,86L320,86L322.5,86L325,86L327.5,86L330,86L332.5,86L335,86L337.5,86L340,86L342.50000000000006,86L345.00000000000006,86L347.50000000000006,86L350,86L352.5,86L355,86L357.5,86L360,86L362.5,86L365,86L367.5,86L370,86L372.5,86L375,86L377.5,86L380,86L382.5,86L385,86L387.5,86L390,86L392.5,86L395,86L397.5,86L400,86L402.5,86L405.00000000000006,86L407.50000000000006,86L410.00000000000006,86L412.5,86L415,86L417.5,86L420,86L422.5,86L425,86L427.5,86L430,86L432.5,86L435,86L437.5,86L440,86L442.5,86L445,86L447.5,86L450,86L452.5,86L455,86L457.5,86L460,86L462.5,86L465,86L467.50000000000006,86L470.00000000000006,86L472.50000000000006,86L475.00000000000006,86L477.5,86L480,86L482.5,86L485,86L487.5,86L490,86L492.5,86L495,86L497.5,86L500,86L502.5,86L505,86L507.5,69.49999999999994L510,69.49999999999994L512.5,69.49999999999994L515,69.49999999999994L517.5,69.49999999999994L520,69.49999999999994L522.5,69.49999999999994L525,69.49999999999994L527.5,69.49999999999994L530,69.49999999999994L532.5,69.49999999999994L535,69.49999999999994L537.5,69.49999999999994L540,69.49999999999994" stroke="blue" stroke-width="1" fill="none" class="line-actual"></path><g><circle class="dot-actual" r="4" cx="60" cy="333.5"></circle></g><g><circle class="dot-actual" r="4" cx="62.5" cy="317"></circle></g><g><circle class="dot-actual" r="4" cx="65" cy="300.5"></circle></g><g><circle class="dot-actual" r="4" cx="67.5" cy="300.5"></circle></g><g><circle class="dot-actual" r="4" cx="70" cy="284"></circle></g><g><circle class="dot-actual" r="4" cx="72.5" cy="267.5"></circle></g><g><circle class="dot-actual" r="4" cx="75" cy="267.5"></circle></g><g><circle class="dot-actual" r="4" cx="77.5" cy="251"></circle></g><g><circle class="dot-actual" r="4" cx="80" cy="251"></circle></g><g><circle class="dot-actual" r="4" cx="82.5" cy="251"></circle></g><g><circle class="dot-actual" r="4" cx="85" cy="251"></circle></g><g><circle class="dot-actual" r="4" cx="87.5" cy="234.5"></circle></g><g><circle class="dot-actual" r="4" cx="90" cy="234.5"></circle></g><g><circle class="dot-actual" r="4" cx="92.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="95" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="97.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="100" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="102.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="105" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="107.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="110" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="112.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="115" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="117.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="120" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="122.5" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="125" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="127.5" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="130" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="132.5" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="135" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="137.5" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="140" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="142.5" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="145" cy="185"></circle></g><g><circle class="dot-actual" r="4" cx="147.5" cy="185"></circle></g><g><circle class="dot-actual" r="4" cx="150" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="152.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="155" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="157.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="160" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="162.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="165" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="167.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="170" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="172.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="175" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="177.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="180" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="182.5" cy="151.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="185" cy="151.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="187.5" cy="151.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="190" cy="151.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="192.5" cy="151.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="195" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="197.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="200" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="202.50000000000003" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="205" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="207.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="210" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="212.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="215" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="217.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="220" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="222.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="225" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="227.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="230" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="232.50000000000003" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="235.00000000000003" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="237.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="240" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="242.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="245" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="247.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="250" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="252.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="255" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="257.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="260" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="262.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="265" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="267.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="270" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="272.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="275" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="277.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="280" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="282.5" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="285" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="287.5" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="290" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="292.5" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="295" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="297.5" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="300" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="302.5" cy="102.5"></circle></g><g><circle class="dot-actual" r="4" cx="305" cy="102.5"></circle></g><g><circle class="dot-actual" r="4" cx="307.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="310" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="312.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="315" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="317.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="320" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="322.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="325" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="327.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="330" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="332.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="335" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="337.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="340" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="342.50000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="345.00000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="347.50000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="350" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="352.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="355" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="357.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="360" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="362.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="365" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="367.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="370" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="372.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="375" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="377.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="380" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="382.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="385" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="387.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="390" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="392.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="395" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="397.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="400" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="402.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="405.00000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="407.50000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="410.00000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="412.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="415" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="417.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="420" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="422.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="425" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="427.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="430" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="432.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="435" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="437.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="440" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="442.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="445" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="447.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="450" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="452.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="455" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="457.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="460" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="462.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="465" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="467.50000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="470.00000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="472.50000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="475.00000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="477.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="480" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="482.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="485" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="487.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="490" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="492.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="495" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="497.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="500" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="502.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="505" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="507.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="510" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="512.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="515" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="517.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="520" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="522.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="525" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="527.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="530" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="532.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="535" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="537.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="540" cy="69.49999999999994"></circle></g></svg> <p>This article suggests a new way to predict how many distinct codes you may expect to see in N survey responses. Such a curve might be used to inform sample size selection before fielding research, or during analysis to benchmark the results. <!--more--></p> <h2 id="background">Background</h2> <p>Text verbatims are awesome as they're one of the few ways your survey can tell you something you didn't already know. But how many respondents do you need to recruit to be confident you'll learn something new?</p> <p>The more responses you get, the more likely you are to see new ideas. But the more responses you get, the more likely it is that the next response is similar to something you've seen before.</p> <h2 id="case-study">Case study</h2> <p>A survey asked 200 patients why they liked a particular medical device.<br>The response returned a wide array of responses. Scanning the data suggests concepts that might be the basis for coding.</p> <p>Here a number of answers suggest the idea of "Easy" highlighted in yellow:</p> <p><img src="/images/tutorial/zipf/D2-easy.png" style="width:360px"></p> <p>Protobi provides a few tools for coding text verbatims, described in this tutorial <a href="http://help.protobi.com/adminaccess/reformat-tool-beta">Advanced recoding tool</a></p> <p><img src="/images/tutorial/zipf/D2-recode-dialog.png" style="width:600px"></p> <p>In this project, the client coded raw verbatim text responses from each respondent into categories. Some responses included compound answers that were coded to more than one concept, e.g. "Affordable and easy to use". </p> <p>Below is a chart showing the count of responses behind each code. The most common codes were "Easy" (n=44), "Cost" (n=36) and "Portable" (n=18).</p> <svg style="height: 400px; width: 600px;"><g class="axis" transform="translate(0, 250)"><g class="tick" transform="translate(78,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Easy</text></g><g class="tick" transform="translate(107,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Cost</text></g><g class="tick" transform="translate(136,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Portable</text></g><g class="tick" transform="translate(165,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">No need to change</text></g><g class="tick" transform="translate(194,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Internet ready</text></g><g class="tick" transform="translate(223,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Appealing</text></g><g class="tick" transform="translate(252,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Familiar</text></g><g class="tick" transform="translate(281,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Wireless</text></g><g class="tick" transform="translate(310,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Keep existing monitor</text></g><g class="tick" transform="translate(339,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Seemed best</text></g><g class="tick" transform="translate(368,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">No landline</text></g><g class="tick" transform="translate(397,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Smart phone</text></g><g class="tick" transform="translate(426,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Already have it</text></g><g class="tick" transform="translate(455,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Paying is better</text></g><g class="tick" transform="translate(484,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Have equipment</text></g><g class="tick" transform="translate(513,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Unsure</text></g><g class="tick" transform="translate(542,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".15em" dx="-.8em" transform="rotate(-90)" style="text-anchor: end;">Reliable</text></g><path class="domain" d="M60,6V0H560V6"></path></g><g class="axis" transform="translate(60, 0)"><g class="tick" transform="translate(0,250)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">0</text></g><g class="tick" transform="translate(0,204)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">10</text></g><g class="tick" transform="translate(0,158)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">20</text></g><g class="tick" transform="translate(0,112)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">30</text></g><g class="tick" transform="translate(0,66)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">40</text></g><g class="tick" transform="translate(0,20)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">50</text></g><path class="domain" d="M-6,20H0V250H-6"></path></g><defs><linearGradient id="gradient" x1="0%" y1="100%" x2="100%" y2="100%"><stop offset="0%" stop-color="#36f" stop-opacity="0.2"></stop><stop offset="50%" stop-color="#36f" stop-opacity="1"></stop><stop offset="100%" stop-color="#fff" stop-opacity="0.1"></stop></linearGradient></defs><text class="x label" text-anchor="end" x="300" y="394">Coded value</text><text class="y label" transform="rotate(-90)" x="-200" dy="1em" style="text-anchor: middle;"># of responses</text><rect class="bar" x="65" y="43" height="207" width="26"></rect><rect class="bar" x="94" y="84.4" height="165.6" width="26"></rect><rect class="bar" x="123" y="171.8" height="78.19999999999999" width="26"></rect><rect class="bar" x="152" y="185.6" height="64.4" width="26"></rect><rect class="bar" x="181" y="194.8" height="55.19999999999999" width="26"></rect><rect class="bar" x="210" y="199.4" height="50.599999999999994" width="26"></rect><rect class="bar" x="239" y="208.6" height="41.400000000000006" width="26"></rect><rect class="bar" x="268" y="217.8" height="32.19999999999999" width="26"></rect><rect class="bar" x="297" y="222.4" height="27.599999999999994" width="26"></rect><rect class="bar" x="326" y="222.4" height="27.599999999999994" width="26"></rect><rect class="bar" x="355" y="222.4" height="27.599999999999994" width="26"></rect><rect class="bar" x="384" y="227" height="23" width="26"></rect><rect class="bar" x="413" y="227" height="23" width="26"></rect><rect class="bar" x="442" y="227" height="23" width="26"></rect><rect class="bar" x="471" y="231.6" height="18.400000000000006" width="26"></rect><rect class="bar" x="500" y="236.2" height="13.800000000000011" width="26"></rect><rect class="bar" x="529" y="240.8" height="9.199999999999989" width="26"></rect></svg> <h2 id="zipf-s-law">Zipf's Law</h2> <p>We can see here the distribution has a "long tail" with a few high-frequency codes and many low-frequency ones.</p> <p>According to <a href="https://en.wikipedia.org/wiki/Zipf%27s_law">Zipf's Law</a> we'd expect the frequency of each code to be inversely proportional to its rank:</p> <div class="katex" data-display="true"><span class="katex-display"><span class="katex"><span class="katex-mathml"><math><semantics><mrow><mi>z</mi><mo>(</mo><mi>r</mi><mo>)</mo><mo>=</mo><msub><mi>z</mi><mrow><mi>m</mi><mi>a</mi><mi>x</mi></mrow></msub><mo>⋅</mo><msup><mi>r</mi><mrow><mo>−</mo><mi>α</mi></mrow></msup></mrow><annotation encoding="application/x-tex"> z(r) = z_{max} \cdot r ^ {-\alpha}</annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="strut" style="height: 0.821331em;"></span><span class="strut bottom" style="height: 1.07133em; vertical-align: -0.25em;"></span><span class="base displaystyle textstyle uncramped"><span class="mord mathit" style="margin-right: 0.04398em;">z</span><span class="mopen">(</span><span class="mord mathit" style="margin-right: 0.02778em;">r</span><span class="mclose">)</span><span class="mrel">=</span><span class="mord"><span class="mord mathit" style="margin-right: 0.04398em;">z</span><span class="vlist"><span class="" style="top: 0.15em; margin-right: 0.05em; margin-left: -0.04398em;"><span class="fontsize-ensurer reset-size5 size5"><span class="" style="font-size: 0em;"></span></span><span class="reset-textstyle scriptstyle cramped"><span class="mord scriptstyle cramped"><span class="mord mathit">m</span><span class="mord mathit">a</span><span class="mord mathit">x</span></span></span></span><span class="baseline-fix"><span class="fontsize-ensurer reset-size5 size5"><span class="" style="font-size: 0em;"></span></span></span></span></span><span class="mbin">⋅</span><span class="mord"><span class="mord mathit" style="margin-right: 0.02778em;">r</span><span class="vlist"><span class="" style="top: -0.413em; margin-right: 0.05em;"><span class="fontsize-ensurer reset-size5 size5"><span class="" style="font-size: 0em;"></span></span><span class="reset-textstyle scriptstyle uncramped"><span class="mord scriptstyle uncramped"><span class="mord">−</span><span class="mord mathit" style="margin-right: 0.0037em;">α</span></span></span></span><span class="baseline-fix"><span class="fontsize-ensurer reset-size5 size5"><span class="" style="font-size: 0em;"></span></span></span></span></span></span></span></span></span></div> <p>Zipf's law can be derived from the power-law probability distribution, which describes many long-tail phenomena.</p> <svg style="height: 460px; width: 600px;"><g class="axis" transform="translate(0, 410)"><g class="tick" transform="translate(60,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">1</text></g><g class="tick" transform="translate(175.6891065798796,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">2</text></g><g class="tick" transform="translate(243.3628956710423,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">3</text></g><g class="tick" transform="translate(291.3782131597592,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">4</text></g><g class="tick" transform="translate(328.6217868402409,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">5</text></g><g class="tick" transform="translate(359.05200225092193,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">6</text></g><g class="tick" transform="translate(384.7803827854717,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">7</text></g><g class="tick" transform="translate(407.0673197396388,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">8</text></g><g class="tick" transform="translate(426.72579134208473,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">9</text></g><g class="tick" transform="translate(444.31089342012046,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">10</text></g><g class="tick" transform="translate(560,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">20</text></g><path class="domain" d="M60,6V0H560V6"></path></g><g class="axis" transform="translate(60, 0)"><g class="tick" transform="translate(0,410)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">1</text></g><g class="tick" transform="translate(0,340.8983101471324)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">2</text></g><g class="tick" transform="translate(0,300.47641284674125)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">3</text></g><g class="tick" transform="translate(0,271.7966202942648)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">4</text></g><g class="tick" transform="translate(0,249.5508449264338)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">5</text></g><g class="tick" transform="translate(0,231.3747229938737)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">6</text></g><g class="tick" transform="translate(0,216.0070308690542)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">7</text></g><g class="tick" transform="translate(0,202.69493044139728)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">8</text></g><g class="tick" transform="translate(0,190.95282569348248)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">9</text></g><g class="tick" transform="translate(0,180.4491550735662)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">10</text></g><g class="tick" transform="translate(0,111.34746522069867)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">20</text></g><g class="tick" transform="translate(0,70.9255679203074)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">30</text></g><g class="tick" transform="translate(0,42.245775367831016)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">40</text></g><g class="tick" transform="translate(0,20.000000000000057)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">50</text></g><path class="domain" d="M-6,20H0V410H-6"></path></g><defs><linearGradient id="gradient" x1="0%" y1="100%" x2="100%" y2="100%"><stop offset="0%" stop-color="#36f" stop-opacity="0.2"></stop><stop offset="50%" stop-color="#36f" stop-opacity="1"></stop><stop offset="100%" stop-color="#fff" stop-opacity="0.1"></stop></linearGradient></defs><text class="x label" text-anchor="end" x="300" y="454">Code response rank </text><text class="y label" transform="rotate(-90)" x="-230" dy="1em" style="text-anchor: middle;"># of responses</text><path d="M60,6.471552179404398L175.6891065798796,75.64234372212485L243.3628956710423,116.10466291981646L291.3782131597592,144.8131352648453L328.6217868402409,167.08115640804422L359.05200225092193,185.27545446253686L384.7803827854717,200.65851427948118L407.0673197396388,213.98392680756578L426.72579134208473,225.73777366022844L444.31089342012046,236.25194795076465L460.2185532343356,245.7631755284609L474.7411088308015,254.4462460052573L488.10056494444444,262.43389653934514L500.46948936535125,269.8293058222016L511.98468251128315,276.7142671484562L522.7564263195184,283.1547183502862L532.874924282708,289.2045923101475" stroke="blue" stroke-width="1" fill="none" class="line-estimate"></path><path d="M60,30.503670619916306L175.6891065798796,52.74944598774738L243.3628956710423,127.54941045879809L291.3782131597592,146.90534101618664L328.6217868402409,162.27303314100607L359.05200225092193,170.94742922172182L384.7803827854717,190.95282569348248L407.0673197396388,216.0070308690542L426.72579134208473,231.3747229938737L444.31089342012046,231.3747229938737L460.2185532343356,231.3747229938737L474.7411088308015,249.5508449264338L488.10056494444444,249.5508449264338L500.46948936535125,249.5508449264338L511.98468251128315,271.7966202942648L522.7564263195184,300.47641284674125L532.874924282708,340.8983101471324" stroke="blue" stroke-width="1" fill="none" class="line-actual"></path><g><circle class="dot-actual" r="4" cx="60" cy="30.503670619916306"></circle></g><g><circle class="dot-actual" r="4" cx="175.6891065798796" cy="52.74944598774738"></circle></g><g><circle class="dot-actual" r="4" cx="243.3628956710423" cy="127.54941045879809"></circle></g><g><circle class="dot-actual" r="4" cx="291.3782131597592" cy="146.90534101618664"></circle></g><g><circle class="dot-actual" r="4" cx="328.6217868402409" cy="162.27303314100607"></circle></g><g><circle class="dot-actual" r="4" cx="359.05200225092193" cy="170.94742922172182"></circle></g><g><circle class="dot-actual" r="4" cx="384.7803827854717" cy="190.95282569348248"></circle></g><g><circle class="dot-actual" r="4" cx="407.0673197396388" cy="216.0070308690542"></circle></g><g><circle class="dot-actual" r="4" cx="426.72579134208473" cy="231.3747229938737"></circle></g><g><circle class="dot-actual" r="4" cx="444.31089342012046" cy="231.3747229938737"></circle></g><g><circle class="dot-actual" r="4" cx="460.2185532343356" cy="231.3747229938737"></circle></g><g><circle class="dot-actual" r="4" cx="474.7411088308015" cy="249.5508449264338"></circle></g><g><circle class="dot-actual" r="4" cx="488.10056494444444" cy="249.5508449264338"></circle></g><g><circle class="dot-actual" r="4" cx="500.46948936535125" cy="249.5508449264338"></circle></g><g><circle class="dot-actual" r="4" cx="511.98468251128315" cy="271.7966202942648"></circle></g><g><circle class="dot-actual" r="4" cx="522.7564263195184" cy="300.47641284674125"></circle></g><g><circle class="dot-actual" r="4" cx="532.874924282708" cy="340.8983101471324"></circle></g><path d="M60,30.503670619916306L175.6891065798796,99.6053604727839L243.3628956710423,140.02725777317505L291.3782131597592,168.70705032565147L328.6217868402409,190.95282569348248L359.05200225092193,209.12894762604267L384.7803827854717,224.4966397508621L407.0673197396388,237.80874017851903L426.72579134208473,249.5508449264338L444.31089342012046,260.0545155463501L460.2185532343356,269.5562413981945L474.7411088308015,278.23063747891024L488.10056494444444,286.2103083421348L500.46948936535125,293.59832960372967L511.98468251128315,300.47641284674125L522.7564263195184,306.9104300313866L532.874924282708,312.95426016111816" stroke="blue" stroke-width="1" fill="none" class="line-theory"></path></svg> <p>In the graph above, the actual frequencies are plotted as dots. The two lines show a slope of -1 (α=1) for reference.</p> <h2 id="heap-s-law">Heap's Law</h2> <p>If the frequency of codes follows Zipf's Law, then the cumulative number of distinct codes we'd expect to encounter at any given sample size is described by Heap's Law:</p> <div class="katex" data-display="true"><span class="katex-display"><span class="katex"><span class="katex-mathml"><math><semantics><mrow><mi>N</mi><mo>(</mo><mi>t</mi><mo>)</mo><mo>≈</mo><mi>k</mi><mo>⋅</mo><msup><mi>t</mi><mi>β</mi></msup></mrow><annotation encoding="application/x-tex">N(t) \approx k \cdot t ^ \beta </annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="strut" style="height: 0.899108em;"></span><span class="strut bottom" style="height: 1.14911em; vertical-align: -0.25em;"></span><span class="base displaystyle textstyle uncramped"><span class="mord mathit" style="margin-right: 0.10903em;">N</span><span class="mopen">(</span><span class="mord mathit">t</span><span class="mclose">)</span><span class="mrel">≈</span><span class="mord mathit" style="margin-right: 0.03148em;">k</span><span class="mbin">⋅</span><span class="mord"><span class="mord mathit">t</span><span class="vlist"><span class="" style="top: -0.413em; margin-right: 0.05em;"><span class="fontsize-ensurer reset-size5 size5"><span class="" style="font-size: 0em;"></span></span><span class="reset-textstyle scriptstyle uncramped"><span class="mord mathit" style="margin-right: 0.05278em;">β</span></span></span><span class="baseline-fix"><span class="fontsize-ensurer reset-size5 size5"><span class="" style="font-size: 0em;"></span></span></span></span></span></span></span></span></span></div> <p>where N(t) is the number of distinct codes we would expect to find in t responses, and k and β are estimated empirically.</p> <p>And in the special case where α=1 in the Zipf distribution, then there is an exact formula for Heap's Law based on the Lambert W function:</p> <div class="katex" data-display="true"><span class="katex-display"><span class="katex"><span class="katex-mathml"><math><semantics><mrow><mi>N</mi><mo>(</mo><mi>t</mi><mo>)</mo><mo>=</mo><mfrac><mrow><mi>t</mi></mrow><mrow><mi>W</mi><mo>(</mo><mi>t</mi><mo>)</mo></mrow></mfrac></mrow><annotation encoding="application/x-tex">N(t) = \frac {t} {W(t)}</annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="strut" style="height: 1.29208em;"></span><span class="strut bottom" style="height: 2.22808em; vertical-align: -0.936em;"></span><span class="base displaystyle textstyle uncramped"><span class="mord mathit" style="margin-right: 0.10903em;">N</span><span class="mopen">(</span><span class="mord mathit">t</span><span class="mclose">)</span><span class="mrel">=</span><span class="minner reset-textstyle displaystyle textstyle uncramped"><span class="mfrac"><span class="vlist"><span class="" style="top: 0.686em;"><span class="fontsize-ensurer reset-size5 size5"><span class="" style="font-size: 0em;"></span></span><span class="reset-textstyle textstyle cramped"><span class="mord textstyle cramped"><span class="mord mathit" style="margin-right: 0.13889em;">W</span><span class="mopen">(</span><span class="mord mathit">t</span><span class="mclose">)</span></span></span></span><span class="" style="top: -0.23em;"><span class="fontsize-ensurer reset-size5 size5"><span class="" style="font-size: 0em;"></span></span><span class="reset-textstyle textstyle uncramped frac-line"></span></span><span class="" style="top: -0.677em;"><span class="fontsize-ensurer reset-size5 size5"><span class="" style="font-size: 0em;"></span></span><span class="reset-textstyle textstyle uncramped"><span class="mord textstyle uncramped"><span class="mord mathit">t</span></span></span></span><span class="baseline-fix"><span class="fontsize-ensurer reset-size5 size5"><span class="" style="font-size: 0em;"></span></span></span></span></span></span></span></span></span></span></div> <svg style="height: 400px; width: 600px;"><g class="axis" transform="translate(0, 350)"><g class="tick" transform="translate(60,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">0</text></g><g class="tick" transform="translate(185,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">50</text></g><g class="tick" transform="translate(310,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">100</text></g><g class="tick" transform="translate(435,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">150</text></g><g class="tick" transform="translate(560,0)" style="opacity: 1;"><line y2="6" x2="0"></line><text y="9" x="0" dy=".71em" style="text-anchor: middle;">200</text></g><path class="domain" d="M60,6V0H560V6"></path></g><g class="axis" transform="translate(60, 0)"><g class="tick" transform="translate(0,350)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">0</text></g><g class="tick" transform="translate(0,267.5)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">5</text></g><g class="tick" transform="translate(0,185)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">10</text></g><g class="tick" transform="translate(0,102.5)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">15</text></g><g class="tick" transform="translate(0,20)" style="opacity: 1;"><line x2="-6" y2="0"></line><text x="-9" y="0" dy=".32em" style="text-anchor: end;">20</text></g><path class="domain" d="M-6,20H0V350H-6"></path></g><defs><linearGradient id="gradient" x1="0%" y1="100%" x2="100%" y2="100%"><stop offset="0%" stop-color="#36f" stop-opacity="0.2"></stop><stop offset="50%" stop-color="#36f" stop-opacity="1"></stop><stop offset="100%" stop-color="#fff" stop-opacity="0.1"></stop></linearGradient></defs><text class="x label" text-anchor="end" x="300" y="394">Respondent #</text><text class="y label" transform="rotate(-90)" x="-200" dy="1em" style="text-anchor: middle;">Cumulative # Unique Codes</text><path d="M62.5,350L65,322.01105L67.5,311.5080338407917L70,303.6212278154287L72.5,297.0636998243365L75,291.34525955869015L77.5,286.2173239998589L80,281.5334924414347L82.5,277.19904551777284L85,273.14858151704993L87.5,269.334727306882L90,265.7218830136717L92.5,262.28250412605047L95,258.9947671189288L97.5,255.84103755291014L100,252.80682753469958L102.5,249.88006422934936L105,247.05056311283403L107.5,244.30964007106843L110,241.64982012080827L112.5,239.06461490242373L115,236.54835010488316L117.5,234.09602979034412L120,231.70322842158092L122.5,229.36600398548143L125,227.08082738947235L127.5,224.84452455811797L130,222.65422854798433L132.5,220.50733964298237L135,218.4014918644631L137.5,216.33452468061714L140,214.30445896264408L142.5,212.30947643459317L145,210.34790201656114L147.5,208.41818857905196L150,206.51890371840935L152.5,204.64871823562584L155,202.80639605816629L157.5,200.9907853901636L160,199.2008109130546L162.5,197.43546688837392L165,195.69381103852442L167.5,193.9749591010315L170,192.2780799679667L172.5,190.60239133558198L175,188.9471558002741L177.5,187.3116773462348L180,185.69529817786736L182.5,184.0973958565463L185,182.517380706776L187.5,180.9546934614441L190,179.40880311981076L192.5,177.87920499523744L195,176.36541893253812L197.5,174.86698767730616L200,173.38347538169762L202.50000000000003,171.9144662329892L205,170.45956319281876L207.5,169.0183868363985L210,167.59057428219342L212.5,166.17577820360617L215,164.77366591512907L217.5,163.38391852622678L220,162.0062301569238L222.5,160.64030720969126L225,159.28586769277916L227.5,157.94264059062698L230,156.61036527741481L232.50000000000003,155.28879097020277L235.00000000000003,153.9776762184445L237.5,152.67678842696506L240,151.38590340976518L242.5,150.10480497225367L245,148.83328451973L247.5,147.57114069013045L250,146.31817900922826L252.5,145.07421156663506L255,143.8390567110913L257.5,142.61253876366365L260,141.39448774758108L262.5,140.18473913354643L265,138.9831335994555L267.5,137.78951680354137L270,136.60373917003963L272.5,135.42565568654098L275,134.25512571226395L277.5,133.09201279653638L280,131.93618450683147L282.5,130.78751226575113L285,129.64587119639484L287.5,128.51113997559406L290,127.38320069452911L292.5,126.26193872627977L295,125.14724259989472L297.5,124.03900388059071L300,122.93711705572295L302.5,121.84147942618964L305,120.75199100295845L307.5,119.66855440842383L310,118.59107478232156L312.5,117.51945969194674L315,116.45361904643804L317.5,115.39346501490462L320,114.33891194818807L322.5,113.28987630406465L325,112.24627657570454L327.5,111.20803322321657L330,110.17506860811844L332.5,109.14730693058004L335,108.12467416929897L337.5,107.10709802387456L340,106.09450785955445L342.50000000000006,105.08683465423584L345.00000000000006,104.08401094761058L347.50000000000006,103.08597079234855L350,102.09264970722052L352.5,101.10398463206815L355,100.11991388453183L357.5,99.1403771184545L360,98.16531528388191L362.5,97.19467058858612L365,96.22838646104103L367.5,95.26640751478482L370,94.30867951410511L372.5,93.35514934098853L375,92.40576496327799L377.5,91.46047540398325L380,90.5192307116962L382.5,89.58198193206084L385,88.64868108025325L387.5,87.71928111442844L390,86.79373591009244L392.5,85.87200023536093L395,84.95402972706762L397.5,84.03978086768507L400,83.12921096302841L402.5,82.22227812070514L405.00000000000006,81.31894122928423L407.50000000000006,80.41915993815388L410.00000000000006,79.5228946380409L412.5,78.63010644216524L415,77.74075716800354L417.5,76.85480931964048L420,75.97222607068238L422.5,75.09297124771189L425,74.21700931426449L427.5,73.34430535530498L430,72.4748250621862L432.5,71.60853471807138L435,70.74540118380276L437.5,69.88539188420043L440,69.02847479477492L442.5,68.17461842883841L445,67.32379182500057L447.5,66.47596453503485L450,65.63110661210158L452.5,64.78918859931571L455,63.95018151864673L457.5,63.1140568601387L460,62.2807865714401L462.5,61.45034304763158L465,60.62269912134229L467.50000000000006,59.7978280531446L470.00000000000006,58.975703522216634L472.50000000000006,58.15629961726586L475.00000000000006,57.339590827702466L477.5,56.52555203505585L480,55.71415850462506L482.5,54.90538587735608L485,54.09921016193863L487.5,53.295607727114316L490,52.494555294190036L492.5,51.69602992975058L495,50.90000903856213L497.5,50.106470356662726L500,49.31539194463221L502.5,48.52675218103661L505,47.740529756041724L507.5,46.95670366518931L510,46.175253203333284L512.5,45.396157958728054L515,44.61939780726675L517.5,43.84495290686317L520,43.072803691973945L522.5,42.30293086825657L525,41.535315407358326L527.5,40.76993854183428L530,40.00678176018749L532.5,39.24582680203076L535,38.48705565336451L537.5,37.73045054196797L540,36.97599393290028L542.5,36.22366852410897" stroke="blue" stroke-width="1" fill="none" class="line-estimate"></path><path d="M60,333.5L62.5,317L65,300.5L67.5,300.5L70,284L72.5,267.5L75,267.5L77.5,251L80,251L82.5,251L85,251L87.5,234.5L90,234.5L92.5,218L95,218L97.5,218L100,218L102.5,218L105,218L107.5,218L110,218L112.5,218L115,218L117.5,218L120,218L122.5,201.5L125,201.5L127.5,201.5L130,201.5L132.5,201.5L135,201.5L137.5,201.5L140,201.5L142.5,201.5L145,185L147.5,185L150,168.49999999999997L152.5,168.49999999999997L155,168.49999999999997L157.5,168.49999999999997L160,168.49999999999997L162.5,168.49999999999997L165,168.49999999999997L167.5,168.49999999999997L170,168.49999999999997L172.5,168.49999999999997L175,168.49999999999997L177.5,168.49999999999997L180,168.49999999999997L182.5,151.99999999999997L185,151.99999999999997L187.5,151.99999999999997L190,151.99999999999997L192.5,151.99999999999997L195,135.5L197.5,135.5L200,135.5L202.50000000000003,135.5L205,135.5L207.5,135.5L210,135.5L212.5,135.5L215,135.5L217.5,135.5L220,135.5L222.5,135.5L225,135.5L227.5,135.5L230,135.5L232.50000000000003,135.5L235.00000000000003,135.5L237.5,135.5L240,135.5L242.5,135.5L245,135.5L247.5,135.5L250,135.5L252.5,135.5L255,135.5L257.5,135.5L260,135.5L262.5,135.5L265,135.5L267.5,135.5L270,135.5L272.5,135.5L275,135.5L277.5,135.5L280,118.99999999999997L282.5,118.99999999999997L285,118.99999999999997L287.5,118.99999999999997L290,118.99999999999997L292.5,118.99999999999997L295,118.99999999999997L297.5,118.99999999999997L300,118.99999999999997L302.5,102.5L305,102.5L307.5,86L310,86L312.5,86L315,86L317.5,86L320,86L322.5,86L325,86L327.5,86L330,86L332.5,86L335,86L337.5,86L340,86L342.50000000000006,86L345.00000000000006,86L347.50000000000006,86L350,86L352.5,86L355,86L357.5,86L360,86L362.5,86L365,86L367.5,86L370,86L372.5,86L375,86L377.5,86L380,86L382.5,86L385,86L387.5,86L390,86L392.5,86L395,86L397.5,86L400,86L402.5,86L405.00000000000006,86L407.50000000000006,86L410.00000000000006,86L412.5,86L415,86L417.5,86L420,86L422.5,86L425,86L427.5,86L430,86L432.5,86L435,86L437.5,86L440,86L442.5,86L445,86L447.5,86L450,86L452.5,86L455,86L457.5,86L460,86L462.5,86L465,86L467.50000000000006,86L470.00000000000006,86L472.50000000000006,86L475.00000000000006,86L477.5,86L480,86L482.5,86L485,86L487.5,86L490,86L492.5,86L495,86L497.5,86L500,86L502.5,86L505,86L507.5,69.49999999999994L510,69.49999999999994L512.5,69.49999999999994L515,69.49999999999994L517.5,69.49999999999994L520,69.49999999999994L522.5,69.49999999999994L525,69.49999999999994L527.5,69.49999999999994L530,69.49999999999994L532.5,69.49999999999994L535,69.49999999999994L537.5,69.49999999999994L540,69.49999999999994" stroke="blue" stroke-width="1" fill="none" class="line-actual"></path><g><circle class="dot-actual" r="4" cx="60" cy="333.5"></circle></g><g><circle class="dot-actual" r="4" cx="62.5" cy="317"></circle></g><g><circle class="dot-actual" r="4" cx="65" cy="300.5"></circle></g><g><circle class="dot-actual" r="4" cx="67.5" cy="300.5"></circle></g><g><circle class="dot-actual" r="4" cx="70" cy="284"></circle></g><g><circle class="dot-actual" r="4" cx="72.5" cy="267.5"></circle></g><g><circle class="dot-actual" r="4" cx="75" cy="267.5"></circle></g><g><circle class="dot-actual" r="4" cx="77.5" cy="251"></circle></g><g><circle class="dot-actual" r="4" cx="80" cy="251"></circle></g><g><circle class="dot-actual" r="4" cx="82.5" cy="251"></circle></g><g><circle class="dot-actual" r="4" cx="85" cy="251"></circle></g><g><circle class="dot-actual" r="4" cx="87.5" cy="234.5"></circle></g><g><circle class="dot-actual" r="4" cx="90" cy="234.5"></circle></g><g><circle class="dot-actual" r="4" cx="92.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="95" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="97.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="100" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="102.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="105" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="107.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="110" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="112.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="115" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="117.5" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="120" cy="218"></circle></g><g><circle class="dot-actual" r="4" cx="122.5" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="125" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="127.5" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="130" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="132.5" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="135" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="137.5" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="140" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="142.5" cy="201.5"></circle></g><g><circle class="dot-actual" r="4" cx="145" cy="185"></circle></g><g><circle class="dot-actual" r="4" cx="147.5" cy="185"></circle></g><g><circle class="dot-actual" r="4" cx="150" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="152.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="155" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="157.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="160" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="162.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="165" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="167.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="170" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="172.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="175" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="177.5" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="180" cy="168.49999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="182.5" cy="151.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="185" cy="151.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="187.5" cy="151.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="190" cy="151.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="192.5" cy="151.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="195" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="197.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="200" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="202.50000000000003" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="205" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="207.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="210" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="212.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="215" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="217.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="220" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="222.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="225" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="227.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="230" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="232.50000000000003" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="235.00000000000003" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="237.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="240" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="242.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="245" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="247.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="250" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="252.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="255" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="257.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="260" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="262.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="265" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="267.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="270" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="272.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="275" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="277.5" cy="135.5"></circle></g><g><circle class="dot-actual" r="4" cx="280" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="282.5" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="285" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="287.5" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="290" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="292.5" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="295" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="297.5" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="300" cy="118.99999999999997"></circle></g><g><circle class="dot-actual" r="4" cx="302.5" cy="102.5"></circle></g><g><circle class="dot-actual" r="4" cx="305" cy="102.5"></circle></g><g><circle class="dot-actual" r="4" cx="307.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="310" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="312.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="315" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="317.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="320" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="322.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="325" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="327.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="330" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="332.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="335" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="337.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="340" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="342.50000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="345.00000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="347.50000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="350" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="352.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="355" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="357.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="360" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="362.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="365" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="367.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="370" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="372.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="375" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="377.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="380" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="382.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="385" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="387.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="390" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="392.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="395" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="397.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="400" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="402.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="405.00000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="407.50000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="410.00000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="412.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="415" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="417.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="420" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="422.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="425" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="427.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="430" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="432.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="435" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="437.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="440" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="442.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="445" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="447.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="450" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="452.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="455" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="457.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="460" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="462.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="465" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="467.50000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="470.00000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="472.50000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="475.00000000000006" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="477.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="480" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="482.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="485" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="487.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="490" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="492.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="495" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="497.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="500" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="502.5" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="505" cy="86"></circle></g><g><circle class="dot-actual" r="4" cx="507.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="510" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="512.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="515" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="517.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="520" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="522.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="525" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="527.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="530" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="532.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="535" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="537.5" cy="69.49999999999994"></circle></g><g><circle class="dot-actual" r="4" cx="540" cy="69.49999999999994"></circle></g></svg> <h2 id="lambert-s-w-function">Lambert's W function</h2> <p>It's striking that the W function should appear here, as we've recently seen it arise in a very different context <a href="https://protobi.com/post/optimal-price-in-discrete-choice-models">Optimal Price in Descrete Choice Models</a> and was only identified as a named as recently as 1993 by Donald Knuth et al (see <a href="https://cs.uwaterloo.ca/research/tr/1993/03/W.pdf">"On Lambert's W Function"</a>).</p> <h2 id="so-what-">So what?</h2> <p>The most common codes are already likely to be unsurprising. In this case, the client already anticipated "Cost", "Ease" and "Uses cell phone" based on prior market knowledge. It's the codes that emerge with more data that yield new insights.</p> <p>After a number of responses were coded, the client created different code related to the cell phone:</p> <ul> <li>"Uses cell phone - can drop landline"</li> <li>"Uses cell phone - I can travel now"</li> <li>"Uses cell phone - I don't need to buy a new device"</li> </ul> <p>These distinctions provided new insights into the marketing strategy, and started to become apparent after they had coded 100-150 responses.</p> <h2 id="summary">Summary</h2> <p>Of course it's not possible to predict exactly how many verbatim codes you'll end up with . But it's safe to say that </p> <ul> <li>the more responses you collect, the more concepts you can identify, </li> <li>the rate at which you identify new codes will decrease.</li> </ul> <p>This article provides empirical curves based on other research domains that may help predict how many concepts we might expect to find based on the sample size.</p>
Date
Status
Published
Draft
Slug
edit
Thumbnail
Categories
Manage
Release
Features
Datasets
Surveys
Tips
NAMCS
Applications
Crosstab
Tutorial
Design
Concepts
Segmentation
Examples
Blog Test Category
Delete
Convert to MD