b3e24bf719c98fba5d88cfc144b32f154c66f611,test/test_kernel.py,TestKernel,testGetPythonDataFromR,#TestKernel#,238
Before Change
iopub = kc.iopub_channel
// create a data frame
msg_id, content = execute(kc=kc, code="null_var = None")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="num_var = 123")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="import numpy\nnum_arr_var = numpy.array([1, 2, 3])")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="logic_var = True")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="logic_arr_var = [True, False, True]")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="char_var = "123"")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="char_arr_var = ["1", "2", "3"]")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="list_var = [1, 2, "3"]")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="dict_var = dict(a=1, b=2, c="3")")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="set_var = set(1, 2, "3")")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="mat_var = numpy.matrix([[1,2],[3,4]])")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="%use R")
clear_channels(iopub)
wait_for_idle(kc)
msg_id, content = execute(kc=kc, code="%get null_var num_var num_arr_var logic_var logic_arr_var char_var char_arr_var mat_var set_var list_var dict_var")
// need to test passed values
After Change
msg_id, content = execute(kc=kc, code="%get null_var num_var num_arr_var logic_var logic_arr_var char_var char_arr_var mat_var set_var list_var dict_var")
wait_for_idle(kc)
// need to test passed values
msg_id, content = execute(kc=kc, code="%use sos")
wait_for_idle(kc)
def testPutRDataFrameToPython(self):
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 3
Instances
Project Name: vatlab/SoS
Commit Name: b3e24bf719c98fba5d88cfc144b32f154c66f611
Time: 2016-10-26
Author: ben.bog@gmail.com
File Name: test/test_kernel.py
Class Name: TestKernel
Method Name: testGetPythonDataFromR
Project Name: vatlab/SoS
Commit Name: b3e24bf719c98fba5d88cfc144b32f154c66f611
Time: 2016-10-26
Author: ben.bog@gmail.com
File Name: test/test_kernel.py
Class Name: TestKernel
Method Name: testPutRDataFrameToPython
Project Name: vatlab/SoS
Commit Name: b3e24bf719c98fba5d88cfc144b32f154c66f611
Time: 2016-10-26
Author: ben.bog@gmail.com
File Name: test/test_kernel.py
Class Name: TestKernel
Method Name: testPutRDataToPython
Project Name: vatlab/SoS
Commit Name: b3e24bf719c98fba5d88cfc144b32f154c66f611
Time: 2016-10-26
Author: ben.bog@gmail.com
File Name: test/test_kernel.py
Class Name: TestKernel
Method Name: testMagicGet