Aidan,

That should be trivial in both the whole of wiki and tiddler focused counts.

Here I have added it to my subtitle macros.

<$list filter="[all[current]get[text]length[]compare:number:gt[0]]" 
variable=size>
<$button tooltip="Size in characters of the current tiddler" 
class="tc-btn-invisible">
{{$:/core/images/size}}<$text text=<<size>>/><$text text={{{ 
[<size>compare:number:lteq[1300]then[ 
in-post]] }}}/><$text text={{{ 
[<size>compare:number:gt[1300]compare:number:lteq[125000]then[ 
in-article]] }}}/>
<$text text={{{ [all[current]get[text]splitregexp[\s+]count[]] }}}/> Words
<$text text={{{ 
[all[current]get[text]splitregexp[\s+]count[]divide[250]round[]] }}}/> Pages
</$button>
</$list>

This idea of obtaining details from the text field hints at a possibility I 
have raised a few times, that is of analytics in Tiddlywiki. 

   - There are a lot of ways to measure, log and collate information in 
   tiddlywiki. 
   - While analytics is used by the big IT players it has also being 
   recognised that providing rich analytics back to the user about their own 
   data, is a great source of insight.
   - I have a thought experiment I am working on to build effective 
   analytics based on data as it arrives rather than just a calculation at a 
   particular time. 
   - I also raised color intuitions 
   <https://groups.google.com/d/msg/tiddlywiki/VBxJf0lF9o8/QFpXn2FlBwAJ> to 
   bring forward such analytics to allow ones intuition to work with the info.

Regards
Tones

On Tuesday, 13 October 2020 05:37:52 UTC+11, Aidan Grey wrote:
>
> Is there a way to shift that count into a variable, so that one could 
> calculate, say, how many pages that word count equates to?
>
> [[the word count]divide[250]round[]]
>
>
> On Mon, Oct 12, 2020 at 9:01 AM Amanda L. Goodman <[email protected] 
> <javascript:>> wrote:
>
>> Thanks for the clarification! 
>>
>> It appears to be working well on my end. 
>>
>> On Sun, Oct 11, 2020 at 5:09 PM TW Tones <[email protected] 
>> <javascript:>> wrote:
>>
>>> LG,
>>>
>>> The first is a character count in the current tiddler, the second the 
>>> word count in the current tiddler.
>>>
>>> Sorry if I have confused you, I think I assumed too much.
>>>
>>> Regards
>>> Tones
>>>
>>> On Monday, 12 October 2020 04:29:58 UTC+11, LG wrote:
>>>>
>>>> Hello, Tony!
>>>>
>>>> Well, that's what I get for trying to read when I'm so tired. I tried 
>>>> that and this is what I'm seeing now: 
>>>>
>>>> 11th October 2020 at 1:16pm 359 in-post 35 Words  
>>>>
>>>>
>>>> I checked it several times against other word counters to ensure that 
>>>> it is accurate. I'm guessing the "359 in-post" refers to all of the 
>>>> TiddlyWiki code? 
>>>>
>>>>
>>>>
>>>> On Sat, Oct 10, 2020 at 2:13 AM TW Tones <[email protected]> wrote:
>>>>
>>>>> LG,
>>>>>
>>>>> Simply put this provides a way to place things into the subtitle of 
>>>>> all tiddlers.
>>>>>
>>>>> One of those things is a display of *characters and words found in 
>>>>> the text field of tiddlers* found defined in 
>>>>> $:/PSaT/subtitle-tags/text-size
>>>>>
>>>>> It has the added feature that it has two numbers which it uses to 
>>>>> indicate if the character counts exceed one of two values.
>>>>> In this case the two thresholds relate to posts or articles in the 
>>>>> LinkedIn.com network. another example 10,000+ words I hear is what some 
>>>>> essays must be for universities etc...
>>>>>
>>>>> Your original enquiry for was the whole of the wiki? This is the same 
>>>>> but for each tiddler. Either remove the logic or add your own thresholds.
>>>>> By the way it works in edit as well :)
>>>>>
>>>>> Going forward the subtitle-tags.json what else can you do with it?
>>>>> Perhaps it could be designed to count words after rendering, to count 
>>>>> the works in the finished tiddler after transclusions etc..
>>>>>
>>>>>
>>>>> Has this answered your Questions?
>>>>>
>>>>> Tones
>>>>>
>>>>> On Saturday, 10 October 2020 13:31:16 UTC+11, LG wrote:
>>>>>>
>>>>>> Hey, Tony! 
>>>>>>
>>>>>> I'm happy to help. I'll admit that I'm not sure what I'm looking for 
>>>>>> here, so I'd appreciate you spelling it out for me. 
>>>>>>
>>>>>> I did the import and read the info off the usage tiddler. I then 
>>>>>> created a "Subtitle Test" tiddler and wrote: Hey. This resulted in it 
>>>>>> appearing right next to the date (under the title) with no space between 
>>>>>> the time and Hey. When I added "&nbsp; Hey" (with no quotation marks), 
>>>>>> the 
>>>>>> expected and hoped for space appeared between the date and Hey.
>>>>>>
>>>>>> 9th October 2020 at 10:21pm  Hey.
>>>>>>
>>>>>>
>>>>>> I'm not sure what this part means in what I should be looking for:
>>>>>>
>>>>>>>
>>>>>>>    - Are the number of characters below 1300 they fit in a linked 
>>>>>>>    in post
>>>>>>>    - Are the number of characters above 1300 and under 125,000 they 
>>>>>>>    fit in a linked in Article.
>>>>>>>
>>>>>>> How I'm interpreting it is that if the subtitle text is below a 
>>>>>> certain amount, it'll fit in the subtitle area. So I adjusted and set 
>>>>>> the 
>>>>>> below level as 10. After I put in ~60 dummy text and checked again, all 
>>>>>> ~60 
>>>>>> words still showed up in the subtitle field. I'm certain that I'm not 
>>>>>> understanding your intentions. 
>>>>>>
>>>>>> Best, 
>>>>>>
>>>>>> LG
>>>>>>
>>>>>> On Fri, Oct 9, 2020 at 12:42 AM TW Tones <[email protected]> wrote:
>>>>>>
>>>>>>> Lg,
>>>>>>>
>>>>>>> I was working on a small project to create subtitle tags, basically 
>>>>>>> using the tag $:/tags/subtitle you can place items in the tiddler 
>>>>>>> subtitle.
>>>>>>>
>>>>>>> This text size measure sounded like an ideal candidate.
>>>>>>>
>>>>>>>    - Using the suggestions in this thread for words and characters
>>>>>>>    - I also added two value tests
>>>>>>>       - Are the number of characters below 1300 they fit in a 
>>>>>>>       linked in post
>>>>>>>       - Are the number of characters above 1300 and under 125,000 
>>>>>>>       they fit in a linked in Article.
>>>>>>>    
>>>>>>> If you install this JSON then open $:/PSaT/subtitle-tags/text-size 
>>>>>>> and you can see how I did it and adjust to you needs.
>>>>>>>
>>>>>>> *Note It modified the core tiddler $:/core/ui/ViewTemplate/subtitle*
>>>>>>>
>>>>>>> Any feedback will help me publish it.
>>>>>>>
>>>>>>> Regards
>>>>>>> Tony
>>>>>>>
>>>>>>> On Monday, 5 October 2020 11:58:50 UTC+11, LG wrote:
>>>>>>>>
>>>>>>>> I copied all of my writing into one TW file. Is there a way to get 
>>>>>>>> a total word count? There are 823 tiddlers. 
>>>>>>>
>>>>>>> -- 
>>>>>>> You received this message because you are subscribed to a topic in 
>>>>>>> the Google Groups "TiddlyWiki" group.
>>>>>>> To unsubscribe from this topic, visit 
>>>>>>> https://groups.google.com/d/topic/tiddlywiki/6acL1HS8Zws/unsubscribe
>>>>>>> .
>>>>>>> To unsubscribe from this group and all its topics, send an email to 
>>>>>>> [email protected].
>>>>>>> To view this discussion on the web visit 
>>>>>>> https://groups.google.com/d/msgid/tiddlywiki/bba9c795-dd2b-4c6a-aa80-2528c3c496b4o%40googlegroups.com
>>>>>>>  
>>>>>>> <https://groups.google.com/d/msgid/tiddlywiki/bba9c795-dd2b-4c6a-aa80-2528c3c496b4o%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>>>>> .
>>>>>>>
>>>>>> -- 
>>>>> You received this message because you are subscribed to a topic in the 
>>>>> Google Groups "TiddlyWiki" group.
>>>>> To unsubscribe from this topic, visit 
>>>>> https://groups.google.com/d/topic/tiddlywiki/6acL1HS8Zws/unsubscribe.
>>>>> To unsubscribe from this group and all its topics, send an email to 
>>>>> [email protected].
>>>>> To view this discussion on the web visit 
>>>>> https://groups.google.com/d/msgid/tiddlywiki/3577e75b-8e16-4f56-a74f-277bc6301560o%40googlegroups.com
>>>>>  
>>>>> <https://groups.google.com/d/msgid/tiddlywiki/3577e75b-8e16-4f56-a74f-277bc6301560o%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>>> .
>>>>>
>>>> -- 
>>> You received this message because you are subscribed to a topic in the 
>>> Google Groups "TiddlyWiki" group.
>>> To unsubscribe from this topic, visit 
>>> https://groups.google.com/d/topic/tiddlywiki/6acL1HS8Zws/unsubscribe.
>>> To unsubscribe from this group and all its topics, send an email to 
>>> [email protected] <javascript:>.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/tiddlywiki/7a9c1184-e7cf-4c00-8278-3bc975736d22o%40googlegroups.com
>>>  
>>> <https://groups.google.com/d/msgid/tiddlywiki/7a9c1184-e7cf-4c00-8278-3bc975736d22o%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "TiddlyWiki" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected] <javascript:>.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/tiddlywiki/CAFWQ5Z4VsQnjPSv9PzAsRzfxeNjRRk%2BR6BeASoL2REcNe6_oyA%40mail.gmail.com
>>  
>> <https://groups.google.com/d/msgid/tiddlywiki/CAFWQ5Z4VsQnjPSv9PzAsRzfxeNjRRk%2BR6BeASoL2REcNe6_oyA%40mail.gmail.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/cd9e539e-c399-4938-98c9-2d5a722c3b51o%40googlegroups.com.

Reply via email to