DIGITAL LIBRARY
TXGRAPH – A TEACHING TOOL
1 University of Nicosia (CYPRUS)
2 Hotjar team (MALTA)
About this paper:
Appears in: EDULEARN18 Proceedings
Publication year: 2018
Pages: 245-255
ISBN: 978-84-09-02709-5
ISSN: 2340-1117
doi: 10.21125/edulearn.2018.0130
Conference name: 10th International Conference on Education and New Learning Technologies
Dates: 2-4 July, 2018
Location: Palma, Spain
Abstract:
This paper presents a language developed with the intention of being used by an educator for visual representation of fully customizable as well as default economics and business graphs in an undergraduate degree course in Economics, through the use of user input in the form of text which is structured according to the language defined. For the sole purpose of demonstrating the functionality, an early stage prototype application was created that incorporates capturing input, parsing it with the compiler and using the resulting commands to draw the corresponding graph on the screen.

Integrating some functionalities it was considered essential to improve user experience. One such functionality was to implement a more specialized code editor that provides the ability for defining custom language highlighting and therefore making it easier for the user to identify different types of commands and well as to distinguish parts of a command from one another. Another functionality that is considered to add to the speed and ease of use is providing hints of possible valid input choices while the user type commands.

The language supports creating two types of graphs. One category includes default graphs, which are the ones considered to be most commonly used in economics. The default graphs are generic, which means that the axes are not explicitly numbered and the graph follows a shape, rather than being drawn from an equation. The second category includes custom graphs, which are created using user provided parameters and offer a more detailed, customized outcome.

The application was developed in JavaScript to capture user input, pass it to the compiler and use the compiler’s resulting commands to draw the outcome on the screen. The compiler was also built using a JavaScript based parser generator, which also includes its own lexical analyzer and therefore its use aids in reducing external dependencies to tools. JavaScript adds to the versatility and availability of the application completely independent of the user’s operating system. An embeddable code editor was used in the application to add importance to user experience. In order to keep consistency across tools, the code editor implemented also uses JavaScript. This provided the possibility for implementing advanced features such as custom syntax highlighting and auto-completion. The paper focuses on the setup and development of the parser and the application functionalities, since the application offers the logic that made the practical implementation of the developed parser and its related functionalities a possibility.
Keywords:
Compiler, lexical analyser, economic graphs, teaching tool.