1 Introduction

In the USA, by 2018, 51% of science, technology, engineering, and mathematics (STEM) professions will be in computer science and information and communication technologies (ICTs) (Carnevale et al. 2011; US National Science Foundation 2016). As a result, national efforts have been designed to provide computer-science education to all students to prepare them for STEM-related employment (US National Science Foundation 2016). The growth of computer-science education and the forecast relevance of ICT-related employment are not only specific to the USA but also to the European Union, Australia, and Asia (Australian Computer Society 2016; Chen and Soldner 2013; EU-Japan Centre for Industrial Cooperation 2015; EU SME Centre 2015; Simon 2012; Statistical Office of the European Union 2017; US National Science Foundation 2016). However, in spite of this need for ICT professionals, the number of students who actually succeed in computer-science courses falls short of meeting employment needs (Chen and Soldner 2013; Rosson et al. 2011). Attrition rates in computer-science courses tend to be high among students with weaker academic backgrounds (i.e., poor math skills and problem-solving abilities) (Beaubouef and Mason 2005; Beaubouef and McDowell 2008) and among students with low motivation (Beaubouef and Zhang 2011), attitude (Sam et al. 2005), confidence (Giannakos et al. 2012), or beliefs about their own competence to learn (Lopez et al. 2006; Rosson et al. 2011).

1.1 Students’ self-efficacy beliefs, achievement, and motivation

Motivation and success in computer-science courses are also determined by students’ self-efficacy (SE) beliefs in their learning abilities (Ramalingam et al. 2004; Rosson et al. 2011). Students with weak SE may struggle to be successful in a computer-science program (Beaubouef and McDowell 2008; Vivian et al. 2013). Weak SE beliefs affect students’ attention, engagement, and effort to successfully complete computer tasks (Hasan 2003). Beliefs about one’s skills and abilities to regulate learning activities and master difficult and challenging specific tasks in ICT, computer programming or problem-solving (Hasan 2003; Wang and Neihart 2015) are referred to as computer self-efficacy (CSE) beliefs (Johnson 2005; Rosson et al. 2011).

In addition, students’ achievement and motivation are also affected by students’ perception of the classroom environment in which they learn (Meece et al. 2006). The classroom is “a social and learning environment” that helps students shape their attitudes and feelings (Koul et al. 2012, p.218). Students’ perceptions of the classroom learning environment (CLE) and their interaction with instructors influence their intrinsic motivation (Urdan and Schoenfelder 2006; Van Dinther et al. 2011), levels of SE (Alt 2015; Dorman 2001), achievement (Ryan et al. 2000; Wolf and Fraser 2007), learning outcomes (Lai et al. 2015; Lüdtke et al. 2009), and school engagement (Opdenakker and Minnaert 2011; Ryan and Patrick 2001). Three effective aspects of a supportive CLE are meaningfulness (assimilation with new knowledge into the existing knowledge in memory), autonomy (opportunities to select and control learning), and involvement (participation in classroom learning activity) (Koul et al. 2012). Moreover, SE is formed by how students perceive information from their interpretation of past experiences, observation of others’ activities, receiving encouraging feedback and judgment, and physiological arousal and affective states (Chen and Usher 2013). Information sources of SE relate to social persuasions, physiological and affective states, and vicarious experiences (Usher and Pajares 2009). Social persuasions refer to how meaningful and encouraging feedback or judgment from influential people such as teachers may boost students’ SE (Chen and Usher 2013). Vicarious experiences involve students determining and comparing their own abilities with observational experiences of role models such as peers and teachers (Hodges and Murphy 2009). Physiological and affective states such as mood, physical strength, distress levels, and arousal can affect students’ levels of SE (Chen and Usher 2013; Hodges and Murphy 2009; Usher and Pajares 2008). In particular, increasing students’ physical and emotional well-being help students reduce their negative affective states and strengthen their SE levels (Usher and Pajares 2008).

1.2 Previous studies of the influences on CSE

According to Bandura (1997) and Schunk and Pajares (2001), there are antecedent factors (i.e., information sources of SE) related to the development of SE. Chen and Usher’s (2013) study of the information sources of SE demonstrated there was a relationship between information sources and SE outcomes. This relationship confirmed that levels of SE were regressed by such sources. Many studies have been conducted on information sources of SE and SE within the different domains, academic levels, and groups of students (Moos and Azevedo 2009; Usher and Pajares 2008). Some studies have explored the relationships between SE and sources of SE in science (Chen and Usher 2013) and mathematics (Hodges and Murphy 2009; Usher and Pajares 2009). However, the review conducted for the present study revealed little research investigating the relationships among CSE, information sources of SE constructs, and CLE in computer-science education (Moos and Azevedo 2009; Van Dinther et al. 2011). The studies identified separated the investigation of the relationship between CSE or SE and CLE, and information sources of SE (e.g., Chen and Usher 2013; Diseth 2011; Durndell and Haag 2002; Hasan 2003; Lin et al. 2013; Morin et al. 2014; Ryan and Patrick 2001; Van Dinther et al. 2011; Veilleux et al. 2013; Zhang 2014). These studies rarely focused on how students’ perceptions of their CLE contribute to information sources of SE and influence their CSE. Figure 1 summarizes the approaches of researchers to the study of influences of CLE and information sources of SE on CSE.

Fig. 1
figure 1

Approaches to the study of CSE

1.3 Purpose and research questions

This typical approach to the study of CSE does not recognize the complexity of the interplay of factors in contexts of learning. Hsu and Huang (2006) examined home and school computer learning environments, motivation, and CSE. However, their study did not focus on more specific aspects of CLE (meaningfulness, autonomy, and involvement). Additionally, Moos and Azevedo (2009) identified the need for more research on how information sources of SE influence the development of CSE. The research reported in this paper aimed to address these gaps in the literature. The purpose of the present study was to investigate the interactions between multiple variables of CLE (e.g., meaningfulness, autonomy, and involvement), information sources of SE (e.g., social persuasions, physiological and affective states, and vicarious experiences), and the strength of CSE. It was beyond the scope of the present study to focus on CSE outcomes such as achievement. High (strong) CSE is positively associated with achievement and positive learning outcomes. What is important to determine is the complex factors related to CLE and information sources that interplay and influence the strength of CSE. The specific questions addressed by the study were as follows:

  1. 1.

    What is the relationship between the perceived CLE, information sources of SE, and the strength of CSE beliefs of undergraduate computer-science students?

  2. 2.

    What combination of the aspects of CLE (meaningfulness, autonomy, and involvement) and information sources of SE (social persuasions, physiological and affective states, and vicarious experiences) best predict the strength of the CSE beliefs of undergraduate computer-science students?

2 Conceptual framework

This section provides a more in-depth overview of the concepts investigated in the present study. The framework provides an overview of CSE, CLE, and information sources of SE. The section also summarizes what is known about the relationship between CLE and CSE. The last section presents a general review of the relationship between information sources of SE and CSE.

2.1 CSE

CSE is “a specific type of SE” (Sam et al. 2005, p.206) derived from Bandura’s (1986) Social Cognitive Theory. CSE is defined as an individual or personal judgment of one’s capabilities in computer use (Compeau and Higgins 1995). Judgment does not refer to what has occurred in the past, but rather to what can be done in the future (Compeau and Higgins 1995). Moreover, CSE refers to an individual’s confidence in his or her abilities to use computers and acquire computer skills easily (Robinson 2008). The strength of CSE relates to an individual’s confidence regarding his or her abilities to accomplish more specific or difficult computer-related tasks (Compeau and Higgins 1995; Moos and Azevedo 2009). In contrast, students’ low confidence in their computer-related abilities might result in poor performance on computer-based tasks (Sam et al. 2005). For example, Wardley and Mang (2015) found that students’ high SE levels in computer and technology were related to positive views of their abilities to learn new technologies. Alexander and Twinomurinzi (2012) reported that large numbers of first-year computing course students did not pursue a computing major because of a lack of confidence in their computer abilities. In computer science, CSE had been associated with students’ achievement, motivation, and outcome expectations (Hsu and Huang 2006; Ramalingam et al. 2004; Zingaro 2014). CSE plays a vital role in students’ perceptions of their abilities to perform computer tasks successfully (Akinbobola and Adeleke 2013; Wilfong 2006). Existing studies of CSE revealed that high CSE influences students’ confidence in their computer abilities (Akinbobola and Adeleke 2013), their ICT use (Van Acker et al. 2013), their learning and skills with ICTs (Çelik 2015), programming abilities (Kinnunen and Simon 2011; Marsh 2010), their program persistence (Kinnunen and Simon 2011), and their learning outcomes (Moos and Azevedo 2009;Ramalingam et al. 2004; Zingaro 2014). In addition, high CSE can lead students to accomplish difficult tasks and perform successfully in work and learning environments (Lin et al. 2013; Moos and Azevedo 2009; Sam et al. 2005).

2.2 CLE

The CLE not only influences students’ academic achievement and engagement, but also their motivation and perceptions (Meece et al. 2006; Opdenakker and Minnaert 2011). The components of the CLE that teachers provide may influence students’ perceptions of positive or negative levels of SE (Linnenbrink and Pintrich 2003). Three aspects of CLE including meaningfulness, autonomy, and involvement can effectively contribute to students’ SE (Nichols 2006; Robertson and Al-Zahrani 2012). Koul et al. (2012) recommended that teachers should engage students with classroom activities that are meaningful and autonomous, rather than competitive. Previous studies have reported that competitive CLEs lead to students’ low SE. These studies focused on grading (Meece et al. 2006), social comparison, less teacher attention, low perceived value of school learning (Schunk and Pajares 2001), and stress (Kinnunen and Simon 2011). In contrast, autonomous learning that involves students’ interactions in learning activities tends to increase students’ level of SE (Urdan and Schoenfelder 2006; Vandewaetere and Clarebout 2011). Meaningful CLE helps students to maintain their positive efficacy (Fast et al. 2010; Pajares and Urdan 2006).

2.3 Information sources of SE

Individual perceptions of SE depend on various personal interpretations of information sources of SE. (e.g., mastery experiences, social persuasions, physiological and affective states, and vicarious experiences) (Schunk and Pajares 2001). Mastery experiences related to success from personal past performance (e.g., individuals who completed difficult tasks or overcame major obstacles) will increase the level of SE beliefs (Bandura 1997). In contrast, failure from past experiences will negatively affect the strength of individual SE, or contribute to a decrease in the level of SE beliefs (Hodges and Murphy 2009). Examples of individuals’ past performances include, but are not limited to factors such as grade point average (GPA), exam score, and task completion (Usher and Pajares 2009). Evidence from prior studies revealed that mastery experiences do not significantly influence students’ SE if the students had limited success in their past performance (Britner and Pajares 2006; Tzeng 2009). Social persuasions and vicarious experiences, however, represent two important sources of SE when students had previously experienced limited success (Zeldin and Pajares 2000). For this reason, the present study does not focus on mastery experiences and is limited to a focus on social persuasions, physiological and affective states, and vicarious experiences sources of SE.

Vicarious experiences refer to creating SE from observational experiences of role models (Usher and Pajares 2008). Students determine their own abilities by observing and comparing themselves with their role models (e.g., peer, teachers, and adults), especially with people who have a similar profile or background (Van Dinther et al. 2011). The success or failure of role models performing tasks can alter students’ SE levels (Bandura 1997; Hodges and Murphy 2009). Vicarious experiences are sensitive to students who have few mastery experiences (Bandura 1997). Social persuasions that involve meaningful and encouraging feedback/judgments from influential people (e.g., teachers, and peers) especially in difficult circumstances, help students boost their SE to perform academic tasks (Chen and Usher 2013). Social persuasions contribute to a persistent sense of SE when significant people persuade students that they are capable of completing their work (Van Dinther et al. 2011).

Physiological and affective states encompass emotions, anxiety, stress, fatigue, mood, and arousal (Chen and Usher 2013; Hodges and Murphy 2009). Positive mood states help students enhance their SE. In contrast, negative emotions and feelings diminish students’ level of SE beliefs (Van Dinther et al. 2011). Students with low levels of confidence to take actions may have poor performance and low learning outcomes (Britner and Pajares 2006).

2.4 The relationship between CLE and CSE

Students’ perceptions of their CLE are positively associated with learning outcomes (Fraser 2002; Wolf and Fraser 2007), and with SE beliefs (Dorman 2001; Schunk and Pajares 2001). For example, Giannakos et al. (2012) emphasized that a supportive CLE increased students’ SE levels and students’ confidence in computer science. Autonomy positively influences students’ SE beliefs (Schunk and Pajares 2001). Wong et al. (2006) found that there were significant differences between students’ and teachers’ perceptions of the computer-supported learning environment. Moreover, Sheard et al. (2010) identified a difference between computer-science students’ and teachers’ perceptions of a preferred classroom. Students, especially junior students, prefer to learn in an interactive environment and have autonomy over their learning (Lin et al. 2013). An autonomous CLE may help predict students’ SE in computer-science learning. In fact, Montgomery et al. (2004) found that student involvement in interactive ICT learning environments may be associated with their levels of ICT competence. Tzeng (2009) and Howland et al. (2012) posited that meaningful learning was essential to construct students’ knowledge from computer technology.

2.5 The relationship between information sources of SE and CSE

Students’ perceptions of information sources of SE (e.g., social persuasions, physiological and affective states, and vicarious experiences) determine students’ SE (Britner and Pajares 2006; Wilfong 2006). Social persuasions and vicarious experiences are two important sources of SE especially when students have limited prior experience (Britner and Pajares 2006; Tzeng 2009; Zeldin and Pajares 2000). Meaningful and encouraging feedback helps students perform academic tasks particularly in difficult circumstances (Chen and Usher 2013). Zeldin and Pajares (2000) found that, especially for female students, use of social modeling developed their SE within male-oriented domains. Moreover, Anderson (2000) found that students mastered learning activities after social persuasions and vicarious experiences were used to mediate their levels of SE. Ramalingam et al. (2004) made two recommendations to help students improve their CSE in programming courses: (1) give more short and frequent assignments and abundant feedback during group work interactions, instead of a small number of long project assignments, (2) use social modeling to demonstrate how to handle a complex program or difficult tasks. Koh and Frick (2009) found that a social persuasive source was linked to increases in students’ CSE beliefs. In contrast, high computer anxiety and anger may have a negative association with CSE (Hauser et al. 2012; Johnson 2005; Wilfong 2006).

3 Review of the literature

This literature review presents an overview of studies most similar to the one presented in this paper.

3.1 Prior studies

There have been many studies of SE but with different influencing factors. These include prior experiences (Hasan 2003), attitude (Carroll et al. 2005; Celik and Yesilyurt 2013) anxiety (Durndell and Haag 2002; Hauser et al. 2012; Saadé and Kira 2009), gender (Deechuay et al. 2016; Marsh 2010; Rosson et al. 2011; Zingaro 2014), sense of belonging (Veilleux et al. 2013), various aspects of preferred learning environments (Lin et al. 2013), and the diversity of information sources of SE (Hodges and Murphy 2009). In addition, studies have examined various levels of education such as primary (Morin et al. 2014), secondary (Bassi et al. 2007; Britner and Pajares 2006; Ryan and Patrick 2001), high school (Papastergiou 2008), and undergraduate (Durndell and Haag 2002; Hasan 2003; Kerr et al. 2006; Veilleux et al. 2013). Research has focused on communities of computing (Carroll et al. 2005) and professionals (Zeldin and Pajares 2000) and on a variety of subject areas including mathematics (Hodges and Murphy 2009; Morin et al. 2014), science (Britner and Pajares 2006), psychology (Diseth 2011), writing (Pajares et al. 2000; Pajares et al. 2007), and communication (Zhang 2014).

There have been a limited number of studies related to the CSE of computer-science students but these have been in the form of conference papers (e.g., Carroll et al. 2005; Lopez et al. 2006; Marsh 2010). Studies have primarily focused on the factors of prior experiences, anxiety, attitude, and gender (e.g., Lopez et al. 2006; Marsh 2010; Rosson et al. 2011; Zingaro 2014) or used the intervening methods such as a cooperative team-based learning environment (Ryan et al. 2000), and peer instruction (Zingaro 2014). This review did not identify any studies of how CLE and information sources of SE influenced the CSE of computer-science students. Table 1 summarizes studies that have investigated factors affecting CSE. All participants were undergraduate students.

Table 1 Studies of factors affecting the CSE of undergraduate students

The summary shows that data collection in studies of CSE tends to rely, for the majority, on surveys. Most of these studies collected data from one particular institution which may have affected the applicability of the results to the larger community. The present study is based on data collected from 10 sites located in five different provinces in Thailand. This broad sampling increases the likelihood that the sample more accurately reflects what actually exists in the population.

Some studies used computer-based approaches for the intervening variables (e.g., Ryan et al. 2000; Zingaro 2014). Others used psychological variables (e.g., Durndell and Haag 2002; Sam et al. 2005; Veilleux et al. 2013). Other studies explored the antecedent variables such as prior experiences that affected students’ interpretation of their SE beliefs (Wilfong 2006). Gender differences were also used to measure the factors influencing CSE (e.g., Marsh 2010; Rosson et al. 2011).

In terms of results, Deechuay et al. (2016), Durndell and Haag (2002), Marsh (2010), and Rosson et al. (2011) found that gender differences exerted a significant influence on CSE. Durndell and Haag (2002) and Sam et al. (2005) revealed that computer anxiety had a negative effect on CSE. Hasan (2003) and Wilfong (2006) identified that computer experiences had a strong effect on CSE. Zingaro (2014) reported that the interactive learning environment with peer instruction significantly increased students’ CSE. In contrast, Ryan et al. (2000) found that learning environments using a cooperative approach did not help students increase their SE. Hsu and Huang (2006) found that a home-based computer learning environment had a direct effect on CSE. Lin et al. (2013) found that student-centered learning affected CSE. Weng et al. (2009) found that students from different types of institutions had different levels of SE. Veilleux et al. (2013) determined that sense of belonging influenced students’ attitudes toward their SE.

3.2 The present study

As Van Dinther et al. (2011) observed in a meta-analysis, there are a limited number of studies that investigate how perceived CLE and information sources of SE affect CSE particularly in computer-science courses. The aim of the present study was to investigate the relationship between a) three aspects of CLE (meaningfulness, autonomy, and involvement); b) information sources of SE (social persuasions, physiological and affective states, and vicarious experiences) and; c) the CSE of undergraduate computer-science students. This study also investigated how the CLE contributed to information sources of SE and subsequently influenced the CSE of computer-science students. The present study focused on undergraduate computer-science students. Data collection involved use of a survey as is the approach used in previous studies. The participants were 524 students which represents the average of prior studies (range from 150 to 944 participants) across 10 different sites. The investigated factors affecting students’ CSE have not been widely explored in computer-science courses as has been the case in other learning domains (e.g., mathematics and science) (Moos and Azevedo 2009; Usher and Pajares 2009; Van Dinther et al. 2011).

4 Methodology

4.1 Sample and procedure

In Thailand, the numbers of undergraduate students enrolled in computer-science programs at institutions of higher education were 26,057 in 2014, 21,227 in 2015, and 20,324 in 2016 (Office of Higher Education Commission 2017). We used convenience sampling technique that took advantage of the researcher’s professional networks and assured a high participation rate (Lerdpornkulrat et al. 2016). In order to increase the likelihood that our sample would more accurately reflect what actually exists in the population (see Table 1), our research design sampled and collected data from first, second, third, fourth, and fifth year students enrolled in seven public universities and three private universities located in the rural and urban provinces of Bangkok, Samutprakan, Nonthaburi, Sakonnakhon, and Chiangmai, Thailand.

Prior to participation, students were informed that their responses would be anonymous. It was at the discretion of each participant to complete the survey or place a blank or partially completed survey into the provided envelope. All survey items were written in Thai. The survey assessed demographical information, perceptions of CLE, CSE beliefs, and sources of SE. Following Brislin’s (1980) translation-back-translation procedure, two bilinguals in English and Thai conducted two-way translations to ensure that the survey items were valid across cultures. The questionnaire was also pretested with a group of 60 students.

Six hundred twenty-six students were asked to complete the surveys. A total of 524 responses representing 84% of surveys, were completed and used in the data analysis. Three hundred and forty-eight (66.4%) were males and 176 (33.6%) females. In the sample, 33.8% of students were in their first year, 20.6% in their second year, 32.6% in the third year, 12.8% in fourth year, and .4% in the fifth year.

4.2 Measures

A Likert scale was used to determine student’s level of agreement or disagreement on the survey questions. Table 2 presents a sample item and Cronbach’s alpha value of each construct.

Table 2 List of measurement scales, sample items, and Cronbach’s alpha values (N=524)

4.2.1 CLE

The instrument for measuring perceptions of the computer-science CLE was adapted from Koul et al. (2012). Three aspects focused on how students perceived their autonomy in making decisions with teachers to do things in the computer-science classroom (e.g., I decide with the teacher who to work with), perceived meaningfulness from learning content (e.g., What I learn has relevance for me), perceived involvement in classroom activities (e.g., I listen carefully to other’s ideas). Responses were rated from 5 (Strongly agree) to 1 (Strongly disagree) of a five-point Likert scale. Cronbach’s alpha values of meaningfulness, autonomy, and involvement variables were respectively .82, .79, and .73.

4.2.2 Information sources of SE

The assessment of information sources of SE was adapted from Usher and Pajares (2009). The characteristics of this assessment came from how students perceive their interpretation of the information sources of SE (Van Dinther et al. 2011). Information sources of SE help students increase their CSE (Van Dinther et al. 2011). Social persuasions refer to encouraging messages about academic capabilities from peers, and teachers etc. (e.g., My CS teachers have told that I am good at learning CS). Physiological and affective states involve negative emotional states and feelings (e.g., Just being in CS class makes feel stressed and nervous). Vicarious experiences relate to observation of role models (e.g., Seeing university seniors do well in CS courses pushes me to do better) (Usher and Pajares 2008; Zeldin and Pajares 2000). We adopted for use in this study, Usher and Pajares’ (2009) validated six-point Likert scale. The scale ranged from six indicating “Completely confident” to one indicating for “Not at all confident.” Cronbach’s alpha values of social persuasions, psychological states, and vicarious experiences were .96, .93, and .82, respectively.

4.2.3 CSE

CSE beliefs were measured in terms of students’ beliefs about their capabilities to perform computing tasks successfully in the computer-science classroom. This survey was adopted from Papastergiou (2008). There were four items such as “I find working with computers very easy”, “I am very confident in my ability to use computers.” A five-point Likert scale was used with a range from 5 (Strongly agree) to 1 (Strongly disagree). Cronbach’s alpha value of CSE was .74.

4.3 Analysis

Analysis relied on the commonly-used indexes to assess whether our path-analysis model was a good fit: Comparative Fit Index (CFI), Norm fit index (NFI), Goodness of Fit Index (GFI), Standardized Root Mean Squared Residual (SRMR), Tucker-Lewis index (TLI), and Root Mean Square Error of Approximation (RMSEA). The Chi-square was not considered to be a very useful fit index in this model test because the chi-square statistic nearly always rejects models with large sample sizes (Bentler and Bonnet 1980; Jöreskog and Sörbom 1993). Absolute Fit Indices include goodness-of-fit index (GFI), adjust GFI (AGFI), Standardized root mean square residual (SRMR), and RMSEA (Bentler 2006; Jöreskog and Sörbom 1986; Steiger and Lind 1980). Indication of the better model-data fit pertains to the higher values of GFI and AGFI, and lower values of SRMR and RMSEA (Lei and Wu 2007). The criteria for a good model-data fit are as follows: CFI > = .95, SRMR <= .08, RMSEA <= .06 (Hu and Bentler 1999).

Path analysis was used to assess the direct and indirect relations between three components of CLE (meaningfulness, autonomy, and involvement), three variables of the sources of SE (social persuasions, vicarious experiences, and physiological and affective states), and one construct of CSE. Path analysis offers a good technique to provide a multivariate method to estimate direct, indirect, and total structural effects among a set of variables based on theoretical and empirical justification for the relationships (Mueller 1999).

5 Results

5.1 What is the relationship between perceived CLE, information sources of SE, and CSE beliefs of undergraduate computer-science students?

Students’ perceptions of the CLE (meaningful, autonomous, and involvement) were positively associated with information sources of SE (social persuasions and vicarious experiences) and CSE. Moreover, students’ interpretations of social persuasions and vicarious experiences were positively associated with CSE. However, there was a negative association between meaningful CLE and physiological and affective states (information sources of SE). There was a low to moderate correlation between the significant variables (from .142 to .627). Kline (2015) and Lerdpornkulrat et al. (2016) argued that a low to moderate correlation is beneficial for overcoming problems of multicollinearity. Multicollinearity refers to a situation when two or more variables are highly correlated within a multiple regression model (Huang 2008). Table 3 summarizes the mean, standard deviations, and inter-correlations between the major variables.

Table 3 Mean, standard deviations, and inter-correlations between the major variables (N=524)

5.2 What combination of aspects of the CLE and of information sources of SE best predict the CSE beliefs of undergraduate computer-science students?

The strongest total effect on social persuasions and vicarious experiences was autonomy while the strongest total effect on physiological and affective states was meaningfulness followed by autonomy. Overall, the strongest effect on CSE was social persuasions followed by vicarious experiences, and physiological and affective states. Meaningfulness had an indirect association with CSE with the intervening variable of physiological and affective states. Autonomy had an indirect association with the CSE with the intervening variables of social persuasions, physiological and affective states, and vicarious experiences. Involvement had an indirect association with CSE with the intervening variable of social persuasions. Autonomy and involvement accounted for 28% of the variance in social persuasions. Meaningfulness and autonomy accounted for 21% of the variance in physiological and affective states. Autonomy accounted for 41% of the variance in vicarious experiences. In addition, social persuasions, physiological and affective states, and vicarious experiences accounted for 33% of the variance in CSE. Path analysis demonstrated that the exogenous variables of meaningfulness, autonomy, and involvement were positively associated with each other. Autonomy was positively associated with social persuasions, vicarious experiences, and physiological and affective states (β = .645, .638, and .408, respectively) while meaningfulness was only negatively associated with physiological and affective states (β = − .564). Table 4 summarizes the results for the path-analysis model.

Table 4 Direct, indirect and total associations for the path analysis model

The standardized path coefficients of the final model were a good fit and accurately examined the relationships between measured variables. Students’ interpretations of information sources of SE mediated the relationships between students’ perceptions of the CLE and CSE. The Chi-square test (412,524) = 892.29, p = < .001, GFI = .898, AGFI = .877, NFI = .913, CFI = .951, TLI = .944, SRMR = 0.077, and RMSEA = .047. Figure 2 shows the standardized coefficients mediating between CLE, and information sources of SE on CSE.

Fig. 2
figure 2

Standardized coefficients mediating between CLE, and information sources of SE on CSE (N = 524) *p < .05, **p < .01, ***p < .001

6 Discussion

Results of the study confirmed the interrelatedness between CLE, information sources of SE, and students’ CSE beliefs. CLEs perceived by students as offering autonomy, meaningfulness, and involvement were positively associated with CSE. Social persuasions and vicarious experiences were also positively associated with CSE. Negative physiological and affective states (e.g., anxiety and stress) were negatively associated with CSE. Results of the first research question confirm Lin et al.’s (2013) association between computer-science preferred learning environments and SE in learning computer science. They confirm Morin et al.’s (2014) association between classroom climate and students’ SE and achievement. The results also confirm Usher and Pajares’ (2008) findings pertaining to the interrelatedness between information sources of SE and SE. However, these studies considered information sources and learning environment constructs simply as two constructs. This study took a more fine-grained approach that investigated the six aspects associated with these two constructs. Additionally, Usher and Pajares (2008) and Morin et al. considered SE in general and not CSE. Likewise, Lin et al. considered SE in computer science specifically.

In relation to the second research question, the analysis revealed that, within information sources, social persuasions were the strongest predictor of CSE. In relation to students’ perceptions of CLEs, autonomy was the strongest predictor of CSE. Autonomy combined with information sources of SE indirectly affected CSE. Meaningfulness had a negative indirect effect on CSE through physiological and affective states. Involvement had a negative indirect effect on CSE through social persuasions. Results revealed that all three aspects of students’ perceptions of the CLE did not directly predict CSE but they significantly contributed to information sources of SE influencing CSE. Autonomy combined with social persuasions had the strongest total effect on CSE, along with vicarious experiences, and physiological and affective states. When students meet their needs in a computer-science classroom, their levels of CSE tend to be increased (Nichols 2006; Ryan and Deci 2000). Students’ high levels of CSE can help to reduce students’ attrition rate in computer-science programs (Rosson et al. 2011) and increase students’ computer-science career aspirations (Kvasny et al. 2011).

In relation to information sources of SE, the current results have also shown that social persuasions (e.g., feedback) are important in the computer-science classroom, along with vicarious experiences (e.g., observation of role models), and physiological and affective states (e.g., stress, anxiety). However, few studies have focused on information sources of SE in computer-science. Veilleux et al. (2013) emphasized that the retention problem of computer-science students can be helped by encouraging feedback and development of a sense of belonging. In addition, Sheard et al. (2010) recommended that cognitive feedback be used to increase undergraduate student engagement in ICT programs to encourage more active student involvement and reduce attrition. Braught et al. (2011) argued that weaker computer-science students may feel alone and may struggle with difficult tasks. In relation to vicarious experiences, Braught et al.’s findings suggested that peer observation and peer work between students of similar abilities can help students feel more comfortable with their tasks. Close and Solberg (2008) found that students’ retention rate was also predicted by a combination of students’ achievement and physiological and affective states. Negative physiological and affective states adversely affect IT students’ SE and achievement (Weng et al. 2009). The current study not only highlighted the importance of CLE and information sources of SE, but also linked these two constructs with computer-science students’ psychological needs in a computer-science classroom.

The combination of aspects of the CLE and of information sources of SE to predict the CSE have not been investigated in previous research. There are some related studies that were close to this study. A meta-analysis by Moos and Azevedo (2009) synthesized research in order to summarize the factors affected to CSE. Moos and Azevedo showed that CSE helps students to learn about the difficult environments such computer-based learning environments. Behavior and psychological factors (e.g., attitude, enjoyment, prior computer experiences, frequency of computer use, and training approach) are important factors to affect CSE. However, they concluded that previous research did not identify the relationship between types of computer-based environments affecting CSE. They also recommend that future research should consider examining information sources of SE related to the development of CSE. Hsu and Huang (2006) aimed to determine learning motivation and learning environments (e.g., home and school) influencing CSE of computer-science students. They focused on the different aspects of CLE and did not include information sources of SE as the antecedent factors of the investigation.

Figure 3 summarizes the study’s results related to the factors that influence the CSE of computer-science students.

Fig. 3
figure 3

Summary of factors that influence the CSE of computer-science students

7 Conclusion

Results of this study are relevant to addressing problems related to the education of computer-science professionals. The number of students who actually succeed in computer-science courses falls short of meeting the need for ICT professionals and attrition rates in computer-science courses tend to be high. In general, motivation and success in computer-science courses are influenced by students’ SE beliefs in their learning abilities. Previous studies have demonstrated that there is a relationship between information sources of SE and SE outcomes. However, little research has investigated the relationships among CSE, information sources of SE constructs, and CLE in computer-science education. Past research has tended to separate the investigation of the relationship between CSE or SE and CLE, and CSE or SE and information sources of SE. These studies rarely focused on identifying the relationship between CLE, information sources of SE, and CSE and how students’ perceptions of their CLE contribute to information sources of SE and influence their CSE. The purpose of the present study was to investigate the interactions between multiple variables of CLE (e.g., meaningfulness, autonomy, and involvement), information sources of SE (e.g., social persuasions, physiological and affective states, and vicarious experiences), and the strength of CSE. Results of the present study suggest that there is complex interplay between factors affecting students’ success in computer-science learning courses.

Theoretically, results of this study support Bandura’s (1986) Social Cognitive Theory that explains that information sources predict SE. Additionally, results support self-determination theory which emphasizes that students’ perceptions of the CLE influence their motivation (Niemiec and Ryan 2009; Opdenakker and Minnaert 2011; Ryan and Deci 2000), related to their SE (Nichols 2006). For example, a sense of autonomy (students’ perception of voice and choice to engage in their academic activities) and relatedness (students’ feeling of belongingness, connectedness, peer interaction, and support from important people) fulfill students’ learning motivation and their psychological need for growth (Niemiec and Ryan 2009; Roca and Gagné 2008; Ryan and Deci 2000).

The significance of the current results is related to the arguments of prior studies. The studies of computer-science have shown that teaching tends towards the traditional lecture format (Van Gorp and Grissom 2001) which does not promote autonomy. Schilling and Klamma (2010) argued that traditional approaches do not prepare computer-science students for professional practice. Their arguments highlight the importance of autonomy. Not surprisingly, researchers are advocating new approaches to learning such as online (Hauser et al. 2012; Hung et al. 2010), interaction or collaboration (Schilling and Klamma 2010; Zingaro 2014), and problem based (Rosson et al. 2011). These are approaches to teaching in computer science that can potentially promote autonomy compared to traditional lectures.

8 Limitations

As is the case with other investigations of CSE, the present study was conducted in only one country, Thailand. It is possible that results may not be generalized to other domains of students or to other countries. Beliefs have socio-cultural roots and are often vary not only according to factors such as gender but also country. However, they may not necessarily be generalized to other countries. Luszczynska et al. (2005) conducted a study with students from Germany, Poland, and South Korea. Their findings were similar for all three countries. They found an association between SE in general and social-cognitive variables. However, Luszczynsk et al. concluded that these results were unlikely to be similar across countries for domain-specific SE (e.g., computer-science). Durndell et al. (2000) found that Scottish versus Romanian students had different levels of confidence in abilities and knowledge in computers. Scottish students had more confidence than Romanian students with their beginning computer skills, whereas Romanian students were more confident in their abilities in advanced computer skills.

Comparison among students with different academic years of study, and/or gender differences may have provided more fine-grained insights. As computer-science students gain experience, it is possible that their CSE may change. In Taiwan, as Lin et al. (2013) reported, autonomy was the strongest predictor of CSE of undergraduate-level computer-science students in their first year of study compared to other levels. Rosson et al. (2011) reported that students’ high-school programming experiences continued to influence the CSE of undergraduate students. Rosson et al. noted that gender differences significantly affected the CSE of Information Sciences and Technology students. Males had higher CSE in java programming than did females.

9 Implications for practice and research

In terms of implications for classroom practice, results suggest that computer-science students’ CSE is more likely to be enhanced by cognitive processes such as gradual social feedback (i.e., social persuasions), social comparison with seeing oneself master progression (i.e., vicarious experiences), and opportunities for students to control their learning environments (i.e., autonomy). Autonomous learning is a beneficial feature in the computer-science domain. This aspect of CLEs helps students actively pursue their personal meaning and self-management which may increase students’ confidence in their computer-science learning (Lin et al. 2013).

CLEs should promote positive feedback and involve students’ input into learning content and activities. These CLEs should also offer encouraging and accurate feedback to students. Autonomous learning should also involve vicarious experiences that offer role models for students. Observation of how peers perform tasks better or worse, may promote confidence in students’ abilities and change their habits if they perform better than peers (Hodges 2013). Hodges (2013) recommended selecting peers with similar academic performance. Autonomous learning environments should also consider physiological and affective states. This means that instructors should aim to create CLEs that reduce frustration, stress, and anxiety. Such environments can enhance and sustain students’ CSE, especially when students have more workload, anxiety, and time constraints (Hauser et al. 2012; Lin et al. 2013; Scheja 2006). In general, an autonomous classroom setting may lead to decrease in high levels of classroom anxiety (Hauser et al. 2012). The theory of cognitive dissonance (Aronson 1969; Festinger 1957) suggests that students may be motivated to implement strategies to eliminate dissonance and inconsistencies in their beliefs and attitudes by working to reduce negative feelings. Similarly, students can be provided with opportunities to evaluate their beliefs and attitudes towards computer science (Elliot and Devine 1994).

In terms of implications for research, it would be interesting and relevant to see if the results of this study can be replicated in other national cultural contexts with similar computer-science educational systems. It would also be interesting if this study were replicated not only within the conventional computer-science classroom but in computer-based learning environments in general. This study identified that CLEs with autonomy, meaningfulness, and involvement were associated with CSE. Data collection in this study was limited to surveys and thus to students’ perceptions. Observations and/or interviews might be used for data collection in subsequent studies to determine if students’ perceptions correspond to their lived experiences. More importantly, additional forms of data collection in future studies might explain in depth why CLE with autonomy, meaningfulness, and involvement was associated with CSE. Such studies might provide in-depth insights into the specific mechanisms and characteristics related to autonomy that influence CSE. Similarly, observations and interviews may provide more in-depth insights into how and why social persuasions and vicarious experiences positively influence CSE.