This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(tidyverse) | |
| project_two <- readr::read_csv( | |
| 'ID, GROUP, value1, value2 | |
| 1 , 1, 1, 1 | |
| 1 , 1, 1, 2 | |
| 2 , 1, 2, 1 | |
| 2 , 1, 2, 2 | |
| 1 , 2, 3, 1 | |
| 1 , 2, 3, 2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Lab2All<-function(data=Lab, L="L", a="a", b="b", name.ext="", deg.obs=2, illum="C"){ | |
| #Setting up variables in dataframe | |
| data[[paste("C", name.ext, sep="")]]<-NA | |
| data[[paste("H", name.ext, sep="")]]<-NA | |
| data[[paste("X", name.ext, sep="")]]<-NA | |
| data[[paste("Y", name.ext, sep="")]]<-NA | |
| data[[paste("Z", name.ext, sep="")]]<-NA | |
| data[[paste("R", name.ext, sep="")]]<-NA | |
| data[[paste("G", name.ext, sep="")]]<-NA |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| RGB2All<-function (data=RGB, R="R", G="G", B="B", name.ext="", deg.obs=2, illum="C"){ | |
| #Setting up variables in dataframe | |
| data[[paste("X", name.ext, sep="")]]<-NA | |
| data[[paste("Y", name.ext, sep="")]]<-NA | |
| data[[paste("Z", name.ext, sep="")]]<-NA | |
| data[[paste("L", name.ext, sep="")]]<-NA | |
| data[[paste("a", name.ext, sep="")]]<-NA | |
| data[[paste("b", name.ext, sep="")]]<-NA |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Building Opencv to add custom format support: | |
| ############################################### | |
| Prerequisites: | |
| -------------- | |
| opencv source - Download the required opencv version for Linux with the | |
| following link. (http://opencv.org/downloads.html) | |
| Dependencies : |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import math | |
| import numpy as np | |
| import cv2 | |
| cam = cv2.VideoCapture(0) | |
| cam.set(cv2.CAP_PROP_FRAME_WIDTH, 1280) | |
| cam.set(cv2.CAP_PROP_FRAME_HEIGHT, 720) | |
| cam.set(cv2.CAP_PROP_CONVERT_RGB, False) # turn off RGB conversion | |
| # cam.set(cv2.CAP_PROP_FOURCC('Y', '1', '6', '')) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import math | |
| import numpy as np | |
| import cv2 | |
| cam = cv2.VideoCapture(0) | |
| cam.set(cv2.CAP_PROP_FRAME_WIDTH, 1280) | |
| cam.set(cv2.CAP_PROP_FRAME_HEIGHT, 720) | |
| cam.set(cv2.CAP_PROP_CONVERT_RGB, False) # turn off RGB conversion | |
| # cam.set(cv2.CAP_PROP_FOURCC('Y', '1', '6', '')) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # TESTING HARDWARE | |
| # see3CAM_CU40 | |
| # raspberry Pi 3 bf8 | |
| # Raspbian Stretch 13-03-2018 | |
| # Python 3.5.3 | |
| # OpenCV 3.4.1 | |
| # load required libraries | |
| import math | |
| import numpy as np |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # TESTING HARDWARE | |
| # see3CAM_CU40 | |
| # raspberry Pi 3 bf8 | |
| # Raspbian Stretch 13-03-2018 | |
| # Python 3.5.3 | |
| # OpenCV 3.4.1 | |
| # load required libraries | |
| import math | |
| import numpy as np |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- | |
| title: "Untitled" | |
| author: "Brandon Hurr" | |
| date: "4/18/2018" | |
| output: | |
| beamer_presentation: | |
| latex_engine: xelatex | |
| --- | |
| ```{r setup, include=FALSE} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(openxlsx) | |
| library(readxl) | |
| library(Hmisc) | |
| library(tidyverse) | |
| #write out the iris dataset | |
| # write.xlsx(iris, "iris.xlsx") just to show you how | |
| # read in a dataset from excel | |
| iris2 <- read_excel("iris.xlsx") # this assumes it's in R's working directory (the one it boots up with) |