#Import data #Only Midle and Low Class students (N=42)

read.csv("only_low_middle_level.csv") #only students who marked less than 12 in Pre_Test N=42
##     ID    username    feedback ITS pre_test_type post_test_type class
## 1  106    yessomen      effort  12             A              B     3
## 2   13    niceniku performance  12             A              B     1
## 3   41     goramen      effort  12             B              A     2
## 4   52    nicetako performance  12             A              B     2
## 5   83     niceimo performance  12             A              B     3
## 6    7    gotamago      effort  12             B              A     1
## 7   35     yestofu      effort  12             A              B     1
## 8   37     gogyoza      effort  12             B              A     2
## 9   16  nicetamago performance  12             A              B     1
## 10  25    oktamago performance  12             B              A     1
## 11  54    niceyuba performance  12             A              B     2
## 12  82     niceice performance  12             A              B     3
## 13   5      gosoba      effort  12             B              A     1
## 14  34   yestamago      effort  12             A              B     1
## 15  44     gounagi      effort  12             B              A     2
## 16  79     gosomen      effort  12             B              A     3
## 17  23      oksoba performance  12             B              A     1
## 18  46   nicegyoza performance  12             A              B     2
## 19  93      oknabe performance  12             B              A     3
## 20 102     yesnabe      effort  12             A              B     3
## 21  69   yessakana      effort  12             A              B     2
## 22  75      gonabe      effort  12             B              A     3
## 23  15   nicesushi performance  12             A              B     1
## 24  49 niceonigiri performance  12             A              B     2
## 25  91       okice performance  12             B              A     3
## 26  29     yesfugu      effort  12             A              B     1
## 27  39      gokaki      effort  12             B              A     2
## 28 100      yesice      effort  12             A              B     3
## 29  10    nicecola performance  11             A              B     1
## 30  12    nicemiso performance  12             A              B     1
## 31   8      gotofu      effort  10             B              A     1
## 32  76    gonigiri      effort  12             B              A     3
## 33  27      okudon performance  12             B              A     1
## 34  33    yessushi      effort  12             A              B     1
## 35  40   goonigiri      effort  12             B              A     2
## 36  74       goimo      effort  12             B              A     3
## 37  21      okmiso performance  12             B              A     1
## 38  26      oktofu performance  12             B              A     1
## 39  50   niceramen performance  12             A              B     2
## 40  56       okika performance  12             B              A     2
## 41  58   okonigiri performance  12             B              A     2
## 42  96      oksake performance  12             B              A     3
##    PreTest_Total_Score PostTest_Total_Score Post_Pre Intrinsic_Value
## 1                    1                    0       -1               6
## 2                    1                   14       13              14
## 3                    2                    1       -1              11
## 4                    2                    3        1               8
## 5                    2                   13       11               3
## 6                    3                    9        6              10
## 7                    3                   10        7               9
## 8                    3                    3        0               6
## 9                    3                    3        0               9
## 10                   3                    4        1               7
## 11                   3                   12        9               7
## 12                   3                    1       -2               4
## 13                   4                    6        2               6
## 14                   4                    3       -1               6
## 15                   5                    8        3               8
## 16                   5                   10        5               8
## 17                   5                    9        4              14
## 18                   5                    2       -3              10
## 19                   5                    8        3              13
## 20                   7                    2       -5              12
## 21                   8                   11        3               5
## 22                   8                    6       -2              10
## 23                   8                    8        0              11
## 24                   8                   11        3              15
## 25                   8                   12        4              12
## 26                   9                   11        2               8
## 27                   9                    4       -5              15
## 28                   9                    6       -3               9
## 29                   9                   11        2              13
## 30                   9                    9        0              11
## 31                  10                    8       -2              13
## 32                  10                   12        2              13
## 33                  10                   12        2              12
## 34                  11                   11        0              15
## 35                  11                   12        1              13
## 36                  11                    3       -8               5
## 37                  11                   14        3              12
## 38                  11                   14        3               7
## 39                  11                   13        2               7
## 40                  11                   13        2              14
## 41                  11                   10       -1               9
## 42                  11                   13        2              11
##    Self.regulation Self.efficacy Test_anxiety Survey_Total_Score
## 1                9             9            9                 33
## 2               17            17           15                 63
## 3               16            16            4                 47
## 4                7             5            5                 25
## 5               11             4            5                 23
## 6               15            12            9                 46
## 7               13            14           14                 50
## 8               15             6            4                 31
## 9               13            10            8                 40
## 10              14            13            9                 43
## 11              13            12           13                 45
## 12              17            11            4                 36
## 13              11            12            7                 36
## 14              12            11            7                 36
## 15              11            12            8                 39
## 16              14             7            7                 36
## 17              13            11            5                 43
## 18              16            11            4                 41
## 19              17            15           16                 61
## 20              18            17           15                 62
## 21              15            11            7                 38
## 22              11             9           14                 44
## 23              15            15            4                 45
## 24              17            16           17                 65
## 25              14            17           14                 57
## 26              11             9           15                 43
## 27              18            14           12                 59
## 28               8             7           12                 36
## 29              18            16           15                 62
## 30              15            15           16                 57
## 31              16            17           15                 61
## 32              16            15           12                 56
## 33              14            11           12                 49
## 34              16            17           13                 61
## 35              19            17            5                 54
## 36              10             6            6                 27
## 37              15            12           12                 51
## 38              14            11           13                 45
## 39              14             8            7                 36
## 40              18            20           14                 66
## 41              14            12            9                 44
## 42              11            13           11                 46
read.csv("only_low_middle_level_effort.csv") #only students who marked less than 12 in Pre_Test and effort feedback group N=20
##     ID  username feedback ITS pre_test_type post_test_type class
## 1  106  yessomen   effort  12             A              B     3
## 2   41   goramen   effort  12             B              A     2
## 3    7  gotamago   effort  12             B              A     1
## 4   35   yestofu   effort  12             A              B     1
## 5   37   gogyoza   effort  12             B              A     2
## 6    5    gosoba   effort  12             B              A     1
## 7   34 yestamago   effort  12             A              B     1
## 8   44   gounagi   effort  12             B              A     2
## 9   79   gosomen   effort  12             B              A     3
## 10 102   yesnabe   effort  12             A              B     3
## 11  69 yessakana   effort  12             A              B     2
## 12  75    gonabe   effort  12             B              A     3
## 13  29   yesfugu   effort  12             A              B     1
## 14  39    gokaki   effort  12             B              A     2
## 15 100    yesice   effort  12             A              B     3
## 16   8    gotofu   effort  10             B              A     1
## 17  76  gonigiri   effort  12             B              A     3
## 18  33  yessushi   effort  12             A              B     1
## 19  40 goonigiri   effort  12             B              A     2
## 20  74     goimo   effort  12             B              A     3
##    PreTest_Total_Score PostTest_Total_Score Post_Pre Intrinsic_Value
## 1                    1                    0       -1               6
## 2                    2                    1       -1              11
## 3                    3                    9        6              10
## 4                    3                   10        7               9
## 5                    3                    3        0               6
## 6                    4                    6        2               6
## 7                    4                    3       -1               6
## 8                    5                    8        3               8
## 9                    5                   10        5               8
## 10                   7                    2       -5              12
## 11                   8                   11        3               5
## 12                   8                    6       -2              10
## 13                   9                   11        2               8
## 14                   9                    4       -5              15
## 15                   9                    6       -3               9
## 16                  10                    8       -2              13
## 17                  10                   12        2              13
## 18                  11                   11        0              15
## 19                  11                   12        1              13
## 20                  11                    3       -8               5
##    Self.regulation Self.efficacy Test_anxiety Survey_Total_Score
## 1                9             9            9                 33
## 2               16            16            4                 47
## 3               15            12            9                 46
## 4               13            14           14                 50
## 5               15             6            4                 31
## 6               11            12            7                 36
## 7               12            11            7                 36
## 8               11            12            8                 39
## 9               14             7            7                 36
## 10              18            17           15                 62
## 11              15            11            7                 38
## 12              11             9           14                 44
## 13              11             9           15                 43
## 14              18            14           12                 59
## 15               8             7           12                 36
## 16              16            17           15                 61
## 17              16            15           12                 56
## 18              16            17           13                 61
## 19              19            17            5                 54
## 20              10             6            6                 27
read.csv("only_low_middle_level_performance.csv") #only students who marked less than 12 in Pre_Test and performance feedback group N=22
##    ID    username    feedback ITS pre_test_type post_test_type class
## 1  13    niceniku performance  12             A              B     1
## 2  52    nicetako performance  12             A              B     2
## 3  83     niceimo performance  12             A              B     3
## 4  16  nicetamago performance  12             A              B     1
## 5  25    oktamago performance  12             B              A     1
## 6  54    niceyuba performance  12             A              B     2
## 7  82     niceice performance  12             A              B     3
## 8  23      oksoba performance  12             B              A     1
## 9  46   nicegyoza performance  12             A              B     2
## 10 93      oknabe performance  12             B              A     3
## 11 15   nicesushi performance  12             A              B     1
## 12 49 niceonigiri performance  12             A              B     2
## 13 91       okice performance  12             B              A     3
## 14 10    nicecola performance  11             A              B     1
## 15 12    nicemiso performance  12             A              B     1
## 16 27      okudon performance  12             B              A     1
## 17 21      okmiso performance  12             B              A     1
## 18 26      oktofu performance  12             B              A     1
## 19 50   niceramen performance  12             A              B     2
## 20 56       okika performance  12             B              A     2
## 21 58   okonigiri performance  12             B              A     2
## 22 96      oksake performance  12             B              A     3
##    PreTest_Total_Score PostTest_Total_Score Post_Pre Intrinsic_Value
## 1                    1                   14       13              14
## 2                    2                    3        1               8
## 3                    2                   13       11               3
## 4                    3                    3        0               9
## 5                    3                    4        1               7
## 6                    3                   12        9               7
## 7                    3                    1       -2               4
## 8                    5                    9        4              14
## 9                    5                    2       -3              10
## 10                   5                    8        3              13
## 11                   8                    8        0              11
## 12                   8                   11        3              15
## 13                   8                   12        4              12
## 14                   9                   11        2              13
## 15                   9                    9        0              11
## 16                  10                   12        2              12
## 17                  11                   14        3              12
## 18                  11                   14        3               7
## 19                  11                   13        2               7
## 20                  11                   13        2              14
## 21                  11                   10       -1               9
## 22                  11                   13        2              11
##    Self.regulation Self.efficacy Test_anxiety Survey_Total_Score
## 1               17            17           15                 63
## 2                7             5            5                 25
## 3               11             4            5                 23
## 4               13            10            8                 40
## 5               14            13            9                 43
## 6               13            12           13                 45
## 7               17            11            4                 36
## 8               13            11            5                 43
## 9               16            11            4                 41
## 10              17            15           16                 61
## 11              15            15            4                 45
## 12              17            16           17                 65
## 13              14            17           14                 57
## 14              18            16           15                 62
## 15              15            15           16                 57
## 16              14            11           12                 49
## 17              15            12           12                 51
## 18              14            11           13                 45
## 19              14             8            7                 36
## 20              18            20           14                 66
## 21              14            12            9                 44
## 22              11            13           11                 46
read.csv("only_low_middle_level_only_value.csv") #Feedback(effort=1,performance=2)
##     ID feedback ITS class PreTest_Total_Score PostTest_Total_Score Post_Pre
## 1   33        1  12     1                  11                   11        0
## 2   40        1  12     2                  11                   12        1
## 3   74        1  12     3                  11                    3       -8
## 4   21        2  12     1                  11                   14        3
## 5   26        2  12     1                  11                   14        3
## 6   50        2  12     2                  11                   13        2
## 7   56        2  12     2                  11                   13        2
## 8   58        2  12     2                  11                   10       -1
## 9   96        2  12     3                  11                   13        2
## 10   8        1  10     1                  10                    8       -2
## 11  76        1  12     3                  10                   12        2
## 12  27        2  12     1                  10                   12        2
## 13  29        1  12     1                   9                   11        2
## 14  39        1  12     2                   9                    4       -5
## 15 100        1  12     3                   9                    6       -3
## 16  10        2  11     1                   9                   11        2
## 17  12        2  12     1                   9                    9        0
## 18  69        1  12     2                   8                   11        3
## 19  75        1  12     3                   8                    6       -2
## 20  15        2  12     1                   8                    8        0
## 21  49        2  12     2                   8                   11        3
## 22  91        2  12     3                   8                   12        4
## 23 102        1  12     3                   7                    2       -5
## 24  44        1  12     2                   5                    8        3
## 25  79        1  12     3                   5                   10        5
## 26  23        2  12     1                   5                    9        4
## 27  46        2  12     2                   5                    2       -3
## 28  93        2  12     3                   5                    8        3
## 29   5        1  12     1                   4                    6        2
## 30  34        1  12     1                   4                    3       -1
## 31   7        1  12     1                   3                    9        6
## 32  35        1  12     1                   3                   10        7
## 33  37        1  12     2                   3                    3        0
## 34  16        2  12     1                   3                    3        0
## 35  25        2  12     1                   3                    4        1
## 36  54        2  12     2                   3                   12        9
## 37  82        2  12     3                   3                    1       -2
## 38  41        1  12     2                   2                    1       -1
## 39  52        2  12     2                   2                    3        1
## 40  83        2  12     3                   2                   13       11
## 41 106        1  12     3                   1                    0       -1
## 42  13        2  12     1                   1                   14       13
##    Intrinsic_Value Self.regulation Self.efficacy Test_anxiety
## 1               15              16            17           13
## 2               13              19            17            5
## 3                5              10             6            6
## 4               12              15            12           12
## 5                7              14            11           13
## 6                7              14             8            7
## 7               14              18            20           14
## 8                9              14            12            9
## 9               11              11            13           11
## 10              13              16            17           15
## 11              13              16            15           12
## 12              12              14            11           12
## 13               8              11             9           15
## 14              15              18            14           12
## 15               9               8             7           12
## 16              13              18            16           15
## 17              11              15            15           16
## 18               5              15            11            7
## 19              10              11             9           14
## 20              11              15            15            4
## 21              15              17            16           17
## 22              12              14            17           14
## 23              12              18            17           15
## 24               8              11            12            8
## 25               8              14             7            7
## 26              14              13            11            5
## 27              10              16            11            4
## 28              13              17            15           16
## 29               6              11            12            7
## 30               6              12            11            7
## 31              10              15            12            9
## 32               9              13            14           14
## 33               6              15             6            4
## 34               9              13            10            8
## 35               7              14            13            9
## 36               7              13            12           13
## 37               4              17            11            4
## 38              11              16            16            4
## 39               8               7             5            5
## 40               3              11             4            5
## 41               6               9             9            9
## 42              14              17            17           15
##    Survey_Total_Score
## 1                  61
## 2                  54
## 3                  27
## 4                  51
## 5                  45
## 6                  36
## 7                  66
## 8                  44
## 9                  46
## 10                 61
## 11                 56
## 12                 49
## 13                 43
## 14                 59
## 15                 36
## 16                 62
## 17                 57
## 18                 38
## 19                 44
## 20                 45
## 21                 65
## 22                 57
## 23                 62
## 24                 39
## 25                 36
## 26                 43
## 27                 41
## 28                 61
## 29                 36
## 30                 36
## 31                 46
## 32                 50
## 33                 31
## 34                 40
## 35                 43
## 36                 45
## 37                 36
## 38                 47
## 39                 25
## 40                 23
## 41                 33
## 42                 63
setwd("/Users/satoushintarou/Desktop/Master thesis/大宮北小/Data") #Directory


datal<-read.csv("only_low_middle_level.csv") 
datale<-read.csv("only_low_middle_level_effort.csv") 
datalp<-read.csv("only_low_middle_level_performance.csv")
datalv<-read.csv("only_low_middle_level_only_value.csv")

#Students who Marked 0〜75 Percentile in the Pre-test

#Pre-Test 75 percentile = score "12"
read.csv("R.csv") #All students N=65
##     ID    username    feedback ITS pre_test_type post_test_type class
## 1    1      gocola      effort  12             B              A     1
## 2    4      goniku      effort  12             B              A     1
## 3    5      gosoba      effort  12             B              A     1
## 4    7    gotamago      effort  12             B              A     1
## 5    8      gotofu      effort  10             B              A     1
## 6   28     yescola      effort  12             A              B     1
## 7   29     yesfugu      effort  12             A              B     1
## 8   30     yesmiso      effort  12             A              B     1
## 9   31     yesniku      effort  12             A              B     1
## 10  33    yessushi      effort  12             A              B     1
## 11  34   yestamago      effort  12             A              B     1
## 12  35     yestofu      effort  12             A              B     1
## 13  37     gogyoza      effort  12             B              A     2
## 14  38       goika      effort  12             B              A     2
## 15  39      gokaki      effort  12             B              A     2
## 16  40   goonigiri      effort  12             B              A     2
## 17  41     goramen      effort  12             B              A     2
## 18  42    gosakana      effort  12             B              A     2
## 19  43      gotako      effort  12             B              A     2
## 20  44     gounagi      effort  12             B              A     2
## 21  45      goyuba      effort  12             B              A     2
## 22  69   yessakana      effort  12             A              B     2
## 23  74       goimo      effort  12             B              A     3
## 24  75      gonabe      effort  12             B              A     3
## 25  76    gonigiri      effort  12             B              A     3
## 26  77      goocha      effort  12             B              A     3
## 27  79     gosomen      effort  12             B              A     3
## 28 100      yesice      effort  12             A              B     3
## 29 101      yesimo      effort  12             A              B     3
## 30 102     yesnabe      effort  12             A              B     3
## 31 103   yesnigiri      effort  12             A              B     3
## 32 105     yessake      effort  12             A              B     3
## 33 106    yessomen      effort  12             A              B     3
## 34 107  yestaiyaki      effort  12             A              B     3
## 35  10    nicecola performance  11             A              B     1
## 36  12    nicemiso performance  12             A              B     1
## 37  13    niceniku performance  12             A              B     1
## 38  15   nicesushi performance  12             A              B     1
## 39  16  nicetamago performance  12             A              B     1
## 40  20      okfugu performance  12             B              A     1
## 41  21      okmiso performance  12             B              A     1
## 42  23      oksoba performance  12             B              A     1
## 43  25    oktamago performance  12             B              A     1
## 44  26      oktofu performance  12             B              A     1
## 45  27      okudon performance  12             B              A     1
## 46  46   nicegyoza performance  12             A              B     2
## 47  48    nicekaki performance  12             A              B     2
## 48  49 niceonigiri performance  12             A              B     2
## 49  50   niceramen performance  12             A              B     2
## 50  51  nicesakana performance  12             A              B     2
## 51  52    nicetako performance  12             A              B     2
## 52  53   niceunagi performance  12             A              B     2
## 53  54    niceyuba performance  12             A              B     2
## 54  56       okika performance  12             B              A     2
## 55  57      okkaki performance  12             B              A     2
## 56  58   okonigiri performance  12             B              A     2
## 57  62     okunagi performance  12             B              A     2
## 58  63      okyuba performance  12             B              A     2
## 59  82     niceice performance  12             A              B     3
## 60  83     niceimo performance  12             A              B     3
## 61  87    nicesake performance  12             A              B     3
## 62  91       okice performance  12             B              A     3
## 63  93      oknabe performance  12             B              A     3
## 64  96      oksake performance  12             B              A     3
## 65  98   oktaiyaki performance  12             B              A     3
##    PreTest_Total_Score PostTest_Total_Score Post_Pre Intrinsic_Value
## 1                   14                   14        0              15
## 2                   13                   12       -1              10
## 3                    4                    6        2               6
## 4                    3                    9        6              10
## 5                   10                    8       -2              13
## 6                   13                   14        1              11
## 7                    9                   11        2               8
## 8                   12                   14        2              14
## 9                   12                   11       -1               8
## 10                  11                   11        0              15
## 11                   4                    3       -1               6
## 12                   3                   10        7               9
## 13                   3                    3        0               6
## 14                  14                   14        0              15
## 15                   9                    4       -5              15
## 16                  11                   12        1              13
## 17                   2                    1       -1              11
## 18                  14                   14        0              14
## 19                  13                   13        0              12
## 20                   5                    8        3               8
## 21                  12                   12        0              13
## 22                   8                   11        3               5
## 23                  11                    3       -8               5
## 24                   8                    6       -2              10
## 25                  10                   12        2              13
## 26                  12                   10       -2              15
## 27                   5                   10        5               8
## 28                   9                    6       -3               9
## 29                  13                   13        0              11
## 30                   7                    2       -5              12
## 31                  13                   13        0              13
## 32                  12                   14        2              15
## 33                   1                    0       -1               6
## 34                  14                   13       -1              12
## 35                   9                   11        2              13
## 36                   9                    9        0              11
## 37                   1                   14       13              14
## 38                   8                    8        0              11
## 39                   3                    3        0               9
## 40                  13                   13        0              13
## 41                  11                   14        3              12
## 42                   5                    9        4              14
## 43                   3                    4        1               7
## 44                  11                   14        3               7
## 45                  10                   12        2              12
## 46                   5                    2       -3              10
## 47                  12                   13        1              15
## 48                   8                   11        3              15
## 49                  11                   13        2               7
## 50                  14                   14        0              11
## 51                   2                    3        1               8
## 52                  13                   12       -1              13
## 53                   3                   12        9               7
## 54                  11                   13        2              14
## 55                  13                   14        1              13
## 56                  11                   10       -1               9
## 57                  12                   12        0               7
## 58                  12                    6       -6              11
## 59                   3                    1       -2               4
## 60                   2                   13       11               3
## 61                  12                   12        0              12
## 62                   8                   12        4              12
## 63                   5                    8        3              13
## 64                  11                   13        2              11
## 65                  14                   14        0               8
##    Self.regulation Self.efficacy Test_anxiety Survey_Total_Score
## 1               19            20           14                 68
## 2               16            13            8                 47
## 3               11            12            7                 36
## 4               15            12            9                 46
## 5               16            17           15                 61
## 6               16            11            4                 42
## 7               11             9           15                 43
## 8               20            19           16                 69
## 9               13            12            8                 41
## 10              16            17           13                 61
## 11              12            11            7                 36
## 12              13            14           14                 50
## 13              15             6            4                 31
## 14              20            20            6                 61
## 15              18            14           12                 59
## 16              19            17            5                 54
## 17              16            16            4                 47
## 18              18            20           17                 69
## 19              11            16           10                 49
## 20              11            12            8                 39
## 21              13            20           20                 66
## 22              15            11            7                 38
## 23              10             6            6                 27
## 24              11             9           14                 44
## 25              16            15           12                 56
## 26              15            13            7                 50
## 27              14             7            7                 36
## 28               8             7           12                 36
## 29              11            16           14                 52
## 30              18            17           15                 62
## 31              16            16           15                 60
## 32              14            18           18                 65
## 33               9             9            9                 33
## 34              16            18           17                 63
## 35              18            16           15                 62
## 36              15            15           16                 57
## 37              17            17           15                 63
## 38              15            15            4                 45
## 39              13            10            8                 40
## 40              18            19           17                 67
## 41              15            12           12                 51
## 42              13            11            5                 43
## 43              14            13            9                 43
## 44              14            11           13                 45
## 45              14            11           12                 49
## 46              16            11            4                 41
## 47              16            18           15                 64
## 48              17            16           17                 65
## 49              14             8            7                 36
## 50              16            17           13                 57
## 51               7             5            5                 25
## 52              14            18           16                 61
## 53              13            12           13                 45
## 54              18            20           14                 66
## 55              19            18           10                 60
## 56              14            12            9                 44
## 57              14            12            7                 40
## 58              13            12           17                 53
## 59              17            11            4                 36
## 60              11             4            5                 23
## 61              19            15            8                 54
## 62              14            17           14                 57
## 63              17            15           16                 61
## 64              11            13           11                 46
## 65               7             5            8                 28
data<-read.csv("R.csv")

quantile(data$PreTest_Total_Score)
##   0%  25%  50%  75% 100% 
##    1    5   10   12   14
summary(data$PreTest_Total_Score)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##   1.000   5.000  10.000   8.908  12.000  14.000

#Demographic

#Students who Marked 0〜75 Percentile in the Pre-test (N=42)
table(datal$feedback)
## 
##      effort performance 
##          20          22

#Analysis 7 #Compare Pre- vs. Post-Test #Only Middle and Low Level Students (N=42)

#Comment:This result is the same as all students (N=65), Analysis 1.

#T-test 
#Pre-test and Post-test
#p-value = 0.02167
t.test(datal$PreTest_Total_Score, datal$PostTest_Total_Score, paired=TRUE)
## 
##  Paired t-test
## 
## data:  datal$PreTest_Total_Score and datal$PostTest_Total_Score
## t = -2.3872, df = 41, p-value = 0.02167
## alternative hypothesis: true mean difference is not equal to 0
## 95 percent confidence interval:
##  -2.7250286 -0.2273524
## sample estimates:
## mean difference 
##        -1.47619

#Analysis 8 #Compare Pre-Test / Effort vs. Performance Group #Compare Post-Test / Effort vs. Performance Group #Only Middle and Low Level Students (N=42)

#Comment:There is a significant difference, "Post-test between the effort and performance group"(p-value = 0.03929). This is not the case for all students (N=65), Analysis2.


#T-test
#Pre-test between the effort and performance group
#p-value = 0.8772
var.test(datale$PreTest_Total_Score,datalp$PreTest_Total_Score)
## 
##  F test to compare two variances
## 
## data:  datale$PreTest_Total_Score and datalp$PreTest_Total_Score
## F = 0.84727, num df = 19, denom df = 21, p-value = 0.7209
## alternative hypothesis: true ratio of variances is not equal to 1
## 95 percent confidence interval:
##  0.3468983 2.1121928
## sample estimates:
## ratio of variances 
##          0.8472657
t.test(PreTest_Total_Score ~ feedback, var.equal=T,data = datal)
## 
##  Two Sample t-test
## 
## data:  PreTest_Total_Score by feedback
## t = -0.15556, df = 40, p-value = 0.8772
## alternative hypothesis: true difference in means between group effort and group performance is not equal to 0
## 95 percent confidence interval:
##  -2.353277  2.016913
## sample estimates:
##      mean in group effort mean in group performance 
##                  6.650000                  6.818182
#T-test
#Post-test between the effort and performance group
#p-value = 0.03929
var.test(datale$PostTest_Total_Score,datalp$PostTest_Total_Score)
## 
##  F test to compare two variances
## 
## data:  datale$PostTest_Total_Score and datalp$PostTest_Total_Score
## F = 0.84365, num df = 19, denom df = 21, p-value = 0.7138
## alternative hypothesis: true ratio of variances is not equal to 1
## 95 percent confidence interval:
##  0.345418 2.103180
## sample estimates:
## ratio of variances 
##          0.8436504
t.test(PostTest_Total_Score ~ feedback, var.equal=T,data = datal)
## 
##  Two Sample t-test
## 
## data:  PostTest_Total_Score by feedback
## t = -2.131, df = 40, p-value = 0.03929
## alternative hypothesis: true difference in means between group effort and group performance is not equal to 0
## 95 percent confidence interval:
##  -5.2607167 -0.1392833
## sample estimates:
##      mean in group effort mean in group performance 
##                       6.8                       9.5

#Analysis 9 #Compare Test Score Increase (増加量) / Effort vs. Performance Group #Only Middle and Low Level Students (N=42)

#Comment:This result is the same as all students (N=65), Analysis 3.
#T-test
#Post_Pre[(Post_Test_Total_Score)ー(Pre_Test_Total_Score)] between the effort and performance group 
#p-value = 0.03926
var.test(datal$Post_Pre,datal$Post_Pre)
## 
##  F test to compare two variances
## 
## data:  datal$Post_Pre and datal$Post_Pre
## F = 1, num df = 41, denom df = 41, p-value = 1
## alternative hypothesis: true ratio of variances is not equal to 1
## 95 percent confidence interval:
##  0.5375237 1.8603832
## sample estimates:
## ratio of variances 
##                  1
t.test(Post_Pre ~ feedback,var.equal=T,data = datal)
## 
##  Two Sample t-test
## 
## data:  Post_Pre by feedback
## t = -2.1313, df = 40, p-value = 0.03926
## alternative hypothesis: true difference in means between group effort and group performance is not equal to 0
## 95 percent confidence interval:
##  -4.9326576 -0.1309788
## sample estimates:
##      mean in group effort mean in group performance 
##                  0.150000                  2.681818

#Analysis 10 #Regression Model #Only Middle and Low Level Students (N=42)

#Comment:???

#y="Post-test", x="Feedback type" and "Pre-test"
model5 <- lm(PostTest_Total_Score ~ feedback*PreTest_Total_Score, data = datal)
summary(model5)
## 
## Call:
## lm(formula = PostTest_Total_Score ~ feedback * PreTest_Total_Score, 
##     data = datal)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -6.3787 -2.3356  0.5795  2.0475  8.0882 
## 
## Coefficients:
##                                         Estimate Std. Error t value Pr(>|t|)  
## (Intercept)                              3.21454    1.85270   1.735   0.0908 .
## feedbackperformance                      2.08054    2.50344   0.831   0.4111  
## PreTest_Total_Score                      0.53917    0.25016   2.155   0.0375 *
## feedbackperformance:PreTest_Total_Score  0.07755    0.33249   0.233   0.8168  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 3.647 on 38 degrees of freedom
## Multiple R-squared:  0.3252, Adjusted R-squared:  0.272 
## F-statistic: 6.105 on 3 and 38 DF,  p-value: 0.001704
model6 <- lm(PostTest_Total_Score ~ feedback+PreTest_Total_Score, data = datal)
summary(model6)
## 
## Call:
## lm(formula = PostTest_Total_Score ~ feedback + PreTest_Total_Score, 
##     data = datal)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -6.4399 -2.2384  0.6025  2.1370  7.8924 
## 
## Coefficients:
##                     Estimate Std. Error t value Pr(>|t|)    
## (Intercept)           2.9226     1.3493   2.166 0.036490 *  
## feedbackperformance   2.6019     1.1134   2.337 0.024670 *  
## PreTest_Total_Score   0.5831     0.1628   3.582 0.000934 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 3.603 on 39 degrees of freedom
## Multiple R-squared:  0.3243, Adjusted R-squared:  0.2896 
## F-statistic: 9.357 on 2 and 39 DF,  p-value: 0.0004794
library(ggplot2)  
ggplot(datal, aes(x = PreTest_Total_Score, y =  Post_Pre, col = feedback)) + geom_point() +geom_smooth(method = "lm",se=FALSE)
## `geom_smooth()` using formula = 'y ~ x'

#y="Score Increase(増加量)", x="Feedback type" and "Pre-test"
model7 <- lm(Post_Pre ~ feedback*PreTest_Total_Score, data = datal)
summary(model7)
## 
## Call:
## lm(formula = Post_Pre ~ feedback * PreTest_Total_Score, data = datal)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -6.3787 -2.3356  0.5795  2.0475  8.0882 
## 
## Coefficients:
##                                         Estimate Std. Error t value Pr(>|t|)  
## (Intercept)                              3.21454    1.85270   1.735   0.0908 .
## feedbackperformance                      2.08054    2.50344   0.831   0.4111  
## PreTest_Total_Score                     -0.46083    0.25016  -1.842   0.0733 .
## feedbackperformance:PreTest_Total_Score  0.07755    0.33249   0.233   0.8168  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 3.647 on 38 degrees of freedom
## Multiple R-squared:  0.2324, Adjusted R-squared:  0.1718 
## F-statistic: 3.835 on 3 and 38 DF,  p-value: 0.01711
model8 <- lm(Post_Pre ~ feedback+PreTest_Total_Score, data = datal)
summary(model8)
## 
## Call:
## lm(formula = Post_Pre ~ feedback + PreTest_Total_Score, data = datal)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -6.4399 -2.2384  0.6025  2.1370  7.8924 
## 
## Coefficients:
##                     Estimate Std. Error t value Pr(>|t|)  
## (Intercept)           2.9226     1.3493   2.166   0.0365 *
## feedbackperformance   2.6019     1.1134   2.337   0.0247 *
## PreTest_Total_Score  -0.4169     0.1628  -2.561   0.0144 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 3.603 on 39 degrees of freedom
## Multiple R-squared:  0.2313, Adjusted R-squared:  0.1919 
## F-statistic: 5.867 on 2 and 39 DF,  p-value: 0.00592
library(ggplot2)  
ggplot(datal, aes(x = PreTest_Total_Score, y =  PostTest_Total_Score, col = feedback)) + geom_point() +geom_smooth(method = "lm",se=FALSE)
## `geom_smooth()` using formula = 'y ~ x'

#Analysis 11 #Compare Math Motivation Score (算数学習への意欲) / Effort vs. Performance Group #Only Middle and Low Level Students (N=42)

#Comment:This result is the same as all students (N=65), Analysis 5.

#T-test
#Math motivation score between the effort and performance group
#p-value = 0.4601
var.test(datale$Survey_Total_Score,datalp$Survey_Total_Score)#等分散
## 
##  F test to compare two variances
## 
## data:  datale$Survey_Total_Score and datalp$Survey_Total_Score
## F = 0.84405, num df = 19, denom df = 21, p-value = 0.7146
## alternative hypothesis: true ratio of variances is not equal to 1
## 95 percent confidence interval:
##  0.3455823 2.1041802
## sample estimates:
## ratio of variances 
##          0.8440517
t.test(Survey_Total_Score ~ feedback,var.equal=T,data = datal)
## 
##  Two Sample t-test
## 
## data:  Survey_Total_Score by feedback
## t = -0.74594, df = 40, p-value = 0.4601
## alternative hypothesis: true difference in means between group effort and group performance is not equal to 0
## 95 percent confidence interval:
##  -9.863750  4.545568
## sample estimates:
##      mean in group effort mean in group performance 
##                  44.75000                  47.40909
#T-test
#Intrinsic value between the effort and performance group
#p-value = 0.4742 
var.test(datale$Intrinsic_Value,datalp$Intrinsic_Value)#等分散
## 
##  F test to compare two variances
## 
## data:  datale$Intrinsic_Value and datalp$Intrinsic_Value
## F = 0.9637, num df = 19, denom df = 21, p-value = 0.941
## alternative hypothesis: true ratio of variances is not equal to 1
## 95 percent confidence interval:
##  0.3945694 2.4024525
## sample estimates:
## ratio of variances 
##          0.9636979
t.test(Intrinsic_Value ~ feedback,var.equal=T,data = datal)
## 
##  Two Sample t-test
## 
## data:  Intrinsic_Value by feedback
## t = -0.72241, df = 40, p-value = 0.4742
## alternative hypothesis: true difference in means between group effort and group performance is not equal to 0
## 95 percent confidence interval:
##  -2.796474  1.323747
## sample estimates:
##      mean in group effort mean in group performance 
##                   9.40000                  10.13636
#T-test
#Self efficacy between the effort and performance group
#p-value = 0.6163  
var.test(datale$Self.efficacy,datalp$Self.efficacy)#等分散
## 
##  F test to compare two variances
## 
## data:  datale$Self.efficacy and datalp$Self.efficacy
## F = 1.0201, num df = 19, denom df = 21, p-value = 0.959
## alternative hypothesis: true ratio of variances is not equal to 1
## 95 percent confidence interval:
##  0.4176529 2.5430030
## sample estimates:
## ratio of variances 
##           1.020077
t.test(Self.efficacy ~ feedback,var.equal=T,data = datal)
## 
##  Two Sample t-test
## 
## data:  Self.efficacy by feedback
## t = -0.5051, df = 40, p-value = 0.6163
## alternative hypothesis: true difference in means between group effort and group performance is not equal to 0
## 95 percent confidence interval:
##  -3.000793  1.800793
## sample estimates:
##      mean in group effort mean in group performance 
##                      11.9                      12.5
#T-test
#Self regulation between the effort and performance group
#p-value = 0.4314 
var.test(datale$Self.regulation,datalp$Self.regulation)#等分散
## 
##  F test to compare two variances
## 
## data:  datale$Self.regulation and datalp$Self.regulation
## F = 1.5032, num df = 19, denom df = 21, p-value = 0.3647
## alternative hypothesis: true ratio of variances is not equal to 1
## 95 percent confidence interval:
##  0.6154652 3.7474422
## sample estimates:
## ratio of variances 
##           1.503215
t.test(Self.regulation ~ feedback,var.equal=T,data = datal)
## 
##  Two Sample t-test
## 
## data:  Self.regulation by feedback
## t = -0.79483, df = 40, p-value = 0.4314
## alternative hypothesis: true difference in means between group effort and group performance is not equal to 0
## 95 percent confidence interval:
##  -2.512153  1.093971
## sample estimates:
##      mean in group effort mean in group performance 
##                  13.70000                  14.40909
#T-test
#Anxiety between the effort and performance group
#p-value = 0.6392 
var.test(datale$Test_anxiety,datalp$Test_anxiety)#等分散
## 
##  F test to compare two variances
## 
## data:  datale$Test_anxiety and datalp$Test_anxiety
## F = 0.73257, num df = 19, denom df = 21, p-value = 0.4992
## alternative hypothesis: true ratio of variances is not equal to 1
## 95 percent confidence interval:
##  0.2999372 1.8262562
## sample estimates:
## ratio of variances 
##          0.7325678
t.test(Test_anxiety ~ feedback,var.equal=T,data = datal)
## 
##  Two Sample t-test
## 
## data:  Test_anxiety by feedback
## t = -0.47248, df = 40, p-value = 0.6392
## alternative hypothesis: true difference in means between group effort and group performance is not equal to 0
## 95 percent confidence interval:
##  -3.238530  2.011257
## sample estimates:
##      mean in group effort mean in group performance 
##                   9.75000                  10.36364

#Analysis 12 #Correlation #Only Middle and Low Level Students (N=42)

library(corrplot)
## corrplot 0.92 loaded
round(cor(datalv),2)
##                         ID feedback   ITS class PreTest_Total_Score
## ID                    1.00    -0.11  0.28  0.94                0.01
## feedback             -0.11     1.00  0.08 -0.14                0.02
## ITS                   0.28     0.08  1.00  0.23               -0.18
## class                 0.94    -0.14  0.23  1.00                0.00
## PreTest_Total_Score   0.01     0.02 -0.18  0.00                1.00
## PostTest_Total_Score -0.16     0.32 -0.04 -0.20                0.48
## Post_Pre             -0.18     0.32  0.11 -0.21               -0.35
## Intrinsic_Value      -0.21     0.11 -0.21 -0.20                0.38
## Self.regulation      -0.23     0.12 -0.19 -0.16                0.23
## Self.efficacy        -0.23     0.08 -0.25 -0.25                0.27
## Test_anxiety          0.00     0.07 -0.25 -0.10                0.35
## Survey_Total_Score   -0.20     0.12 -0.28 -0.21                0.38
##                      PostTest_Total_Score Post_Pre Intrinsic_Value
## ID                                  -0.16    -0.18           -0.21
## feedback                             0.32     0.32            0.11
## ITS                                 -0.04     0.11           -0.21
## class                               -0.20    -0.21           -0.20
## PreTest_Total_Score                  0.48    -0.35            0.38
## PostTest_Total_Score                 1.00     0.65            0.30
## Post_Pre                             0.65     1.00           -0.01
## Intrinsic_Value                      0.30    -0.01            1.00
## Self.regulation                      0.20     0.02            0.57
## Self.efficacy                        0.26     0.04            0.74
## Test_anxiety                         0.42     0.15            0.53
## Survey_Total_Score                   0.37     0.07            0.86
##                      Self.regulation Self.efficacy Test_anxiety
## ID                             -0.23         -0.23         0.00
## feedback                        0.12          0.08         0.07
## ITS                            -0.19         -0.25        -0.25
## class                          -0.16         -0.25        -0.10
## PreTest_Total_Score             0.23          0.27         0.35
## PostTest_Total_Score            0.20          0.26         0.42
## Post_Pre                        0.02          0.04         0.15
## Intrinsic_Value                 0.57          0.74         0.53
## Self.regulation                 1.00          0.72         0.23
## Self.efficacy                   0.72          1.00         0.50
## Test_anxiety                    0.23          0.50         1.00
## Survey_Total_Score              0.74          0.91         0.74
##                      Survey_Total_Score
## ID                                -0.20
## feedback                           0.12
## ITS                               -0.28
## class                             -0.21
## PreTest_Total_Score                0.38
## PostTest_Total_Score               0.37
## Post_Pre                           0.07
## Intrinsic_Value                    0.86
## Self.regulation                    0.74
## Self.efficacy                      0.91
## Test_anxiety                       0.74
## Survey_Total_Score                 1.00
cor_matrix<-round(cor(datalv),2)
corrplot(corr=cor_matrix)

#Comment: "Self efficacy × Post-test" and "Self regulation × Post-test" is a significant correlation in the case of all students (N=65), but it is not here.

##Significant Correlation##

#Pre-Test × Post-Test
#pp-value = 0.001324, cor 0.4792036
cor.test(datal$PreTest_Total_Score,datal$PostTest_Total_Score)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$PreTest_Total_Score and datal$PostTest_Total_Score
## t = 3.453, df = 40, p-value = 0.001324
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  0.2051516 0.6835756
## sample estimates:
##       cor 
## 0.4792036
#Math Motivation Score × Pre-test
#p-value = 0.01315, cor 0.3796418
cor.test(datal$Survey_Total_Score,datal$PreTest_Total_Score)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Survey_Total_Score and datal$PreTest_Total_Score
## t = 2.5954, df = 40, p-value = 0.01315
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  0.08558573 0.61285844
## sample estimates:
##       cor 
## 0.3796418
#Math Motivation Score × Post-test
#p-value = 0.01461, cor 0.3742882
cor.test(datal$Survey_Total_Score,datal$PostTest_Total_Score)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Survey_Total_Score and datal$PostTest_Total_Score
## t = 2.5528, df = 40, p-value = 0.01461
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  0.07938783 0.60894701
## sample estimates:
##       cor 
## 0.3742882
#Intrinsic value × Post-test
#p-value = 0.05005, cor 0.3043299
cor.test(datal$Intrinsic_Value,datal$PostTest_Total_Score)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Intrinsic_Value and datal$PostTest_Total_Score
## t = 2.0206, df = 40, p-value = 0.05005
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  0.0004391956 0.5567632484
## sample estimates:
##       cor 
## 0.3043299
#Test anxiety × Post-test
#p-value = 0.005469, cor 0.4212233
cor.test(datal$Test_anxiety,datal$PostTest_Total_Score)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Test_anxiety and datal$PostTest_Total_Score
## t = 2.9373, df = 40, p-value = 0.005469
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  0.1345126 0.6428545
## sample estimates:
##       cor 
## 0.4212233
##No significant##

#Self efficacy × Post-test
#p-value = p-value = 0.1014, cor 0.2562308/a significant correlation in the case of all students (N=65).
cor.test(datal$Self.efficacy,datal$PostTest_Total_Score)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Self.efficacy and datal$PostTest_Total_Score
## t = 1.6765, df = 40, p-value = 0.1014
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.05172905  0.51969044
## sample estimates:
##       cor 
## 0.2562308
#Self regulation × Post-test
#p-value = 0.2106, cor 0.1972309/a significant correlation in the case of all students (N=65).
cor.test(datal$Self.regulation,datal$PostTest_Total_Score)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Self.regulation and datal$PostTest_Total_Score
## t = 1.2724, df = 40, p-value = 0.2106
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.1135045  0.4728193
## sample estimates:
##       cor 
## 0.1972309
#Math motivation score × Score increase(増加量)
cor.test(datal$Survey_Total_Score,datal$Post_Pre)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Survey_Total_Score and datal$Post_Pre
## t = 0.45447, df = 40, p-value = 0.6519
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.2374297  0.3675975
## sample estimates:
##        cor 
## 0.07167384
#Intrinsic value × Score increase
cor.test(datal$Intrinsic_Value,datal$Post_Pre)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Intrinsic_Value and datal$Post_Pre
## t = -0.04359, df = 40, p-value = 0.9654
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.3101737  0.2976628
## sample estimates:
##          cor 
## -0.006892088
#Self efficacy × Score increase
cor.test(datal$Self.efficacy,datal$Post_Pre)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Self.efficacy and datal$Post_Pre
## t = 0.28029, df = 40, p-value = 0.7807
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.2631990  0.3435821
## sample estimates:
##        cor 
## 0.04427403
#Self regulation × Score increase
cor.test(datal$Self.regulation,datal$Post_Pre)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Self.regulation and datal$Post_Pre
## t = 0.1014, df = 40, p-value = 0.9197
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.2893105  0.3184104
## sample estimates:
##        cor 
## 0.01603043
#Test anxiety × Score increase
cor.test(datal$Test_anxiety,datal$Post_Pre)
## 
##  Pearson's product-moment correlation
## 
## data:  datal$Test_anxiety and datal$Post_Pre
## t = 0.96865, df = 40, p-value = 0.3385
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.1598975  0.4352936
## sample estimates:
##       cor 
## 0.1513912