A Review of Games Written in R on CRAN (2024)

Posted on September 11, 2022 by R on Dr. Rick Tankard in R bloggers | 0 Comments

[This article was first published on R on Dr. Rick Tankard, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)

Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

R is primarily designed for statistical computing and graphics, andthat’s where I’ve spent most of my time in R. This includes developing an Rpackage, exSTRa, for my PhD. Risn’t an ideal language for video games, without native support forreactive programming. Though where there’s computing, there are games.

A brief review of games

I decided to look at what games are available on CRAN, searchingfor either “game”. Games outside of CRAN may be covered inanother post.For each R package that was a game, I’ve given a short review.

In this post, CLI stands for command-line interface (games without a graphics window).

Here’s the list, in a random order:

  • twenty48

    A CLI tile puzzle game where you slide the board in a directionto combine the same number. It didn’t come with instructions onthe rules of the game but is similar to a game called Threes, so Iwas able to work it out. Overall a good implementation.

    A Review of Games Written in R on CRAN (1)

  • proton

    A CLI text adventure game that gets you performing some datawrangling in order to solve the puzzles. This is a game that has areason to be in R. I quite enjoyed it, really. This game could berecommended to students for teaching R.

    Pietraszko uses a password which is very difficult to guess.At first, try to hack an account of a person which is not as cautious as Pietraszko.But who is the weakest point? Initial investigation suggests that John Insecure doesn'tcare about security and has an account on the Proton server. He may use a passwordwhich is easy to crack.Let's attack his account first!Problem 1: Find the login of John Insecure.Bit has scrapped 'employees' data (names and logins) from the www web page of TechnicalUniversity of Warsaw. The data is in the data.frame `employees`.Now, your task is to find John Insecure's login.When you finally find out what John's login is, use`proton(action = "login", login="XYZ")` command, where XYZ is Insecure's login.
  • BetaBit

    BetaBit is a sequel to proton.Wait a minute, it has proton in it along with two other games!These are The Frequeon Game and The Regression Game.The programming tasks get a bit harder here, but still a good way to havesome challenges for learning R.

     _____ _ _____ _____|_ _| |_ ___ | __|___ ___ ___ _ _ ___ ___ | __|___ _____ ___| | | | -_| | __| _| -_| . | | | . | | | | | .'| | -_||_| |_|_|___| |__| |_| |___|_ |___|___|_|_| |_____|__,|_|_|_|___||_|You've Got MailFrom: [emailprotected]To: [emailprotected]Subject: Interested?Hi,We are looking for a smart guy with extraordinary hacking skills.Our mutual friend assured us that you are our man.TL;DR: We are observing a group of terrorists that are planning something.We have intercepted some data, but do not know how to read it (attached).There is a password somewhere. We have to find it to stop terrorists.Would you like to join our team? Help us and we will help you in the future.It's not clear how to start. Our informer told us that the key is somehow related withthree key phrases: `guns`, `and`, `roses`.Probably these are the names of some messages / datasets.Would you like to check if you have access to any of them?If you want to help, please type:`frequon(subject = "Re: Interested?",content = "Text of the message that you have access to")`so as we could read the message too.Remember: any time you want, you can get some piece of advice, justtype: `frequon(hint=TRUE)`.
  • wordler

    This is a CLI implementation of Wordle.Pretty standard stuff, except it also gives you a programmatic interfaceso you can explore properties and strategies for the game Wordle.

    A Review of Games Written in R on CRAN (2)

  • ztype

    This isn’t really an R game, as it instead provides a function that issupposed to submita form to https://zty.pe to include functions from a package.In my case, that didn’t seem to work and I just got ordinary words in thebrowser.

  • sokoban

    A transport puzzle game where you push crates around in a warehouse to getthem to storage locations. An alright game.I couldn’t get it to work in R Studio, but did work in the R Gui on Windows.

    A Review of Games Written in R on CRAN (3)

  • happytime

    Another implementation of 2048.I prefer the twenty48 version more due to the use of colours.

    A Review of Games Written in R on CRAN (4)

  • FourScores

    This is basically Connect 4, except you can choose the size of the board.You can play either against the AI or against another human player.

    A Review of Games Written in R on CRAN (5)

  • casino

    A CLI game implementing Blackjack, Poker and a 3-reel Slot machine.Performs well.

    A Review of Games Written in R on CRAN (6)

  • pixelpuzzle

    Pizzle puzzle is a variation on the jigsaw puzzle, where instead, you have toshift rows of pixels until the image matches the original pixel image.Not a bad CLI game at all. It can get quite challenging at the harder difficultylevels.

    A Review of Games Written in R on CRAN (7)

  • tictactoe

    A CLI game of Tic Tac Toe.Allows you to simulate games of two AIs against each other, optionally ofdifferent levels.

    A Review of Games Written in R on CRAN (8)

  • rwarrior

    This is my own CLI game, so I am a bit biased. As a programming game,rwarrior would play differently if implemented in any other programminglanguage.I hope to add a graphical interface.

    A Review of Games Written in R on CRAN (9)

  • lightsout

    An R implementation of the Lights Out game in R.This Shiny app plays well and is quick to react.An excellent little puzzle game.

    A Review of Games Written in R on CRAN (10)

  • snake

    A graphical R implementation of the classic game snake.Unfortunately, it feels a bit laggy where you have to press yourinput when the snake is one block before when intending to move.

    A Review of Games Written in R on CRAN (11)

  • codebreaker

    A CLI implementation of Mastermind (though I don’t know if the rules vary here).Nice and colourful.A well-implemented game.

    A Review of Games Written in R on CRAN (12)

Two-player-only games:

  • BoardGames

    Despite the name, this package only implements the game Ultimate Tic Tac Toe on a 9×9 board for two players (no option for a single player).Still a game you could do on pen and paper, thisimplementation helps to check you are following the rules properly.The game runs smoothly.

    A Review of Games Written in R on CRAN (13)

Other packages I found that simulated or analysed games, but not a game inthemselves, included:

  • SnakesAndLaddersAnalysis

    Want to play Snakes and Ladders but only have a minute to play?Use SnakesAndLaddersAnalysis!This is more for simulating games of Snakes and Ladders than actual play.Learning to count is the point of the game, and you won’t get any of this here.

  • CamelUp

    Simulates the board game CamelUp in a Shiny interface but only supports thegame as one player.

  • stockfish, bigchess, chess and rchess are packages related to Chessengines, file formats, playing chess programmatically and analysis.It wasn’t apparent how these may let you play chess against theStockfish Chess engine or give a graphical interface.

Closing remarks

Have you tried any games in R?Games I’d recommend include BetaBit, pixelpuzzle, lightsout and my own package rwarrior.Some of the others aren’t really worth the hassle and you are better off playing a web version.With the Github releasednarapackage, we might be seeing more graphical based games coming to R.Let’s just hope nara can get on CRAN soon.

Related

To leave a comment for the author, please follow the link and comment on their blog: R on Dr. Rick Tankard.

R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.

Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

A Review of Games Written in R on CRAN (2024)

FAQs

What is a cran in R? ›

The Comprehensive R Archive Network (CRAN) is R's central software repository, supported by the R Foundation. It contains an archive of the latest and previous versions of the R distribution, documentation, and contributed R packages. It includes both source packages and pre-compiled binaries for Windows and macOS.

Is it possible to make a game in R? ›

Did you know you can use R and Shiny to build video games? Well, don't expect to create the next GTA in R, but you can still develop simple, enjoyable, and easy to play games.

Is R used in game development? ›

While R programming can be used to develop simple games, particularly text-based or basic graphical games, it is not designed for or typically used in game development. R's strengths lie in data analysis, statistical computing, and visualization, not in creating complex or high-performance games.

What is a CRAN used for? ›

A form of balance crane, tower cranes are fitted into the ground and used to move and carry heavy materials for longer distances. They are most often used when constructing tall buildings.

What is the relationship between RStudio and CRAN? ›

What is the relationship between RStudio and CRAN? // RStudio installs packages from CRAN that are not in Base R. CRAN is an online archive with R packages and other R-related resources that makes sure the resources are authentic and valid.

Is it illegal to emulate a game you already own? ›

If you own a game physically, you are likely to emulate or own a ROM of the game. However, there's no legal precedent in the United States to say it's illegal. There is no trial on record of any company going to court over emulators or ROMs and their use.

What games start with R? ›

Video Games starting with R
  • R-Type Dimensions EX.
  • R-Type Final 2.
  • R.A.W. : Realms of Ancient War.
  • R.U.S.E.
  • Rabbit And Steel.
  • Race Driver: Grid.
  • Race For The Galaxy.
  • Race the Sun.

Can a 12 year old create a game? ›

Yes, a kid can be a game developer! Game development is a skill that can be learned and practiced at any age, and many successful game developers started developing games when they were children. There are many resources available to kids who are interested in learning how to develop games.

When R is better than Python? ›

R programming is better suited for statistical learning, with unmatched libraries for data exploration and experimentation. Python is a better choice for machine learning and large-scale applications, especially for data analysis within web applications.

What coding language is best for games? ›

7 Most Popular Programming Languages for Game Development
  • C++ It's no surprise that C++ is one of the top game-developing languages, especially because it's such a popular, flexible solution. ...
  • Java. ...
  • JavaScript. ...
  • HTML5. ...
  • C# ...
  • Lua. ...
  • Python.
Jul 26, 2024

Is R used in real life? ›

R is one of the most widely used programming languages in the world today. It is used in almost every industry, ranging from finance, banking to medicine and manufacturing.

What is CRAN in data? ›

The Comprehensive R Archive Network (CRAN) was founded in 1997 by Kurt Hornik and Fritz Leisch to host R's source code, executable files, documentation, and user-created packages.

What does the acronym CRAN stand for in the context of R? ›

Comprehensive R Archive Network. Cran (unit), of uncleaned herring.

How do I check my R package for CRAN? ›

Use R CMD check and R CMD check --as-cran or, with devtools, check() . Modify your package so that there are no errors or warnings. You are now done with the essentials and have a proper R package! Go back to the main page, or go to the page about putting your R package on GitHub.

How many R packages are there on CRAN? ›

As of March 2023, there were over 19,000 packages available on the Comprehensive R Archive Network, or CRAN, the public clearing house for R packages.

Top Articles
Pregnant Coworker Falls Asleep During Lunch Break, AITA For Not Waking Her Up?
'AITA for not helping my husband with his children more?' 'We have a strong prenup.'
Will Byers X Male Reader
Research Tome Neltharus
Can ETH reach 10k in 2024?
Craigslist Mexico Cancun
Nwi Police Blotter
Needle Nose Peterbilt For Sale Craigslist
Student Rating Of Teaching Umn
Power Outage Map Albany Ny
Pro Groom Prices – The Pet Centre
Dumb Money
Nioh 2: Divine Gear [Hands-on Experience]
Rainfall Map Oklahoma
Dexter Gomovies
Mineral Wells Independent School District
Roster Resource Orioles
The best TV and film to watch this week - A Very Royal Scandal to Tulsa King
Mission Impossible 7 Showtimes Near Marcus Parkwood Cinema
Www Craigslist Com Bakersfield
Tyrone Unblocked Games Bitlife
Robeson County Mugshots 2022
12 Facts About John J. McCloy: The 20th Century’s Most Powerful American?
Prot Pally Wrath Pre Patch
Celina Powell Lil Meech Video: A Controversial Encounter Shakes Social Media - Video Reddit Trend
Pawn Shop Moline Il
Harrison County Wv Arrests This Week
Churchill Downs Racing Entries
2015 Kia Soul Serpentine Belt Diagram
Goodwill Of Central Iowa Outlet Des Moines Photos
Trinket Of Advanced Weaponry
4.231 Rounded To The Nearest Hundred
Dailymotion
Craigslist Middletown Ohio
UPC Code Lookup: Free UPC Code Lookup With Major Retailers
Learn4Good Job Posting
Grand Teton Pellet Stove Control Board
Joplin Pets Craigslist
How are you feeling? Vocabulary & expressions to answer this common question!
Michael Jordan: A timeline of the NBA legend
Сталь aisi 310s российский аналог
Stewartville Star Obituaries
1Exquisitetaste
ESA Science & Technology - The remarkable Red Rectangle: A stairway to heaven? [heic0408]
Parent Portal Pat Med
Valls family wants to build a hotel near Versailles Restaurant
Lady Nagant Funko Pop
Aznchikz
BYU Football: Instant Observations From Blowout Win At Wyoming
Law Students
Comenity/Banter
Latest Posts
Article information

Author: Twana Towne Ret

Last Updated:

Views: 6402

Rating: 4.3 / 5 (44 voted)

Reviews: 83% of readers found this page helpful

Author information

Name: Twana Towne Ret

Birthday: 1994-03-19

Address: Apt. 990 97439 Corwin Motorway, Port Eliseoburgh, NM 99144-2618

Phone: +5958753152963

Job: National Specialist

Hobby: Kayaking, Photography, Skydiving, Embroidery, Leather crafting, Orienteering, Cooking

Introduction: My name is Twana Towne Ret, I am a famous, talented, joyous, perfect, powerful, inquisitive, lovely person who loves writing and wants to share my knowledge and understanding with you.