[self-interest] pie-chart tutorial [1 Attachment]

Russell Allen mail at russell-allen.com
Fri Mar 7 00:44:38 UTC 2014


 

Hi Stephen, 

You can see if mapBy: is a defined method name by selecting it and right
clicking and choosing 'implementers' 

Also, when your code pops up the error, you should be able to expand the
stack on the error's outliner, and play around with it. My guess is that
'data copy' is returning nil, or some other object which doesn't
understand mapBy: You should be able to get an outliner of it and see
for yourself what object it is. 

Try clicking things which are raised like buttons, or small triangles
which look like they might expand and see how you go :) 

Russell 

On 2014-03-07 03:38, Stephen De Gabrielle wrote: 

> [Attachment(s) from Stephen De Gabrielle included below] 
> 
> Hi, 
> 
> I was working through the pie-chart tutorial in the main repository at 
> self [1] / docs [2] / tutorial [3] / Morphic [4] / PieChart [5] / CHANGES.HTML 
> 
> I think I did everything right but I am getting an error 
> 'Lookup error, 'mapBy:' not found' 
> 
> I believe this is a valid selector, but I am only just starting with the language 
> this is the 'copyNewData: data'' slot' text 
> 
>> | new. wList |
>> new: copyRemoveAllMorphs.
>> wList:
>> data copy mapBy: [| :val. w |
>> w: pieWedgeMorph copyRemoveAllMorphs.
>> w color: paint copyRandom.
>> w amount: val.
>> ].
>> new addAllMorphs: wList.
>> new
> 
> I checked the handbook, mapBy: is a valid selector http://handbook.selflanguage.org/4.5/usefulselectors.html [6] 
> 
> Any ideas where I have gone wrong? 
> 
> Kind regards, 
> 
> Stephen 
> 
> --
> Stephen De Gabrielle 
> 

 

Links:
------
[1]
https://github.com/russellallen/self/tree/5e8031667b5d549d4b4a6cec41e06aa97c3c9c45
[2]
https://github.com/russellallen/self/tree/5e8031667b5d549d4b4a6cec41e06aa97c3c9c45/docs
[3]
https://github.com/russellallen/self/tree/5e8031667b5d549d4b4a6cec41e06aa97c3c9c45/docs/tutorial
[4]
https://github.com/russellallen/self/tree/5e8031667b5d549d4b4a6cec41e06aa97c3c9c45/docs/tutorial/Morphic
[5]
https://github.com/russellallen/self/tree/5e8031667b5d549d4b4a6cec41e06aa97c3c9c45/docs/tutorial/Morphic/PieChart
[6] http://handbook.selflanguage.org/4.5/usefulselectors.html
[7]
https://groups.yahoo.com/group/self-interest/attachments/folder/51280297/item/list
[8]
https://groups.yahoo.com/group/self-interest/attachments/folder/51280297/item/1577102556/view
[9]
https://groups.yahoo.com/group/self-interest/post;_ylc=X3oDMTJwaGtxbGRjBF9TAzk3MzU5NzE0BGdycElkAzExMTQ4MzUEZ3Jwc3BJZAMxNzA3Mjc2NzE4BG1zZ0lkAzMwNTkEc2VjA2Z0cgRzbGsDcnBseQRzdGltZQMxMzk0MTIzOTE0?act=reply&messageNum=3059
[10]
https://groups.yahoo.com/group/self-interest/post;_ylc=X3oDMTJla2tmcG9jBF9TAzk3MzU5NzE0BGdycElkAzExMTQ4MzUEZ3Jwc3BJZAMxNzA3Mjc2NzE4BHNlYwNmdHIEc2xrA250cGMEc3RpbWUDMTM5NDEyMzkxNA--
[11]
https://groups.yahoo.com/group/self-interest/message/3059;_ylc=X3oDMTM0N3A5ZTc1BF9TAzk3MzU5NzE0BGdycElkAzExMTQ4MzUEZ3Jwc3BJZAMxNzA3Mjc2NzE4BG1zZ0lkAzMwNTkEc2VjA2Z0cgRzbGsDdnRwYwRzdGltZQMxMzk0MTIzOTE0BHRwY0lkAzMwNTk-
[12]
https://groups.yahoo.com/group/self-interest;_ylc=X3oDMTJlZTI0dW1iBF9TAzk3MzU5NzE0BGdycElkAzExMTQ4MzUEZ3Jwc3BJZAMxNzA3Mjc2NzE4BHNlYwN2dGwEc2xrA3ZnaHAEc3RpbWUDMTM5NDEyMzkxNA--
[13]
https://groups.yahoo.com/group/self-interest/members;_ylc=X3oDMTJmYWs2Zmg2BF9TAzk3MzU5NzE0BGdycElkAzExMTQ4MzUEZ3Jwc3BJZAMxNzA3Mjc2NzE4BHNlYwN2dGwEc2xrA3ZtYnJzBHN0aW1lAzEzOTQxMjM5MTQ-?o=6
[14]
https://groups.yahoo.com/;_ylc=X3oDMTJkaXZhM2ZxBF9TAzk3NDc2NTkwBGdycElkAzExMTQ4MzUEZ3Jwc3BJZAMxNzA3Mjc2NzE4BHNlYwNmdHIEc2xrA2dmcARzdGltZQMxMzk0MTIzOTE0
[15] https://info.yahoo.com/privacy/us/yahoo/groups/details.html
[16] https://info.yahoo.com/legal/us/yahoo/utos/terms/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.selflanguage.org/pipermail/self-interest/attachments/20140307/381df424/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/x-ygp-stripped
Size: 204 bytes
Desc: not available
URL: <http://lists.selflanguage.org/pipermail/self-interest/attachments/20140307/381df424/attachment.bin>


More information about the Self-interest mailing list