-2

I try to use awk to extract from a dataframe, but I get this message

    could not find function "awk"

Do I need to install a package?

1 Answers1

2

Awk is a system command you need to call out of your R environment to the operating system and execute the awk command.

Example from R console
> system( 'awk \'BEGIN { print "Hello, world" }\' ')
Hello, world

For future reference you may want to do a search in StackOverflow of related problems:

Search in StackOverflow for "R AWK"

https://stackoverflow.com/search?q=R+AWK

Technophobe01
  • 8,212
  • 3
  • 32
  • 59