[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [amibroker] AmiBroker AFL Glossary project --READY TO PROCEED



PureBytes Links

Trading Reference Links

Keith,

On Sep 6, 2008, at 8:38 PM, Keith McCombs wrote:

Dennis --
I was able to open the .txt and .rtf files, but not Part 1.1.3 or Part 1.1.5.  My system seems to think that they are .html files, but FireFox presents a blank screen for both.

The .txt and .rtf were the only attachments -- those others were something added by the ISP somewhere along the line in the conversion process.  I have seen it once before with my accountant.  Could be something to do with Mac vs PC formats. 

Have you written the software to convert the templates into a single searchable document yet?

I have not started that yet, since I needed a template and part of a database to work with first.  I also need the form of a finished document to write out.  I was planning on your basic format to start with -- though I have additional information in the template now that should be optionally written out for test purposes.
However, I am happy to share the work --if someone would like to try their hand at writing an AFL conversion formula to read in the database text file and write out another formatted text file.  My AFL will end up looking like a very simple minded plodding formula --mirrors my mind... LOL

Since AFL can only write out a text file, I was thinking that RTF or HTML would have to be written into the text to get even simple things like bold text.  I think HTML might be a simpler format to use for this, but RTF is compatible with just about every word processor.  Perhaps we just stick with plain text for now.  

If I were to use RTF, I would take some plain text conversion, edit in the format in my editor and save it out as RTF.  Then I would read it in as plain text so I would have all the formatting text.  Then I would just use the tags and commands from that to assemble formatted documents from my AFL.  See how my simple mind works ;-)

BTW, I notice that links that you entered do not appear as 'clickable' in OpenOffice.org 2.4.1.  I don't know about Word (I recently removed it from my computer, after too many years of complete disgust).  However, they are 'clickable' in Thunderbird email and in Adobe Reader, after conversion to .pdf.  I have been fooled in the past by typing a link name correctly and then converting it to a 'clickable' link using a OO.o or Word, and making a typing error at that time.  Therefore, I STRONGLY recommend that links remain plain text in the template for easy editing, and too reduce wasted effort.

ABSOLUTELY!  I went to some pains to make sure the links were just text in the files.  Many programs and emails have an option to turn text that looks like a url into a clickable link.  I goofed and did not turn that option OFF in my email program when I sent the template, so it made them clickable.  Don't try to copy and edit those urls from the post, type them in from scratch or use the attached files.  The clickable text displayed for a url is not the actual url used, even if it looks like a url.  For instance, if you edit the clickable url text to say HappyDays it will still take you to the same url.  That is why I have a Link_name:  item that would be the text that would be clickable, but the Link_url: item is the actual url.

However, If someone does not get this right, it would not really be that big a deal, because any text editor can save the file as text only, and all that hidden link stuff goes away and just the text remains (that's how I fix mine).

BR,
Dennis



-- Keith

Dennis Brown wrote:
Hello,

I am starting a new thread with this message because it is a starting point to proceed with filling in the Glossary database and contains the template to do so.  I have included the template in the text of this message, and also attached a .txt and a .rtf version of the file.  I can also email or upload them if these is not sufficient for some who wish to contribute.

I have racked my brains for a few days trying out different variations of the previous suggestions (including my own) and thinking about how the Glossary data could be used, and also about how to parse and translate it into other formats.  I also filled out a couple of entries several different ways to see how it was to work with.  

I discovered it is easier to work with a fixed width font, and I have backed away from the pseudo XML syntax as that was more confusing to the human eye than a simple Keyword:  type of entry.  There is no difference in ease of parsing.  I did retain a couple of ideas from the XML that would help make it more robust to parse.  

Translating formats = fill a bucket with one entry of defaults, then parse in the data items of one entry, then empty the bucket in whatever format to "print" or populate a database.

I thought about having a rigid functional hierarchy to place entries, but rejected that because it is so much more useful to be able to assign an entry to multiple functional groups.  If I want to find all the string functions, or I want to get all the Date/Time functions I would have overlap and I want to see that in a listing.  In reality, the groups are just more search tags, but they could be treated a little differently under certain circumstances.  By defining the functional groups, we get a consistent way to find or organize some types of output.  We have to define more functional groups than we now have, but that can come over time.

READY TO PROCEED!

I am ready to proceed with creating glossary entries at this point.  I might personally be able to do one a day on average.  At that rate it would take many years to compile a complete glossary for AB.  This is one of the reasons that it will take many hands to make this happen.  It is a bit tedious to find things like links to other sources of information.  On the other hand, information can always be added later to any entry to flesh it out, as long as the basic stuff is there.  It just gets more useful over time.

After filling out just a couple of these, I have a great appreciation for the initial work Keith did that really got the ball rolling.  Thanks again Keith.

I will continue filling out the entries for the string manipulation entries.

Please volunteer to make a text file for one of the other functional groups.  

Here are some small ones to try out that are not too demanding:

Form the AFL Function Reference - Categorized list of functions

Referencing other symbol data
Time Frame functions
File Input/Output functions
Statistical functions 
Moving averages, summation
Lowest/Highest
Composites
Basic price pattern detection

Just  pick one and reply to this post, or send an email to me to stake your claim.

Thanks in advance to all who offer to help with this project.

Best regards,
Dennis


Template sample for Glossary Database entry --20080906

Font used: Courier Regular 12 point fixed width UniCode UTF-8

Notes about template:
Text is ignored if it is not between Begin_entry: and End_entry: keywords.
  This allows Keyword: in comment lines outside the structure or the 
  whole entry to be ignored as shown below.
Text is ignored if the line does not start with a data item Keyword:
  This allows comment lines inside a structure.
  However, I would recommend starting a comment with "//" to be more clear.
The order of some items is important.
  A "*" below indicates an item that must follow the previous item.
Some items can be repeated as many times as needed.
  A "+" below indicates these items.
A group listing is used to determine to which groups this entry belongs.
  The Tag_group: would have an entry for every level above this entry.
  An entry can also be a member of more than one group,
  for instance, a string function might also be a date or time function.
  The Tag_group: data are also treated as search tags.
A synonym could have an entry that simply references another entry.

General Template:

//Begin_entry:  Starts an entry (// forces ignore this entry)
Name_entry:     Entry Text
Name_long:      Expanded Name
Description:    Short description of entry

Return_type:    Return Value type (a, n, t, an, nt)
Return_name:    Optional Descriptive Name of Return Value

Arg_type:       +Argument Value type (a, n, t, an, nt)
Arg_name:       +*Optional Descriptive Name of Argument Value
Arg_default:    +*Optional Default Argument Value

Link_ABdoc:     Link url to AB manual document
Link_video:     Link url to AB video help
Link_tutorial:  Link url to AB tutorial doc
Link_KBdoc:     Link url to AB knowledge base
Link_UKBdoc:    Link url to Users knowledge base
Link_url:       +Link url to any useful page
Link_name:      +*Optional Name text for any Link above

Version_AB:     Earliest AB version to support feature (x.x)
Tag_group:      +Group term from group hierarchy list
Tag_search:     +Search term

Related_entry:  +Related Glossary entry
End_entry:      Ends this entry

// The simplest synonym entry would look like this:

Begin_entry:
Name_entry:     AFL
Name_long:      AmiBroker Formula Language
Description:    Abbreviation for AmiBroker Formula Language
Tag_group:      AFL
Related_entry:  AmiBroker Formula Language
End_entry:

// String manipulation functions:

Begin_entry:
Name_entry:     Asc()
Name_long:      get ASCII code of character
Description:    Returns the ASCII code number for a text character
Return_type:    n
Return_name:    ASCII code
Arg_type:       t
Arg_name:       String
Arg_type:       n
Arg_name:       CharacterPosition
Arg_default:    0
Link_ABdoc:     http://www.amibroker.com/f?asc
Link_name:      ASCII Definition and table
Version_AB:     x.x
Tag_group:      AFL
Tag_group:      Functions
Tag_group:      String manipulation
Tag_group:      Type Conversions
Tag_search:     ASCII
Tag_search:     character
Tag_search:     convert
Tag_search:     code
Related_entry:  
End_entry:


Begin_entry:
Name_entry:     DateTimeToStr()
Name_long:      convert datetime to string
Description:    Returns a text representation of the datetime number
Return_type:    t
Return_name:    DateTime Text
Arg_type:       n
Arg_name:       DateTime Number
Version_AB:     x.x
Tag_group:      AFL
Tag_group:      Functions
Tag_group:      String manipulation
Tag_group:      Type Conversions
Tag_group:      Date and Time
Tag_search:     datetime
Tag_search:     date
Tag_search:     time
Tag_search:     convert
Related_entry:  StrToDateTime()
Related_entry:  Now()
Related_entry:  DateTime()
Related_entry:  TimeNum()
Related_entry:  Date()
End_entry:


__._,_.___

Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

For other support material please check also:
http://www.amibroker.com/support.html




Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe

__,_._,___