R: AI-Driven Code Generation, Explanation and Execution for Data Analysis

# AI-Driven Code Generation, Explanation and Execution for Data Analysis

## Documentation for package ‘mergen’ version 0.2.1

- DESCRIPTION file
- User guides, package vignettes and other documentation
- Package NEWS
- Package README

## Help Pages

check_install | Check and Install R Package
clean_code_blocks | Clean code blocks returned by the agent
executeCode | execute code
extractCode | extract the code and text from the text returned by LLM agent
extractFilenames | Extract file names from user prompt
extractInstallPkg | extract package names and install them
fileHeaderPrompt | Extract file headers from files in prompt
promptContext | Predefined prompt contexts for prompt engineering
runCodeInResponse | Executes the code in the received response from the agent
sampleResponse | Sample more solutions when non-executable code returned by the agent
selfcorrect | Self correct the code returned by the agent
sendPrompt | Send a prompt to a specified language model agent and return the response.
setupAgent | set up an online LLM API for subsequent tasks